[LLVMdev] multithreading and the JIT, specifically llvm::sys::Memory

Reid Kleckner rnk at google.com
Mon Mar 23 14:09:13 PDT 2015


On Mon, Mar 23, 2015 at 11:51 AM, Justin Bogner <mail at justinbogner.com>
wrote:

> Dale Martin <Dale.Martin at mathworks.com> writes:
> > We were doing some experiments to deserialize/JIT bitcode on multiple
> threads
> > and we hit what looks like this issue:
> >
> > http://lists.cs.uiuc.edu/pipermail/llvmbugs/2013-April/027937.html
> >
> > We’re using LLVM-3.5 so I was a bit surprised that the patch that was
> provided
> > in 2013 doesn’t appear to be in the current codebase. I’m curious what
> the
> > status of this patch and issue are? Are other people multithreading
> their code
> > this way?
>
> I didn't look into it, but the bug's description states this only
> happens when LLVM is built by a pre-C++11 compiler. Trunk requires C++11
> these days, so is this fix even relevant anymore?
>

It's still relevant. Our minimum supported VS version is 2013, which
doesn't have thread safe statics yet. VS 2015 will have it, but it hasn't
been officially released yet. Six CTPs and still going strong. :)

Probably the best thing to do here is some manual atomic checking and
setting of the page size. ManagedStatic is IMO too heavyweight.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150323/5cd9219a/attachment.html>


More information about the llvm-dev mailing list