[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #12 from github-bugzi...@puremagic.com --- Commits pushed to dmd-cxx at https://github.com/dlang/druntime https://github.com/dlang/druntime/commit/fc1013763ff485844b1fef4696498b677a44b4db fix Issue 14476 - core.thread unit tests failing on FreeBSD 9+ https://github.com/dlang/druntime/commit/8e5df2b76a1c3be5b6f18f4ba832a740649a6ca8 Merge pull request #1248 from MartinNowak/fix14476 --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #11 from github-bugzi...@puremagic.com --- Commits pushed to stable at https://github.com/D-Programming-Language/druntime https://github.com/D-Programming-Language/druntime/commit/fc1013763ff485844b1fef4696498b677a44b4db fix Issue 14476 - core.thread unit tests failing on FreeBSD 9+ https://github.com/D-Programming-Language/druntime/commit/8e5df2b76a1c3be5b6f18f4ba832a740649a6ca8 Merge pull request #1248 from MartinNowak/fix14476 --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 Andrei Alexandrescu changed: What|Removed |Added Version|unspecified |D2 --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #10 from github-bugzi...@puremagic.com --- Commits pushed to master at https://github.com/D-Programming-Language/druntime https://github.com/D-Programming-Language/druntime/commit/fc1013763ff485844b1fef4696498b677a44b4db fix Issue 14476 - core.thread unit tests failing on FreeBSD 9+ - the newly created thread fails because of a stack overflow in a syscall to sbrk triggered by pthread_attr_get_np/calloc https://github.com/D-Programming-Language/druntime/commit/8e5df2b76a1c3be5b6f18f4ba832a740649a6ca8 Merge pull request #1248 from MartinNowak/fix14476 fix Issue 14476 - core.thread unit tests failing on FreeBSD 9+ --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #9 from Joakim --- After running the tests some more on my 9.1 i386 VM, it turns out this test is not the issue. The FreeBSD-only test added in issue 13416 seems to be the real culprit, reopened that one instead. --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 Martin Nowak changed: What|Removed |Added Keywords||pull --- Comment #8 from Martin Nowak --- https://github.com/D-Programming-Language/druntime/pull/1248 --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #7 from Martin Nowak --- This is a simple stack overflow. The unittest creates a thread with the minumum stack size of 4KiB and that thread crashes when calling pthread_attr_get_np. https://github.com/freebsd/freebsd/blob/01e375543f2cca888435d33af45404f00296ca0c/lib/libthr/thread/thr_attr.c#L139 The failure happens in a syscall. pthread_attr_get_np -> calloc -> syscall -> sbrk --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #6 from Jonathan M Davis --- (In reply to Martin Nowak from comment #4) > (In reply to Jonathan M Davis from comment #2) > > It looks like it's this commit in druntime which broke things: > > I hope you used https://github.com/CyberShadow/Digger to bisect this. I've never used Digger, and if I knew about it, I'd forgotten. But git-bisect was plenty, and given that that commit adds the test that fails and the code that it's testing, it's not exactly surprising. The harder part was figuring out what pull request the commit was associated with. But unfortunately, I don't know much about what the code is doing, which makes it harder for me to be helpful.(In reply to Martin Nowak from comment #5) > (In reply to Jonathan M Davis from comment #2) > > The second failure with > > > > Testing link_linkdep > > 2.067.0 comes with shared library support for FreeBSD, not sure why they > fail on 9.1. The ugly runtime liker bug is fixed in both 8.4 and 9.1. > http://svnweb.freebsd.org/base?view=revision&revision=226155 Hmmm. I'm using 10.1, so I would _hope_ that it would be fine given that the older versions are, but then again, the code in core.thread seems to work fine on 8.4 and not 9.1 or 10.1. However, looking at Joakim's post, his 32-bit 9.1 VM is failing in a different place earlier in the tests if he comments out the failing core.thread test, so for that problem, 9.1 and 10.1 don't seem to be acting the same (though maybe it's a 32-bit vs 64-bit problem, since he's using 32-bits, whereas I'm using 64). Regardless, it's clear that 8.4 is not acting the same as later versions, so the version of FreeBSD seems to matter more than would be desirable. Maybe I should figure out a way to get a FreeBSD 10.1 setup available for Brad on the autotester so that we're not just testing on an older version - though if he wants the current machines to be supported, he'll have to update the current FreeBSD machines by July according to what freebsd.org says about the support lifecycle of 8.4. But for better or worse, I'm now using FreeBSD 10.1 as my main OS, so I'm likely to start noticing some of these problems that have been getting passed the autotester. --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #5 from Martin Nowak --- (In reply to Jonathan M Davis from comment #2) > The second failure with > > Testing link_linkdep 2.067.0 comes with shared library support for FreeBSD, not sure why they fail on 9.1. The ugly runtime liker bug is fixed in both 8.4 and 9.1. http://svnweb.freebsd.org/base?view=revision&revision=226155 --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 Martin Nowak changed: What|Removed |Added CC||c...@dawg.eu --- Comment #4 from Martin Nowak --- (In reply to Jonathan M Davis from comment #2) > It looks like it's this commit in druntime which broke things: I hope you used https://github.com/CyberShadow/Digger to bisect this. --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #3 from Jonathan M Davis --- It looks like this was the pull request that introduced the change: https://github.com/D-Programming-Language/druntime/pull/1109 --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #2 from Jonathan M Davis --- It looks like it's this commit in druntime which broke things: commit 5c96aca53bf63a9abc58fd45b59156e605c5fa3a Author: Martin Nowak Date: Tue Jan 20 08:56:25 2015 +0100 round thread stack size to pagesize and min stack size The second failure with Testing link_linkdep is there before that commit, but that's the commit that introduces the failure in core.thread. --
[Issue 14476] core.thread unit tests failing on FreeBSD 9+
https://issues.dlang.org/show_bug.cgi?id=14476 --- Comment #1 from Joakim --- I can confirm that that last unittest is the one causing the problem on i386 also, as commenting it out gets core.thread to pass and the tests to fail here instead: Testing link Testing load Testing linkD Testing linkDR Testing loadDR Testing host gmake[1]: *** [obj/freebsd/32/host.done] Segmentation fault: 11 (core dumped) This is with dmd/druntime HEAD on FreeBSD 9.1 stable from a couple years ago running in a VM. --