[Bug target/102376] New: [aarch64] using target("sve") attribute without a + is not very helpful on what is wrong

pinskia at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Thu Sep 16 18:30:02 GMT 2021


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

            Bug ID: 102376
           Summary: [aarch64] using target("sve") attribute without a + is
                    not very helpful on what is wrong
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Keywords: diagnostic
          Severity: enhancement
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: pinskia at gcc dot gnu.org
  Target Milestone: ---
            Target: aarch64-*-*

Take:
void calculate(void) __attribute__ ((__target__ ("sve")));

Currently GCC produces:
<source>:1:57: error: pragma or attribute 'target("sve")' is not valid
    1 | void calculate(void) __attribute__ ((__target__ ("sve")));
      |                                                         ^

But maybe it should tell you that you need to add a + in front of sve.

Also this is inconstitant with x86_64 where you don't need the + sign.


More information about the Gcc-bugs mailing list