LLVM JIT support on PowerPC?
Does anyone know the status of LLVM JIT support on PowerPC? I have seen the link Target Feature Matrix , it claimes that LLVM JIT supports PowerPC. But when I ran the HowToUseJIT example (in t开发者_运维百科he $LLVM_SRC/examples), it gave the error belows,
Running foo: %X4<def> = LDtoc <ga:@add1>, %X2
UNREACHABLE executed!
Stack dump:
0. Running pass 'PowerPC Machine Code Emitter' on function '@foo'
Aborted
No matter on ppc or ppc64, LLVM JIT cannot call external functions. Any idea? Should I file a bug report, or which part of LLVM I can take a look first?
Thanks!
The PPC support in LLVM stagnated during some time, mostly because noone is interested in it (as you might know, Apple deprecated PPC on Mac). Thus, it's pretty expected that JIT on PPC might be heavily broken or won't work at all.
You might fill a bug report, but almost surely noone will work on it (due to reasons I outlined). So, feel free to fix the bug and submit the patch. Thanks!
If you want to fix the stuff by yourself - you should start by looking into PPC JIT code emitter and provide the handling of such instructions there.
精彩评论