__builtin_cmprb

Purpose

Compares the ranged byte.

This built-in function is valid only when -qarch(-mcpu) is set to utilize the POWER9™ technology.

Prototype

int __builtin_cmprb(const int a, int b, int c)

Usage

  • If a is 0, the result is set by the following rules:
    • If the rightmost byte of b is in the range from the rightmost byte of c to the second rightmost bytes of c, the result is 1.
    • Otherwise, the result is 0.
  • If a is 1, the result is set by the following rules:
    • If the rightmost byte of b is in the range from the rightmost byte to the second rightmost byte of either halfword of c, the result is 1.
    • Otherwise, the result is 0.
Notes:
  • a can only be 0 or 1.
  • The rightmost byte is the low bound of the range and second rightmost byte is the high bound of the range.


Voice your opinion on getting help information Ask IBM compiler experts a technical question in the IBM XL compilers forum Reach out to us