28.2.42 __builtin_fbcl
Architecture
dsPIC33A, dsPIC33C/E/F, dsPIC30
Description
Finds the first bit change from left (Msb) in value. This is useful for dynamic scaling of fixed-point data. An example for dsPIC33E:
int16_t result, value;
result = __builtin_fbcl(value);
might generate:
fbcl w4, w5
Prototype
int __builtin_fbcl(int value);
For dsPIC33A, int is int32_t. For dsPIC33C/E/F or
dsPIC30, int is int16_t.
Argument
value – Integer number to check for change.
Return Value
Returns a literal value sign extended to represent the number of bits to shift left.
Machine Instruction
fbcl
Error Messages
None
