mgorny added a comment.

In D109695#2999171 <https://reviews.llvm.org/D109695#2999171>, @labath wrote:

> Let's take a step back. First, I'd like to understand why are you adding a 
> whole new register, instead of just an alias (alt_name) for an existing 
> register.

Well, I was thinking 'what if the register has already another alt_name?' While 
it's unlikely that such a thing would happen with gdbserver, it's valid input 
in the end, and adding a new register seemed a more reliable solution for 
arbitrary input.

> And second, have you considered putting this into the ABI plugin, as that's 
> where the rest of the "augmentation" code lives (or most of it, anyway).

I initially did, yes, and I've figured out that it doesn't belong there since 
1) these assignments aren't really specific to a single ABI but are general 
architecture characteristics, and 2) the logic is really specific to the 
gdb-remote plugin.

I mean, putting things like generic regno assignments into ABI makes sense 
because different ABIs could use different registers for given purpose. 
However, things like ESP being derived from RSP or aliasing sp to x31 seem 
ABI-independent.

That said, I don't feel strongly about it.


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

https://reviews.llvm.org/D109695

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to