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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |WAITING
   Last reconfirmed|                            |2016-03-30
     Ever confirmed|0                           |1

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
GCCs intended behavior with respect to "incompatible" prototypes or function
pointer types is to

 a) emit a call assuming the ABI with the "incorrect" prototype/function
pointer
 type is in effect (even if it sees the actual function definition)
 b) eventually not inline if incompatibilities are too gross (the runtime
effect
 of an incompatibility is not specified and thus can differ depending on
whether
 the function body is inlined or not)

So - what should the attribute do in addition to the current intended behavior
(which may not the one implemented in all corner cases or on all targets which
I would consider a bug)?  From what I see you'd want to disable inlining
to get reliable "patch-up of incompatibilities", thus use
__attribute__((noinline,noclone))?  What else?

Reply via email to