-qignerrno

Category

Optimization and tuning

Pragma equivalent

#pragma options [no]ignerrno

Purpose

Allows the compiler to perform optimizations that assume errno is not modified by system calls.

Some system library functions set errno when an exception occurs. When ignerrno is in effect, the setting and subsequent side effects of errno are ignored. This allows the compiler to perform optimizations that assume errno is not modified by system calls.

Syntax

Read syntax diagramSkip visual syntax diagram
        .-noignerrno-.   
>>- -q--+-ignerrno---+-----------------------------------------><

Defaults

Usage

If you require both -O3 or higher and the ability to set errno, you should specify -qnoignerrno after the optimization option on the command line.

Predefined macros

C++ only __IGNERRNO__ is defined to 1 when ignerrno is in effect; otherwise, it is undefined.

Related information