[PATCH] D157802: [JITLink][EHFrameSupport] Accept multiple relocations

Job Noorman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 19 00:50:21 PDT 2023


jobnoorman added a comment.

In D157802#4647831 <https://reviews.llvm.org/D157802#4647831>, @Hahnfeld wrote:

> I'm not proposing a general solution, just looking at the one case we need in `eh_frame` to get the PC offset from the start of the `.text` section (as far as I understand). There `ADD32` and `SUB32` are at exactly the same offset (that's the condition that currently makes `EHFrameEdgeFixer` fail) with the `SUB32` pointing to the start of the block with a zero addend. For everything else, I agree with your previous statement that storing two arbitrary symbols is a problem, and I don't think we want to go into splitting blocks to fuse edges.

The problem is that those `ADD32`/`SUB32` pairs are not the only problematic relocs. There will be a lot of `SET6`/`SUB6` pairs (used for `DW_CFA_advance_loc`) at the same offset where the `SUB6` does not point to the start of a block (cf. this test case <https://github.com/llvm/llvm-project/pull/66067/files#diff-297d9308360fbf461cc8dcd59fddb4c7ff60eedb59ef54f37631e2b970d30902>).


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D157802/new/

https://reviews.llvm.org/D157802



More information about the llvm-commits mailing list