D97899 added support for these relocations, but MaskRay noticed
the range check was incomplete. Fix it.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Event Timeline
Maybe, but this discussion is orthogonal to this fix, right? I can't answer for other clients of RuntimeDyld (JIT stuff), but having asserts in the library is fine for BOLT.
Changing that would be more involved (as the entire lib has to change -- all code dealing with relocs from all targets).
Changing that would be more involved (as the entire lib has to change -- all code dealing with relocs from all targets).
There is actually an existing error reporting mechanism, it's just *very* poorly used / documented. You can set HasError = true and ErrorStr = <msg>. That's the right way to check this.
What platforms is BOLT running on? You might be able to switch to JITLink either now or in the near future -- error handling is in a much better state there.
BOLT targets X86 and AArch64.
Linux only? Or Darwin and Windows too?
On Darwin JITLink already supports x86-64 and AArch64.
On Linux JITLink supports x86-64, and should support AArch64 in the not-too-distant future.
There is no Windows support for JITLink yet.
Ok. Keep an eye out for JITLink arm64 support. It's not going to land immediately, but I think Vassil is interested in it too, so I'm hoping we can get it done before LLVM 13. As soon as it's ready ORCv2 / JITLink will probably be an attractive option for you.
Adding Jonas as our Arm JIT expert (as per https://github.com/cms-sw/cmssw/issues/31123)