mpd/src/util/BitReverse.cxx

16 lines
385 B
C++
Raw Normal View History

// SPDX-License-Identifier: GPL-2.0-or-later
// Copyright The Music Player Daemon Project
2020-02-05 19:49:18 +01:00
#include "BitReverse.hxx"
static constexpr BitReverseTable
GenerateBitReverseTable() noexcept
{
BitReverseTable table{};
for (unsigned i = 0; i < 256; ++i)
table.data[i] = BitReverseMultiplyModulus(i);
return table;
}
const BitReverseTable bit_reverse_table = GenerateBitReverseTable();