-qunwind

Category

Optimization and tuning

Pragma equivalent

None.

Purpose

Specifies whether the call stack can be unwound by code looking through the saved registers on the stack.

Specifying -qnounwind asserts to the compiler that the stack will not be unwound, and can improve optimization of non-volatile register saves and restores.

Syntax

Read syntax diagramSkip visual syntax diagram
        .-unwind---.   
>>- -q--+-nounwind-+-------------------------------------------><

Defaults

-qunwind

Usage

The setjmp and longjmp families of library functions are safe to use with -qnounwind.

Predefined macros

None.