You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -17,19 +17,17 @@ Instructs the compiler to turn off stack probes if **`off`** (or **`-`**) is spe
17
17
18
18
## Remarks
19
19
20
+
This pragma only applies to 32-bit platforms (x86, ARM32). It has no effect on 64-bit platforms.
21
+
20
22
This pragma takes effect at the first function defined after the pragma is seen. Stack probes are neither a part of macros nor of functions that are generated inline.
21
23
22
-
If you don't give an argument for the **`check_stack`**pragma, stack checking reverts to the behavior specified on the command line. For more information, see [Compiler options](../build/reference/compiler-options.md). The interaction of the `#pragma check_stack` and the [`/Gs`](../build/reference/gs-control-stack-checking-calls.md) option is summarized in the following table.
24
+
`#pragma check_stack(off)` / `#pragma Check_stack-` is ignored if the size of the function locals is larger than 4096 or the value specified by `/Gs`.
23
25
24
-
### Using the check_stack Pragma
26
+
The default behavior on is to insert stack probes at the beginning of each function if the size of the locals exceeds 4096 (or the value specified by `/Gs`) to ensure that the stack is large enough to accommodate the function's requirements.
|`#pragma check_stack( )` or<br /><br /> `#pragma check_stack`| Yes | Turns off stack checking for functions that follow |
29
-
|`#pragma check_stack( )` or<br /><br /> `#pragma check_stack`| No | Turns on stack checking for functions that follow |
30
-
|`#pragma check_stack(on)`<br /><br /> or `#pragma check_stack +`| Yes or No | Turns on stack checking for functions that follow |
31
-
|`#pragma check_stack(off)`<br /><br /> or `#pragma check_stack -`| Yes or No | Turns off stack checking for functions that follow |
28
+
Use [/Gs (Control stack checking calls)](../build/reference/gs-control-stack-checking-calls.md) to change the threshold of the locals that trigger stack probes. Use with caution.
0 commit comments