This is not a miscompile in the sense that the compiler's code
generation is not wrong; but there is non-Thumb-2 compatible inline
assembler, which means that the code may not work if the package is
built in Thumb-2.
The ldm ..., {...,lr,pc} instruction form is not permitted in Thumb-2.
However, there are likely to be other problems also, which may result in
buggy execution without necessarily causing compile failures.
I'm guessing that the JIT output is ARM code only (not Thumb), and that
interworking is not currently handled fully for calls and returns
between the C++/other high level code and the JIT output ... am I
correct here?
*If* the following conditions are met, then I recommend to build the
package with -marm :
1) If the JIT output calls/jumps to code which is not part of the JIT
output, the destination code must
a) be called via C++/high-level code which is part of llvm itself,
or
b) be part of llvm itself
2) Addresses of JITted code must not be pased out of the llvm package
(i.e., external libraries must not invoke parts of the JITted code as a
callback)
(If met, these conditions imply that switching between ARM and Thumb
will not be needed when jumping into/out of the JITted code, providing
that llvm itself was built as all ARM code.)
If the above conditions are not met, then we may have to look at this
package more closely.
--
[arm] needs porting to thumb2
https://bugs.launchpad.net/bugs/513735
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs