Header And Logo

PostgreSQL
| The world's most advanced open source database.

Functions

fls.c File Reference

#include "c.h"
Include dependency graph for fls.c:

Go to the source code of this file.

Functions

int fls (int mask)

Function Documentation

int fls ( int  mask  ) 

Definition at line 55 of file fls.c.

Referenced by interval_transform().

{
    int         bit;

    if (mask == 0)
        return (0);
    for (bit = 1; mask != 1; bit++)
        mask = (unsigned int) mask >> 1;
    return (bit);
}