[llvm-bugs] [Bug 46572] New: NEON and "error: unknown type name 'inline'" when using -std=c89
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Jul 2 21:19:13 PDT 2020
https://bugs.llvm.org/show_bug.cgi?id=46572
Bug ID: 46572
Summary: NEON and "error: unknown type name 'inline'" when
using -std=c89
Product: clang
Version: 7.0
Hardware: Other
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: C
Assignee: unassignedclangbugs at nondot.org
Reporter: noloader at gmail.com
CC: blitzrakete at gmail.com, dgregor at apple.com,
erik.pilkington at gmail.com, llvm-bugs at lists.llvm.org,
richard-llvm at metafoo.co.uk
I'm working with a project that wishes to use -std=c89 -pedantic for
testing.[1]
Compiling a NEON source file on Aarch64 that uses vector built-ins [2], such as
vabdq_u8, results in the following. It looks like Clang disagrees with 'inline'
from <arm_neon.h>.
>From [1]:
clang blake2s.c -o blake2s -march=armv8-a -O3 -I../testvectors -Wall -Wextra
-std=c89 -pedantic -Wno-long-long -DBLAKE2S_SELFTEST
In file included from blake2s.c:19:
/usr/lib/llvm-6.0/lib/clang/6.0.0/include/arm_neon.h:433:1: error: unknown type
name 'inline'
__ai uint8x16_t vabdq_u8(uint8x16_t __p0, uint8x16_t __p1) {
^
/usr/lib/llvm-6.0/lib/clang/6.0.0/include/arm_neon.h:430:21: note: expanded
from macro '__ai'
#define __ai static inline __attribute__((__always_inline__, __nodebug__))
^
/usr/lib/llvm-6.0/lib/clang/6.0.0/include/arm_neon.h:433:1: error: expected
identifier or '('
/usr/lib/llvm-6.0/lib/clang/6.0.0/include/arm_neon.h:430:28: note: expanded
from macro '__ai'
#define __ai static inline __attribute__((__always_inline__, __nodebug__))
^
...
[1] https://travis-ci.org/github/noloader/BLAKE2/jobs/704535809
[2] https://github.com/BLAKE2/BLAKE2/blob/master/power8/blake2s.c
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200703/3113dea2/attachment.html>
More information about the llvm-bugs
mailing list