Re: [lldb-dev] Duplicate use of "sp" register name on x86 targets

2021-09-06 Thread Pavel Labath via lldb-dev

On 25/08/2021 21:13, Michał Górny via lldb-dev wrote:

Hi,

While working on improving gdbserver compatibility, I've noticed that
"sp" is used twice:

1. as an alt_name for esp/rsp register (giving full 32/64-bit stack
pointer),

2. and as the name of sp pseudo-register (giving ESP/RSP truncated to 16
bits).

FWICS the current lookup logic (at least for LLGS targets) means that 1.
takes precedence, i.e. 'register read sp' and 'p $sp' will both resolve
to RSP.  The 16-bit SP is only visible via 'register read --all'.

However, I'm wondering whether this is actually desirable.
In particular, should 'sp' generic name take precedence over an actual
'sp' (pseudo-)register?



Given that accessing the lower 16 bits of the stack pointer is pretty 
useless, and I can think of several use cases for accessing the (full) 
stack pointer in an architecture-agnostic way, I think that the current 
precedence is right.


Which is not to say that the situation is ideal, but I'm not sure what 
can we (short of travelling back in time) do about it. Maybe we can 
provide some alias (sp_16, sp_86, ???), so that the register remains 
addressable?


pl
___
lldb-dev mailing list
lldb-dev@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev


Re: [lldb-dev] who is maintaining lldb-x86_64-debian

2021-09-06 Thread Pavel Labath via lldb-dev

On 03/09/2021 07:00, Omair Javaid via lldb-dev wrote:

Hi Jan,
On Thu, 2 Sept 2021 at 17:29, Jan Kratochvil > wrote:


On Thu, 02 Sep 2021 12:42:37 +0200, Raphael “Teemperor” Isemann via
lldb-dev wrote:
 > If this is about the TestGuiBasicDebug failures, then that test
is also
 > failing on other bots. I personally would vote to disable the
test as that
 > part of the test is flakey since its introduction (which was
during this
 > GSoC).

Yes, in the last month or so there have been some random failures on 
this otherwise very stable buildbot so I was wondering if someone is 
looking after and taking care of these issues or not.


There are multiple racy testcases. I have setup alert only if all last
5 builds failed. That is a longterm reliable enough threshold.

For https://lab.llvm.org/staging/#/builders/16
 = lldb-x86_64-fedora:
https://lab.llvm.org/staging/api/v2/builders/16/builds?limit=5&order=-number


         "state_string": "build successful",

This is helpful. Thanks!



Jan



I haven't been very (or at all) active for the last few months, but that 
should change soon (as soon as I regain my bearings). And then I'll see 
what I can do about this.


pl
___
lldb-dev mailing list
lldb-dev@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev


Re: [lldb-dev] Duplicate use of "sp" register name on x86 targets

2021-09-06 Thread Michał Górny via lldb-dev
On Mon, 2021-09-06 at 13:23 +0200, Pavel Labath wrote:
> On 25/08/2021 21:13, Michał Górny via lldb-dev wrote:
> > Hi,
> > 
> > While working on improving gdbserver compatibility, I've noticed that
> > "sp" is used twice:
> > 
> > 1. as an alt_name for esp/rsp register (giving full 32/64-bit stack
> > pointer),
> > 
> > 2. and as the name of sp pseudo-register (giving ESP/RSP truncated to 16
> > bits).
> > 
> > FWICS the current lookup logic (at least for LLGS targets) means that 1.
> > takes precedence, i.e. 'register read sp' and 'p $sp' will both resolve
> > to RSP.  The 16-bit SP is only visible via 'register read --all'.
> > 
> > However, I'm wondering whether this is actually desirable.
> > In particular, should 'sp' generic name take precedence over an actual
> > 'sp' (pseudo-)register?
> > 
> 
> Given that accessing the lower 16 bits of the stack pointer is pretty 
> useless, and I can think of several use cases for accessing the (full) 
> stack pointer in an architecture-agnostic way, I think that the current 
> precedence is right.

Thanks, this makes sense to me.

> 
> Which is not to say that the situation is ideal, but I'm not sure what 
> can we (short of travelling back in time) do about it. Maybe we can 
> provide some alias (sp_16, sp_86, ???), so that the register remains 
> addressable?
> 

I was originally thinking of "_sp" but I suppose more specific names
make more sense ;-).  That said, I guess it can probably wait until
someone actually sees a need for it.

-- 
Best regards,
Michał Górny


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