<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">OK, I've enhanced Atomic.h by pulling in a bunch of implementations from libatomic_ops, and others that I could figure out on my own. <div><br></div><div>Again, my plea: PLEASE TRY THIS OUT ON YOUR PLATFORM, AND SEND ME PATCHES IF IT DOESN'T WORK!  Similarly, if you think the implementation could be improved for your platform, send me a patch.</div><div><br></div><div>I know that Sparc doesn't work currently (no CAS implementation yet), and I'm a little unsure about the ARM version, so it'd be great if gurus for those platforms could look at them.</div><div><br></div><div>--Owen</div><div><br><div><div><div>On May 16, 2009, at 3:00 PM, Zoltan Varga wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">Hi,<br><br>  You might want to use this:<br><br><a href="http://www.hpl.hp.com/research/linux/atomic_ops/">http://www.hpl.hp.com/research/linux/atomic_ops/</a><br><br>                             Zoltan<br><br><div class="gmail_quote"> On Sat, May 16, 2009 at 11:11 PM, Owen Anderson <span dir="ltr"><<a href="mailto:resistor@mac.com">resistor@mac.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"> Some of you may have noticed that I addedd include/llvm/System/Atomics.h to the repository briefly, which will be used for adding support for threading in LLVM.<br> <br> I have tried to provided appropriate implementations of the atomic ops (currently memory fence and CAS) for platforms we care about, but my knowledge of these, and my ability to test them, is limited.  So, please, if you run on any less common platform, test out the file, and send me patches to improve it if it doesn't work verbatim on your system.<br> <br> Thanks,<br><font color="#888888"> <br> --Owen</font><br>_______________________________________________<br> LLVM Developers mailing list<br> <a href="mailto:LLVMdev@cs.uiuc.edu">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><br> _______________________________________________<br>LLVM Developers mailing list<br>LLVMdev@cs.uiuc.edu         <a href="http://llvm.cs.uiuc.edu">http://llvm.cs.uiuc.edu</a><br><a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev">http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</a><br></blockquote></div><br></div></div></body></html>