Show / Hide Table of Contents

Class ExecutionStack

Extends RuntimeHelpers class with execution stack inspection routines.

Inheritance
object
ExecutionStack
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: DotNext.Runtime.CompilerServices
Assembly: DotNext.Unsafe.dll
Syntax
public static class ExecutionStack

Methods

View Source

IsOnExecutionStack(void*)

Determines whether the specified memory location belongs to the stack memory.

Declaration
[CLSCompliant(false)]
public static bool IsOnExecutionStack(void* location)
Parameters
Type Name Description
void* location

The memory location.

Returns
Type Description
bool

true if location is on the stack; otherwise, false.

Exceptions
Type Condition
PlatformNotSupportedException

The target platform doesn't have a reliable way to inspect an execution stack.

See Also
get_IsStackDetectionSupported()
View Source

IsOnExecutionStack<T>(ref readonly T)

Determines whether the specified memory location belongs to the stack memory.

Declaration
public static bool IsOnExecutionStack<T>(ref readonly T location) where T : allows ref struct
Parameters
Type Name Description
T location

The memory location.

Returns
Type Description
bool

true if location is on the stack; otherwise, false.

Type Parameters
Name Description
T

The type of the data at the memory location.

Exceptions
Type Condition
PlatformNotSupportedException

The target platform doesn't have a reliable way to inspect an execution stack.

See Also
get_IsStackDetectionSupported()
View Source

get_ExecutionStackSize()

Gets a value of the execution stack belongs to the current thread.

Declaration
public static nuint get_ExecutionStackSize()
Returns
Type Description
nuint
Exceptions
Type Condition
PlatformNotSupportedException

The target platform doesn't have a reliable way to inspect an execution stack.

See Also
get_IsStackDetectionSupported()
View Source

get_IsStackAllocated<T>(ReadOnlySpan<T>)

Gets a value indicating that the span represents a memory allocated on the stack.

Declaration
public static bool get_IsStackAllocated<T>(ReadOnlySpan<T> span)
Parameters
Type Name Description
ReadOnlySpan<T> span
Returns
Type Description
bool
Type Parameters
Name Description
T
Exceptions
Type Condition
PlatformNotSupportedException

The target platform doesn't have a reliable way to inspect an execution stack.

See Also
get_IsStackDetectionSupported()
View Source

get_IsStackDetectionSupported()

Gets a value indicating that IsOnExecutionStack<T>(ref readonly T) method is supported on the target platform.

Declaration
public static bool get_IsStackDetectionSupported()
Returns
Type Description
bool
View Source

get_RemainingExecutionStack()

Gets the remaining execution stack space.

Declaration
public static nuint get_RemainingExecutionStack()
Returns
Type Description
nuint
Exceptions
Type Condition
PlatformNotSupportedException

The target platform doesn't have a reliable way to inspect an execution stack.

See Also
get_IsStackDetectionSupported()
  • View Source
☀
☾
In this article
Back to top
Supported by the .NET Foundation
☀
☾