[PATCH] D112870: [MergeFunctions] Don't merge functions that use @llvm.type.checked.load instrinsics

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Oct 30 08:46:16 PDT 2021


nikic added a comment.

In D112870#3098512 <https://reviews.llvm.org/D112870#3098512>, @kubamracek wrote:

>> Shouldn't this be fixed in FunctionComparator?
>
> So that's certainly the right question here. Should it? To me it looks like FunctionComparator is ignoring metadata attachments *on purpose*, and that fits the contract of "determine whether 2 functions will generate machine code with the same behavior".

I'm reasonably sure that ignoring metadata //arguments// is just an oversight here -- they probably weren't used outside dbg intrinsics when this code was written. We have things like constrained fp intrinsics with rounding/exception mode determined by metadata arguments nowadays, and treating two fp operations with different rounding mode as equivalent would clearly be incorrect.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D112870



More information about the llvm-commits mailing list