[PATCH] D144541: [X86] Save/restore base pointer register when it is clobbered

LuoYuanke via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 27 18:40:21 PST 2023


LuoYuanke added a comment.



In D144541#4155710 <https://reviews.llvm.org/D144541#4155710>, @efriedma wrote:

>> Why it would mess unwinding?
>
> I meant fp-based unwinding for profiling etc., not DWARF unwind.
>
>> That register (other register) may also be clobbered in another inline asm
>
> We don't have to use the same register for each inline asm.

The base pointer register is reserved by compiler, we can't reserve too much register?

>> Don't know what ech cif_escape means
>
> llvm-readobj --unwind can decode the DWARF for you.
>
> The important thing is that it allocates a variable amount of space between the arguments and the frame pointer, and saves the incoming value of esp on the stack.

It seems this option is the best one. What do you think?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D144541



More information about the llvm-commits mailing list