digitalmars.D - Any workaround for bug 24118?
- Paolo Invernizzi (8/8) Sep 05 2023 Hi all,
- RazvanN (10/18) Sep 05 2023 I have run the code with a debug build (without -release) which
- user1234 (5/13) Sep 05 2023 Hello, I have just found that `if( __ctfe && true)` works.
- Paolo Invernizzi (5/13) Sep 05 2023 That's a perfect workaround for here and now, thank you!
- Paolo Invernizzi (3/15) Sep 05 2023 Nope, still crashing on our codebase
- RazvanN (3/11) Sep 05 2023 PR fixing the issue: https://github.com/dlang/dmd/pull/15578
- Paolo Invernizzi (2/17) Sep 06 2023 Thank you Razvan, I'll follow the progress of the PR
- RazvanN (23/41) Sep 06 2023 @Paolo: If you want to compile your code before my PR gets in,
- Paolo Invernizzi (6/48) Sep 06 2023 Thanks Razvan, that's really appreciated, especially because on
- RazvanN (4/11) Sep 06 2023 You're welcome! Let me know if there is anything else I could of
Hi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround? We are not even sure about the root cause of it ... Thank you, Paolo [1] https://issues.dlang.org/show_bug.cgi?id=24118
Sep 05 2023
On Tuesday, 5 September 2023 at 13:19:15 UTC, Paolo Invernizzi wrote:Hi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround? We are not even sure about the root cause of it ... Thank you, Paolo [1] https://issues.dlang.org/show_bug.cgi?id=24118I have run the code with a debug build (without -release) which does not exclude asserts and I get: core.exception.AssertError src/dmd/e2ir.d(1725): This case should have been rewritten to `_d_arraycatnTX` in the semantic phase Walter has recently made it so that the lowerings to the druntime hooks are not emitted in ctfe contexts. I bet that's why this code is failing. I'm investigating further, hopefully will be able to come up with a fix shortly. Stay tuned.
Sep 05 2023
On Tuesday, 5 September 2023 at 13:19:15 UTC, Paolo Invernizzi wrote:Hi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround?Hello, I have just found that `if( __ctfe && true)` works.We are not even sure about the root cause of it ...That's an assertion failure in the backend which happens when a conditional expression is processed.Thank you, Paolo [1] https://issues.dlang.org/show_bug.cgi?id=24118
Sep 05 2023
On Tuesday, 5 September 2023 at 14:32:17 UTC, user1234 wrote:On Tuesday, 5 September 2023 at 13:19:15 UTC, Paolo Invernizzi wrote:That's a perfect workaround for here and now, thank you! I've just tested that the code is compiling fine on dmd-nightly, so I guess it was fixed somehow in main. /PHi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround?Hello, I have just found that `if( __ctfe && true)` works.
Sep 05 2023
On Tuesday, 5 September 2023 at 14:39:07 UTC, Paolo Invernizzi wrote:On Tuesday, 5 September 2023 at 14:32:17 UTC, user1234 wrote:Nope, still crashing on our codebaseOn Tuesday, 5 September 2023 at 13:19:15 UTC, Paolo Invernizzi wrote:That's a perfect workaround for here and now, thank you!Hi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround?Hello, I have just found that `if( __ctfe && true)` works.
Sep 05 2023
On Tuesday, 5 September 2023 at 13:19:15 UTC, Paolo Invernizzi wrote:Hi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround? We are not even sure about the root cause of it ... Thank you, Paolo [1] https://issues.dlang.org/show_bug.cgi?id=24118PR fixing the issue: https://github.com/dlang/dmd/pull/15578
Sep 05 2023
On Tuesday, 5 September 2023 at 15:34:36 UTC, RazvanN wrote:On Tuesday, 5 September 2023 at 13:19:15 UTC, Paolo Invernizzi wrote:Thank you Razvan, I'll follow the progress of the PRHi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround? We are not even sure about the root cause of it ... Thank you, Paolo [1] https://issues.dlang.org/show_bug.cgi?id=24118PR fixing the issue: https://github.com/dlang/dmd/pull/15578
Sep 06 2023
On Wednesday, 6 September 2023 at 07:54:41 UTC, Paolo Invernizzi wrote:On Tuesday, 5 September 2023 at 15:34:36 UTC, RazvanN wrote:Paolo: If you want to compile your code before my PR gets in, putting the ctfe code in a function will get rid of the ice: ```d import std.algorithm : map; import std.range : zip; import std.typecons : tuple; void mock() { zip([1,2,3], ["a", "b", "c"]) .map!( i => tuple("", i[1]) ) .map!( a => a[0] ? a[0] : " " ~ a[1] ) ; } void foo() { if( __ctfe ) { mock(); } } ```On Tuesday, 5 September 2023 at 13:19:15 UTC, Paolo Invernizzi wrote:Thank you Razvan, I'll follow the progress of the PRHi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround? We are not even sure about the root cause of it ... Thank you, Paolo [1] https://issues.dlang.org/show_bug.cgi?id=24118PR fixing the issue: https://github.com/dlang/dmd/pull/15578
Sep 06 2023
On Wednesday, 6 September 2023 at 10:57:24 UTC, RazvanN wrote:On Wednesday, 6 September 2023 at 07:54:41 UTC, Paolo Invernizzi wrote:Thanks Razvan, that's really appreciated, especially because on macOS we mainly rely on LDC not only for releases as usuals, but also for the edit-compile-debug cycle (DMD x86_64 is actually slower than LDC arm64). /POn Tuesday, 5 September 2023 at 15:34:36 UTC, RazvanN wrote:Paolo: If you want to compile your code before my PR gets in, putting the ctfe code in a function will get rid of the ice: ```d import std.algorithm : map; import std.range : zip; import std.typecons : tuple; void mock() { zip([1,2,3], ["a", "b", "c"]) .map!( i => tuple("", i[1]) ) .map!( a => a[0] ? a[0] : " " ~ a[1] ) ; } void foo() { if( __ctfe ) { mock(); } } ```On Tuesday, 5 September 2023 at 13:19:15 UTC, Paolo Invernizzi wrote:Thank you Razvan, I'll follow the progress of the PRHi all, Actually we are unable to build any tools on Apple Silicon due to issue 24118 [1]: Someone can suggest a workaround? We are not even sure about the root cause of it ... Thank you, Paolo [1] https://issues.dlang.org/show_bug.cgi?id=24118PR fixing the issue: https://github.com/dlang/dmd/pull/15578
Sep 06 2023
On Wednesday, 6 September 2023 at 11:03:31 UTC, Paolo Invernizzi wrote:On Wednesday, 6 September 2023 at 10:57:24 UTC, RazvanN wrote:You're welcome! Let me know if there is anything else I could of assistance with.[...]Thanks Razvan, that's really appreciated, especially because on macOS we mainly rely on LDC not only for releases as usuals, but also for the edit-compile-debug cycle (DMD x86_64 is actually slower than LDC arm64). /P
Sep 06 2023