[llvm] RuntimeLibcalls: Really move default libcall handling to tablegen (PR #148780)
Trevor Gross via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 4 10:42:26 PDT 2025
tgross35 wrote:
> I'm not really sure what the issue is. The implementation is very underdeveloped if it's that broad. The starting state only bothered to handle sin and cos
There is no issue in the PR here, this looks fine. The problem is when trying to use LLVM's `double` which AIUI is always `f64`, but platform `double` on AVR is `f32`. So `llvm.*.f64` calls symbol `sqrt` with a `f64`, but that's a `f32` symbol on the platform https://llvm.godbolt.org/z/f6sdP4MxT. (Basically the same problem as with `f128` using `long double` symbols). The only way to resolve it is to lower LLVM's `double` math to C23 `sqrtf64` rather than `sqrt` on AVR.
Underdeveloped is accurate here, it's not relevant for a whole lot of users.
https://github.com/llvm/llvm-project/pull/148780
More information about the llvm-commits
mailing list