[PATCH] D103288: [SanCov] Properly set ABI parameter attributes

Jonas Paulsson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 9 15:05:37 PDT 2021


jonpa added a comment.



> calling a function with mismatched ABI attributes is very much like prototype mismatch, so it's UB

Sounds right to me.

> The other option is that we compromise and allow codegen to look at the callee only for some kinds of ABI attributes.



> ...just go down the easier route of looking at the caller for the type parameters to byval/etc

The sext/zext attributes are the ones of immediate concern and must never be missing, at least on SystemZ.

I have proposed a patch at https://reviews.llvm.org/D103992, that follows the route of trying to make sure that all calls everywhere have the proper attributes set. That is needed if you would prefer to avoid the checking of the prototype during isel.  (On the other hand, I am not really saying that I think that is better than the old behaviour...)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D103288/new/

https://reviews.llvm.org/D103288



More information about the llvm-commits mailing list