This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/68896] [ARM] target attribute ignored


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

--- Comment #2 from chrbr at gcc dot gnu.org ---
Currently not a bug, or rather implementation specified.

According to the documentation

6.61.15 Function Specific Option Pragmas

#pragma GCC target ("string"...)
...
Each function that is defined after this point is as if
attribute((target("STRING"))) was specified for that function

So here we have 

#pragma GCC target ("fpu=vfp")
...
int8x8_t __attribute__ ((target("fpu=neon"))) my

so "my" is defined as if attribute((target("fpu=vfp"))) was specified.

Now, IMHO this is not intuitive since the attribute targets has a smaller
scope, it should have a higher priority. And the doc doesn't say if the
attribute target is inserted before or after the existing ones, in case of
conflict.
so literally not a bug, but I'd like to specify the order of insertion to solve
your current issue.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]