https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116984
--- Comment #3 from Sam James <sjames at gcc dot gnu.org> --- (In reply to Kees Cook from comment #0) > It should be be possible to trigger -fsanitize=bounds within > __builtin_dynamoc_object_size() (which should have no side-effects). > Can you give some more background here? This isn't obvious to me (at least for your case).