https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108915
AK <hiraditya at msn dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|INVALID |FIXED --- Comment #4 from AK <hiraditya at msn dot com> --- Adding `__attribute__((used))` also fixed it. Does it reflect the same behavior as using `asm` as you suggested?