Martin Kinkelin
Martin Kinkelin
How's `-mcpu=native` for you? That made it work again on godbolt (once), but I'm not sure the godbolt runner CPUs are stable.
On godbolt, I get znver3 too for some attempts. And there `-O1 -mcpu=native` fails, but `-O3 -mcpu=native` passes again. [FWIW, the isolated testcase works because the std.int128 binops are templates,...
On an AMD Ryzen 3960X (Zen v2), I can reproduce the failures with prebuilt v1.41.0-beta1 (FWIW, on Ubuntu 24, same as my laptop), with both `x86-64-v3` and `native`.
There is no v2.110.0 final yet, so we get more upstream issues filed here for LDC. The compiler crashes with `dmd-nightly` on run.dlang.io too. Apparently caused by `= null`; `=...
So the immediate problem is this? > dub --arch=aarch64 --compiler=ldc2 --single /Users/runner/.dub/packages/dmd/~master/dmd/config.d -- /Users/runner/.dub/packages/dmd/~master/dmd/generated/dub /Users/runner/.dub/packages/dmd/~master/dmd/VERSION /etc The most suspicious thing IMO is the `--arch=aarch64`, so I'd try removing it, and...
Okay thx, now I think I know what happens - the `ldc2.conf` file expects `arm64-apple-…` triples, not `aarch64-…`. Apple went with this scheme for clang, so we/LDC adopted it. Now...
Okay, after looking at DMD's dub.sdl, I think that should be fixed - it builds & runs a little `config.d` tool, so it must be runnable on the compiling machine....
Looks as if https://github.com/dlang/dmd/pull/9275 actually broke working cross-compilation before, despite its name. ;)
The thing is: that `config.d` tool doesn't need to be built for the same build **target** as the main dub build. And it cannot, just imagine some guy cross-compiling some...
I've had a go at it: https://github.com/dlang/dmd/pull/16756