On March 26, 2021 4:20:28 PM GMT+01:00, Florian Weimer <f...@deneb.enyo.de> 
wrote:
>* Richard Biener:
>
>>> I think H.J. needs this for a function that isn't even
>always_inline,
>>> just extern inline __attribute__ ((gnu_inline)).  Is that aspect
>>> something that could be solved for GCC 11?
>>
>> But that should already work, no?  Yes, it won't inline but also not
>> error.  Unless glibc lacks the out-of-line definition, that is.
>
>It does not work:
>
>extern double strtod (const char *, char **);
>
>extern __inline __attribute__ ((__gnu_inline__)) double
>atof (const char *__nptr)
>{
>  return strtod (__nptr, (char **) ((void *)0));
>}
>
>fails with -mno-sse:
>
>t.c: In function ‘atof’:
>t.c:5:1: error: SSE register return with SSE disabled
>
>I don't think we need to support calling atof under these
>circumstances (in fact, this is impossible to support because there is
>no ABI we could use for the call).  But we need to ignore the inline
>function definition, like we ignore function declarations.  Otherwise
>we'll have to patch a lot of headers to support -mno-sse.
>
>Or has this already been fixed differently in GCC 11?

I think that has been fixed differently already.

Richard. 

Reply via email to