wimax: Use bitwise operations instead of power-2 multiplications

This commit is contained in:
Eduardo Almeida
2023-06-11 19:21:24 +00:00
parent 8c49f49cbf
commit 7dbf987f55

View File

@@ -547,7 +547,7 @@ SimpleOfdmWimaxPhy::ConvertBitsToBurst(Bvec buffer)
for (int l = 0; l < 8; l++)
{
bool bin = buffer.at(i + l);
temp += (uint8_t)(bin * std::pow(2.0, (7 - l)));
temp |= (bin << (7 - l));
}
*(pstart + j) = temp;