Following change https://reviews.llvm.org/rL354972 the Intel JIT Listener would not report line table information because the section index didn't match.
There was a similar issue with the PerfJitEventListener here: https://reviews.llvm.org/D59189
This patch performs the section index lookup when building the object address used to query the line table information.
$ llvm-lit llvm/test/JitListener
- Testing: 2 tests, 2 threads --
PASS: LLVM :: JitListener/simple.ll (1 of 2)
PASS: LLVM :: JitListener/multiple.ll (2 of 2)
Testing Time: 0.36s
Expected Passes : 2
AFAIU there should not be error here. If Sym is an absolute symbol without section assigned then Undef value should be used as SectionIndex.