__addex, __builtin_ppc_addex

Purpose

Adds Extended using overflow bit.

Note: This built-in function is valid only when both of the following conditions are met:
  • The -mcpu option is set to target POWER9 processors or higher.
  • The compiler mode is 64-bit.

Prototype

signed long long __builtin_ppc_addex(signed long long a, signed long long b, const int c);

unsigned long long __builtin_ppc_addex(unsigned long long a, unsigned long long b, const int c);

signed long long __addex(signed long long a, signed long long b, const int c);

unsigned long long __addex(unsigned long long a, unsigned long long b, const int c);

Note:
  • The built-in function in the form of __name is a synonym of the built-in function in the form of __builtin_ppc_name.
  • The built-in function in the form of __name is provided for compatibility with IBM® XL C/C++ for AIX® 16.1.0 or earlier releases. This built-in function form might be deprecated in the future.

Usage

The third parameter c is 0. The parameter equal to 1, 2, or 3 is reserved.

The result is the sum of a and b, and the overflow bit.