How use ldc pragmas?
james.p.leblanc
james.p.leblanc at gmail.com
Fri Oct 1 20:14:01 UTC 2021
On Friday, 1 October 2021 at 19:58:30 UTC, max haughton wrote:
> On Friday, 1 October 2021 at 19:23:06 UTC, james.p.leblanc
> Is it sqrt.32 or sqrt.f32? Try the latter, LLVM docs seem to
> agree.
Hello Max,
Thanks for the correction... unfortunately, even after changing
the "32",
to "f32", **I receive the same error**. So there is something of
a bigger
nature that **I am still doing wrong.**
I should have noted earlier that I am just trying to mirror the
docs found at:
https://wiki.dlang.org/LDC-specific_language_changes
```d
// provide square root intrinsics
pragma(LDC_intrinsic, "llvm.sqrt.f32")
float sqrt(float);
pragma(LDC_intrinsic, "llvm.sqrt.f64")
double sqrt(double);
pragma(LDC_intrinsic, "llvm.sqrt.f80")
real sqrt(real); // x86 only
```
Any additional hints for ldc instrinsics are greatly appreciated.
James
More information about the Digitalmars-d-learn
mailing list