[PATCH] D34875: ARM: Report error for invalid use of AAPCS_VFP calling convention

Charles Baylis via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 30 10:11:26 PDT 2017


charles.baylis added a comment.

In https://reviews.llvm.org/D34875#796780, @t.p.northover wrote:

> What's the use case here? For people using `__attribute__((pcs(...)))` Clang should be producing the diagnostic (and I'm not even entirely convinced it should be an error, if your code only contains integer types there's not actually any problem).


While the main use case is clang, the current behaviour is undesirable. When configured for the hardfp ABI, llvm and clang will (for Thumb-1, and targets without VFP) silently produce code which conforms to the softfloat ABI instead.

Fixing the problem in clang still allows that undesirable behaviour in LLVM. It may also be necessary to fix it in clang for cleaner error reporting, unless there is a more delicate way to report the error here.

> Beyond that the tests don't need to be in separate files

I think that they do, because report_fatal_error() causes compilation to terminate so the subsequent tests don't generate a message which can be checked.

> and contain an awful lot of Clang-generated cruft (the attributes, metadata, entry label and source_filename).

Ack.


https://reviews.llvm.org/D34875





More information about the llvm-commits mailing list