[clang] [llvm] IR: Add an intrinsic for memcmp. (PR #118178)
Matt Arsenault via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 2 14:51:20 PST 2024
arsenm wrote:
> We will want to add more handling than that in the future but it is not going to be soon. Very likely the additional handling will be for special cases where the `size_t num` parameter to `memcmp` is known at compile time. I wanted to add the intrinsic so that the backend knows that is isn't just looking at a regular function call where the function happened to be called `memcmp` but an actual call to THE `memcmp`.
You can always do libcall recognition, you don't need an intrinsic to optimize them
https://github.com/llvm/llvm-project/pull/118178
More information about the cfe-commits
mailing list