[LLVMdev] [PATCH] Fix weak/linkonce linkage in execution engine

Matthieu Moy Matthieu.Moy at grenoble-inp.fr
Sat Mar 19 10:12:17 PDT 2011


Hi,

I sent this a few days ago, but got no reply, so re-sending to make sure
the patches are not dropped. To summarize, the weak_odr and linkonce_odr
linkage are badly managed in the JIT Execution engine, the patches add
testcases and fix the problem (more details in the commit messages
within the patches).

Regards,

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-add-testcase-for-weak_odr-and-linkonce_odr-in-JIT.patch
Type: text/x-diff
Size: 2683 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110319/428f9b22/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-JIT-fix-linkage-of-weak-and-linkonce-symbols.patch
Type: text/x-diff
Size: 2880 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110319/428f9b22/attachment-0001.patch>
-------------- next part --------------

Matthieu Moy <Matthieu.Moy at grenoble-inp.fr> writes:

> Hi,
>
> I've had problem with a program using LLVM that tried to dynamic_cast
> objects created in the JIT execution engine, from the native part of the
> program (for the curious, the program is PinaVM
> http://gitorious.org/pinavm/pages/Home).
>
> I've narrowed down the issue to the linkage of weak_odr and linkonce_odr
> symbols, used for the vtables, and that _must_ be unique for
> dynamic_cast to work.
>
> Attached are two patches: the first adds a (failing) testcase, the
> second fixes the issue.
>
> I'm not familiar with patch submission on this list, let me know if
> there's a better way to submit patches.

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/


More information about the llvm-dev mailing list