[ First ]  [ Previous ]  [ Next ]  [ Last ]  [ Manuals ]


Intrinsic Functions for Bit Rotation

CodeWarrior C has functions


  __rol(op, n)
  __ror(op, n)

that do left or right bit rotation respectively.

The op argument represents the item to have its bits rotated. The n argument represents the number of times to rotate op bits. The op argument is not promoted to a larger data type, and may be of type char, short, int, long or long long.

These functions are intrinsic ("built-in"). That is, to use the functions you do not first have to provide function prototypes for them. Also, you do not need to link with any special libraries.


NOTE

Currently, these functions are limited to the Motorola 68K and Intel x86 versions of the CodeWarrior C/C++ compiler.

[ First ]  [ Previous ]  [ Next ]  [ Last ]  [ Manuals ]

Visit the Metrowerks website at: http://www.metrowerks.com
For assistance contact Metrowerks Technical Support at: cw_support@metrowerks.com
Copyright © 2000, Metrowerks Corp. All rights reserved.

Last updated: August 17, 2000