16 Apr 2025 |
rosssmyth | Well one that has been found is that arm-none-eabi means two different things. | 02:18:00 |
rosssmyth | I know there are others but don't know them off-hand | 02:18:24 |
Tristan Ross | I have had thoughts of adding specific toolchain attributes into the systems aside from the actual toolchain tools (cc, libc, linker, etc.). This would focus on CPU model optimizations but could apply to the triple. | 02:18:40 |
Tristan Ross | Yeah if you find a case where things just completely do not match then report it to the stdenv team. | 02:18:58 |
rosssmyth | And then Zig, at least last I checked, the triples were different from GCC and Clang. | 02:19:11 |
Tristan Ross | Sort of | 02:19:50 |
Tristan Ross | Most things should work. | 02:19:58 |
rosssmyth | I don't particularly care about most things though | 02:20:08 |
Tristan Ross | But if you find an issue with Zig, lmk since I maintain it. | 02:20:13 |
rosssmyth | I've not tried using Zig as a C compiler in about two years because of the mess I had triying to use it before, | 02:20:39 |
Tristan Ross | Yeah, though it's hard to know what the cases are without knowing what the cases are. So for now, we've stuck with a best effort thing. | 02:20:43 |
rosssmyth | https://github.com/NixOS/nixpkgs/issues/395349 | 02:20:58 |
Tristan Ross | Ok, you could try it now lol. A lot has changed in two years. | 02:21:05 |
rosssmyth | This is the arm-none-eabi | 02:21:08 |
Tristan Ross | Yeah, I'll have to look into this when I have time. | 02:21:34 |
Tristan Ross | Also, LLVM doesn't really use arch-os-abi . That actually might cause problems. | 02:22:03 |
Tristan Ross | arch-vendor-os-abi is a better way of doing it. | 02:22:13 |
rosssmyth | yes | 02:22:19 |
rosssmyth | I am glad LLVM tries to be mostly sane | 02:22:29 |
rosssmyth | Looks like Zig forwards the triples to the Clang backend now days. Which is great. I remember the blog post Andrew Kelly wrote about it being a drop-in replacement for Clang for cross-compilation and it just wasn't true at all when the blog post was written because the triples were so different | 02:23:44 |
Tristan Ross | Tbf, there's always going to be edge cases that aren't always going to be checked. | 02:24:34 |
rosssmyth | The edge case was...all of windows | 02:24:45 |
Tristan Ross | Oh | 02:27:33 |
| lazyLambda set a profile picture. | 03:24:14 |
| Alexandru Tocar joined the room. | 11:46:48 |
17 Apr 2025 |
| axel joined the room. | 18:02:30 |
FliegendeWurst | Are there really platforms where the byte order is different for floats and integers? | 19:09:55 |
FliegendeWurst | * Are there really platforms where the byte order is different for floats and integers?
I'm wondering, because I found this check: https://github.com/john30/ebusd/blob/25.1/CMakeLists.txt#L139-L165
But could not find any platform on godbolt that would trigger the other case. | 19:15:46 |
rosssmyth | For IEEE floats, no. | 19:38:59 |
rosssmyth | I think PDP had a funny thing where this was not true, but that was also before IEEE floats | 19:39:34 |