Building a debug tests of Higgs[¹] doesn't finish building and runs out of memory with dmd-2016-10-10 (v2.073.0-master-9a935f6). Only takes about 2GB with dmd-2016-10-09 (v2.073.0-master-321c95e). According to verbose output it hangs at `semantic3 parser`. Digger says it's caused by https://github.com/dlang/phobos/pull/4286. [¹]: https://github.com/higgsjs/Higgs
Seems to happen for 2 ctRegex to filter out non-alphanumerical characters. auto nonAlnum = ctRegex!(`[^\w]`w); enum notAlnum = ctRegex!(`[^0-9|a-z|A-Z]`, "g");
From Dmitry https://github.com/dlang/phobos/pull/4286#issuecomment-255182046 > The new version is more demanding on memory during CTFE so yeah, most likely it now fails for some patterns. Dunno what to do here would really love to see the new engine sometime soon. That might still take a while and in the meantime such simple ctRegex eat up 16GiB (kill my project tester https://ci.dawg.eu/ btw). If we can't really support the NFA kickstarter in CTFE, then we should just disable it for now.
https://github.com/dlang/phobos/pull/4877
Wasn't fully resolved by the PR. https://github.com/dlang/phobos/pull/4877#issuecomment-257186040
More specifically this commit https://github.com/dlang/phobos/commit/e98fa4ad5ad39487844c91357cfec4f698e88230 is responsible for the high memory usage. Also both, regex and ctRegex, trigger the bug if initialized during CTFE. enum notAlnum = regex(`[^0-9|a-z|A-Z]`); enum ctNotAlnum = ctRegex!(`[^0-9|a-z|A-Z]`); https://github.com/dlang/phobos/pull/4995
Commits pushed to master at https://github.com/dlang/phobos https://github.com/dlang/phobos/commit/07090ae2fdaddd1c40b8c149f32733e908094ac3 disable kickstart in ctfe to workaround Issue 16626 - consumes too much memory, introduced by e98fa4ad5ad39487844c91357cfec4f698e88230 (#4286) https://github.com/dlang/phobos/commit/9cbc862544a9a4afa14bb526ec4aff7792a71e49 Merge pull request #4995 from MartinNowak/fix16626 disable kickstart in ctfe to workaround Issue 16626
Commits pushed to stable at https://github.com/dlang/phobos https://github.com/dlang/phobos/commit/07090ae2fdaddd1c40b8c149f32733e908094ac3 disable kickstart in ctfe to workaround Issue 16626 https://github.com/dlang/phobos/commit/9cbc862544a9a4afa14bb526ec4aff7792a71e49 Merge pull request #4995 from MartinNowak/fix16626
Commits pushed to newCTFE at https://github.com/dlang/phobos https://github.com/dlang/phobos/commit/07090ae2fdaddd1c40b8c149f32733e908094ac3 disable kickstart in ctfe to workaround Issue 16626 https://github.com/dlang/phobos/commit/9cbc862544a9a4afa14bb526ec4aff7792a71e49 Merge pull request #4995 from MartinNowak/fix16626