[flang-commits] [flang] [flang][AMDGPU] Convert math ops to AMD GPU library calls instead of libm calls (PR #99517)
Matt Arsenault via flang-commits
flang-commits at lists.llvm.org
Fri Jul 19 07:38:08 PDT 2024
arsenm wrote:
> > I don't think this is the way the system should work, but I guess it's reusing an existing pass
>
> I haven't found a better way to do this with what exists right now. The problem is that the math ops get converted to LLVM intrinsic calls in MLIR which may not be supported by the backend and there's no mechanism to map intrinsics to functions that implement them right now. There is a discussion thread on discourse, and the main proposal requires changes to the library where an attribute would be added to a function to indicate it implements a certain intrinsic.
Right, we don't have a real platform definition for how this is supposed to work. Every frontend stitches all of these pieces together slightly differently, and the result is a big mess
https://github.com/llvm/llvm-project/pull/99517
More information about the flang-commits
mailing list