[PATCH] D34409: Use 64bit jump table with large code model on 64bit

Yichao Yu via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 20 15:54:52 PDT 2017


yuyichao added a comment.

> the existing 32-bit offsets are probably fine.

Ah, I just realize that the large code model is indeed doing some magic here. I'll leave it as is then and update the test. (Though it feels a little strange since the wrong format is asked for....)

> Which leaves x86. It looks like x86 is much like PPC and correct right now:

I believe it's actually wrong. The jump table is emitted into `.rodata` and can be placed far away. It's where I actually saw segfault/assertion.

> That covers the cases most people have been interested in, especially since large model and PIC runs into various other issues too from what I remember.

For some reason we are using large code model with PIC in the JIT and this is the only issue I see on x86-64 so far.


https://reviews.llvm.org/D34409





More information about the llvm-commits mailing list