<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div apple-content-edited="true"><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><div style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; ">Broken mostly because updated libraries detect forging of thread contexts (state) for security reasons and blow up.</span></div></span> </div><br><div><div>On 25 Apr 2009, at 14:12, Jay wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><div class="hmmessage" style="font-size: 10pt; font-family: Verdana; ">Cool.<br> <br> > If I use user threads, it's a different story (which is probably too bad,<br><br>Oops, right, I forgot, I should have mentioned that, user threads have likely been broken on all platforms for a while. I noticed that on PPC_LINUX. I think it is trivial to fix. Or use pthreads..<br> <br> <br> - Jay<br><br> <br>> To:<span class="Apple-converted-space"> </span><a href="mailto:jay.krell@cornell.edu">jay.krell@cornell.edu</a><br>> Date: Fri, 24 Apr 2009 20:38:17 -0700<br>> From:<span class="Apple-converted-space"> </span><a href="mailto:mika@async.caltech.edu">mika@async.caltech.edu</a><br>> CC:<span class="Apple-converted-space"> </span><a href="mailto:m3devel@elegosoft.com">m3devel@elegosoft.com</a><br>> Subject: Re: [M3devel] help booting CM3 on FreeBSD 4.11?<br>><span class="Apple-converted-space"> </span><br>> Jay (and others),<br>><span class="Apple-converted-space"> </span><br>> Success! I think.... I was able to build the compiler, after much<br>> experimentation, by using Jay's build order and linking with -libc_r.<br>> Mentor works, and that's usually a good sign.<br>><span class="Apple-converted-space"> </span><br>> Jay, your assembly worked too! And as you say, it's much easier to<br>> bootstrap with that than to do what I was trying to do (but I did<br>> both, several times, just to make sure).<br>><span class="Apple-converted-space"> </span><br>> I don't know why I was having linking problems with -libc_r earlier.<br>> Now it just seems to work. So, pthreads on FreeBSD 4.<br>><span class="Apple-converted-space"> </span><br>> If I use user threads, it's a different story (which is probably too bad,<br>> as I know that user threads work absolutely fine in my old version of CM3):<br>><span class="Apple-converted-space"> </span><br>> I can build a compiler fine, but the bootstrapped cm3 crashes in<br>> the user thread code. Note that exactly the same thing happens whether<br>> I bootstrap with the assembly version from Jay or from v. 5.3.4, which<br>> I think is what I had. Here we go:<br>><span class="Apple-converted-space"> </span><br>> Starting program: /usr/local/cm3/pkg/cm3/FreeBSD4/cm3<span class="Apple-converted-space"> </span><br>><span class="Apple-converted-space"> </span><br>> Program received signal SIGSEGV, Segmentation fault.<br>> 16_82568bb in RTHooks.PushEFrame (frame=16_bfbff3f4) at ../src/thread/POSIX/ThreadPosix.m3:1599<br>> 1599 f.next := self.context.handlers;<br>> (gdb) where<br>> #0 16_82568bb in RTHooks.PushEFrame (frame=16_bfbff3f4) at ../src/thread/POSIX/ThreadPosix.m3:1599<br><br></div></span></blockquote></div><br></body></html>