[PATCH] D139000: [AMDGPU] Clear bodies of function with incompatible features

Pierre van Houtryve via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 4 07:11:52 PST 2023


Pierre-vh added a comment.

In D139000#4026031 <https://reviews.llvm.org/D139000#4026031>, @arsenm wrote:

> I think this is too much magic to apply based on target-features, and is too specific for the library usage. I think this needs to be an explicit opt-in behavior for the function, maybe a form of linkage (target_weak)? I also think the library use case is insufficient to add such a thing. It's like 1 medium-small file that requires duplication, plus maybe 5 or so microscopic functions

I thought we agreed this was the solution we wanted, at least for now? I remember there was quite a bit of discussion but I ended up with a green light to work on this pass based on the current use-case (device libs)

I agree this should probably be opt-in though, but adding a linkage type seems overkill no? Could we do something simpler like a target-feature perhaps? Or just make the CL option off by default?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D139000



More information about the llvm-commits mailing list