[llvm] [LLVM] Factor disabled Libcalls into the initializer (PR #98421)

Joseph Huber via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 11 10:31:54 PDT 2024


jhuber6 wrote:

> I suspect long-term, we might want to factor this differently... it's sort of annoying for out-of-tree targets to be forced to modify code outside the target itself. But it's probably simpler to consider the best way to approach that after everything is unified and pulled out of TargetLowering. So I'm okay with landing this as-is, and revisiting later.

Yeah, I'm working on a patch that just moves the logic to a separate class. I think a full overhaul / rewrite would be much more difficult and I'm mainly concerned with allowing LTO to optimize out unused libcalls. It seems a little strange overall that we have the `TargetLibraryInfo` that manages IR "libcalls" and `TargetLoweringBase" that handels RT "libcalls" and they're totally different.

https://github.com/llvm/llvm-project/pull/98421


More information about the llvm-commits mailing list