[Bug c++/90228] [UBSAN]: get_addr_base_and_unit_offset_1

rguenth at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Apr 24 12:37:00 GMT 2019


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90228

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
Hmm.  We return signed offset because the maximum object size is half of the
address space.  So I think the code is OK and just invalid C input will produce
undefined output here.  Otherwise we'd need one bit more in precision and
sacrifice speed of compilation quite a bit for this hot function.


More information about the Gcc-bugs mailing list