QP/C
Variables
qf_log2.c File Reference

QF_log2Lkup[] definition. More...

#include "qf_pkg.h"

Go to the source code of this file.

Variables

uint8_t const Q_ROM Q_ROM_VAR QF_log2Lkup [256]
 Lookup table for (log2(n) + 1), where n is the index into the table.

Detailed Description

QF_log2Lkup[] definition.

Definition in file qf_log2.c.


Variable Documentation

uint8_t const Q_ROM Q_ROM_VAR QF_log2Lkup[256]

Lookup table for (log2(n) + 1), where n is the index into the table.

This lookup delivers the 1-based number of the most significant 1-bit of a byte.

Note:
Index range n = 0..255. The first index (n == 0) should never be used.

Definition at line 37 of file qf_log2.c.

Referenced by QF_publish().