[Bug c/89256] No optimized division by constant for __int128
amonakov at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri Feb 8 17:36:00 GMT 2019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89256
Alexander Monakov <amonakov at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |amonakov at gcc dot gnu.org
--- Comment #1 from Alexander Monakov <amonakov at gcc dot gnu.org> ---
It's not so easy, as this trick needs a widening multiply or a high-multiply
operation: e.g. in func64, the compiler uses upper 64 bits of the 128-bit
product of two 64-bit operands.
In func128, it would need to obtain 128 upper bits of a 256-bit product, which
no CPU offers as part of instruction set; so it would need to be a libcall for
a TImode high-multiply operation.
More information about the Gcc-bugs
mailing list