<div dir="ltr">After reading <a href="http://lists.cs.uiuc.edu/pipermail/llvmdev/2009-November/027391.html">http://lists.cs.uiuc.edu/pipermail/llvmdev/2009-November/027391.html</a>, I was hoping that there exists a way to overwrite the head of LLVM's shadow stack to make it thread local and that it would magically just work..<br>
<br>> Note that I used per-thread shadow stacks but none of the LLVM GC support. I used a technique similar to Henderson's accurate garbage collection in an uncooperative environment.<br><br>Thanks, I'll definitely take a look at your work and the paper you mentioned.<br>
<br>Paweł.<br><br><br><div class="gmail_extra"><br><br><div class="gmail_quote">2014-02-17 11:31 GMT+01:00 Jon Harrop <span dir="ltr"><<a href="mailto:jonathandeanharrop@googlemail.com" target="_blank">jonathandeanharrop@googlemail.com</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>I already did this for HLVM. Check it out:</div><div><br></div><div><a href="http://www.ffconsultancy.com/ocaml/hlvm/" target="_blank">http://www.ffconsultancy.com/ocaml/hlvm/</a></div>
<div class="gmail_extra"><br></div>
<div class="gmail_extra">Note that I used per-thread shadow stacks but none of the LLVM GC support. I used a technique similar to Henderson's accurate garbage collection in an uncooperative environment.</div><div class="gmail_extra">

<br></div><div class="gmail_extra">Parallel performance was extremely good:</div><div class="gmail_extra"><br></div><div class="gmail_extra"><a href="http://flyingfrogblog.blogspot.com/2010/01/naive-parallelism-with-hlvm.html" target="_blank">http://flyingfrogblog.blogspot.com/2010/01/naive-parallelism-with-hlvm.html</a></div>

<div class="gmail_extra"><br></div><div class="gmail_extra">HLVM can be faster than Java, Haskell, OCaml, MLton and almost as fast as C/C++:</div><div class="gmail_extra"><br></div><div class="gmail_extra"><a href="http://flyingfrogblog.blogspot.com/2010/01/hlvm-on-ray-tracer-language-comparison.html" target="_blank">http://flyingfrogblog.blogspot.com/2010/01/hlvm-on-ray-tracer-language-comparison.html</a></div>

<div class="gmail_extra"><br></div><div class="gmail_extra">The design of HLVM is very simple. The GC that handles concurrent mutators is only 100 lines of code. The entire garbage collected VM is only 2,000 lines of OCaml code.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">Cheers,</div><div class="gmail_extra">Jon.<br><br></div><div class="gmail_quote"><div><div class="h5">On Mon, Feb 17, 2014 at 7:27 AM, Paweł Batko <span dir="ltr"><<a href="mailto:pawel.batko@gmail.com" target="_blank">pawel.batko@gmail.com</a>></span> wrote:<br>

</div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid"><div><div class="h5"><div dir="ltr"><p style="margin:0px 0px 1em;padding:0px;border:0px currentColor;line-height:17.8px;clear:both;font-family:Arial,"Liberation Sans","DejaVu Sans",sans-serif;font-size:14px;vertical-align:baseline">


Hi all,<br><br>I would like to implement GC for a language supporting multiple threads. There will be no shared state between threads as communication will be based on message passing. I do not care much about performance. The priority for me is to get things working.</p>


<p style="margin:0px 0px 1em;padding:0px;border:0px currentColor;line-height:17.8px;clear:both;font-family:Arial,"Liberation Sans","DejaVu Sans",sans-serif;font-size:14px;vertical-align:baseline">
I have read LLVM guide on writing GC: <a style="margin:0px;padding:0px;border:0px currentColor;color:rgb(74,107,130);text-decoration:none;vertical-align:baseline;background-color:transparent" href="http://llvm.org/docs/GarbageCollection.html" rel="nofollow" target="_blank">http://llvm.org/docs/GarbageCollection.html</a>. Shadow stack approach looks very promising. The problem is, as described in the guide, shadow stack is single thread solution. It would be ideal if I could get LLVM to create a shadow stack on per thread basis. How could this be achieved?<br>


<br>Thanks,<br>Paweł.</p></div>
<br></div></div>_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:LLVMdev@cs.uiuc.edu" target="_blank">LLVMdev@cs.uiuc.edu</a>         <a href="http://llvm.cs.uiuc.edu" target="_blank">http://llvm.cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</a><br>
<br></blockquote></div><div class="gmail_extra"><br></div></div>
</blockquote></div><br></div></div>