Fedora Account System
Red Hat Associate
Red Hat Customer
This example: void * foo_ifunc (void) __asm__ ("foo"); void * __attribute__ ((__optimize__ ("-fno-stack-protector"))) foo_ifunc (void) { return 0; } extracted from a glibc test results in: ifuncmod1.s: Assembler messages: ifuncmod1.s:122: Error: bad expression ifuncmod1.s:122: Error: junk at end of line, first unrecognized character is `f' ifuncmod1.s:123: Error: bad expression ifuncmod1.s:123: Error: junk at end of line, first unrecognized character is `f' ifuncmod1.s:126: Error: junk at end of line, first unrecognized character is `*' when compiled with these flags: gcc -c -O2 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 --save-temps The assembler input looks like this: .globl foo .type foo, @function foo: .LFB0: .cfi_startproc xorl %eax, %eax ret .cfi_endproc .LFE0: .size foo, .-foo .pushsection .gnu.build.attributes .dc.l 6 # size of name .dc.l 16 # descsz = sizeof (addresses) .dc.l 0x101 # type = FUNC .dc.b 0x47, 0x41, 0x2a, 0x2, 0, 0 # name (numeric: -fstack-protector status) .dc.b 0, 0 # Padding .quad *foo .quad *foo_end # description (symbol name) .popsection *foo_end:
Hi Florian, Thanks for reporting this bug. To be clear, the issue here is not that an ifunc resolver is involved, but rather than the asm() function attribute has been used to provide a specific assembler name. The new annobin-3.5 source release contains a patch that fixes this bug, and there should now be an annobin-3.5-1.fc29 rpm available. Cheers Nick
(In reply to Nick Clifton from comment #1) > Thanks for reporting this bug. To be clear, the issue here is not > that an ifunc resolver is involved, but rather than the asm() function > attribute has been used to provide a specific assembler name. Right, I reduced it past the IFUNC resolver. > The new annobin-3.5 source release contains a patch that fixes this bug, > and there should now be an annobin-3.5-1.fc29 rpm available. Thanks for fixing it so quickly!