[PATCH] D155245: [MC][AsmParser] Diagnose improperly nested .cfi frames

Martin Storsjö via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Nov 19 13:47:50 PST 2023


mstorsjo added a comment.

In D155245#4657083 <https://reviews.llvm.org/D155245#4657083>, @jroelofs wrote:

> In D155245#4657075 <https://reviews.llvm.org/D155245#4657075>, @mstorsjo wrote:
>
>> This breaks building libffi for 32 bit arm; the following snippet does fallthrough from one global function to another, while sharing one single CFI region for all of them: https://github.com/libffi/libffi/blob/master/src/arm/sysv.S#L139-L213
>>
>> Based on this patch, the code in libffi looks like it would be invalid and intentionally should fail to compile.
>
> I may need to restrict this to just MachO, and possibly only when `.subsections_via_symbols` is present.  If this is blocking you, please feel free to revert.

Thanks! I pushed a revert now, and thanks for considering restricting the scope of this error!

>> However, I noticed a different surprising detail here; it looks like this check fails to trigger on Linux (ELF in general I presume?) targets, while it does trigger on MachO and COFF.
>
> That is really weird.  I'll investigate this week.
>
> https://github.com/llvm/llvm-project/issues/72802

Thanks, much appreciated!


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D155245



More information about the llvm-commits mailing list