[PATCH] ARM & AArch64: merge the semantic checking of NEON intrinsics

Ana Pazos apazos at codeaurora.org
Tue Feb 11 10:52:13 PST 2014


Hi Tim,

Did you verify this patch building all auto-generated headers?

I mean did you modify \tools\clang\lib\Headers\Makefile with rules to build arm_neon_sema.h (-gen-arm-neon-sema) and arm_neon_test.h (-gen-arm-neon-test), in addition to arm_neon.h?

Just to make sure no repeated definition happens in the tests.

The check for uniqueness came from the fact AArch64 redefines some ARM intrinsics (it adds new types to the original type strings), so they do not appear more than once in the test list (coming from AArch64 and ARM intrinsics definitions). This was needed for generating the builtins list and I think for the tests too..

Thanks,
Ana.

-----Original Message-----
From: cfe-commits-bounces at cs.uiuc.edu [mailto:cfe-commits-bounces at cs.uiuc.edu] On Behalf Of Tim Northover
Sent: Tuesday, February 11, 2014 6:11 AM
To: t.p.northover at gmail.com
Cc: cfe-commits at cs.uiuc.edu
Subject: [PATCH] ARM & AArch64: merge the semantic checking of NEON intrinsics

Hi all,

There are two kinds of automatically generated tests for NEON intrinsics, both of which can be merged without adversely affecting users (I assert).

# We check that a valid kind of __builtin_neon_XYZ overload is requested (e.g. we're not asking for a float32x4_t version when it only accepts integers. Since the __builtin_neon_XYZ intrinsics should only be used in arm_neon.h, relaxing this test and permitting AArch64 types for AArch32 should not cause a problem. The extra arm_neon.h definitions should be #ifdefed out anyway so won't reach SemaChecking.
# We check that intrinsics which take immediates are actually given compile-time constants within range. Since all NEON intrinsics should be backwards compatible, these tests should be identical on AArch64 and AArch32 anyway.

Does it look reasonable?

Cheers.

Tim.

http://llvm-reviews.chandlerc.com/D2738

Files:
  include/clang/Sema/Sema.h
  lib/Sema/SemaChecking.cpp
  utils/TableGen/NeonEmitter.cpp





More information about the cfe-commits mailing list