Issue |
135840
|
Summary |
[LLDB] MIPS, incorrect byte order issues with `Cast` and `p/x`
|
Labels |
new issue
|
Assignees |
|
Reporter |
patryk4815
|
Similar bug as in:
- https://github.com/llvm/llvm-project/issues/135707
(btw qemu-mips don't work - I don't know why, probably qemu issue)
Steps to reproduction:
My small openwrt TP-LINK Switch with ~18MB disk space:
```
root@OpenWrt:/tmp# ./gdbserver 0:1234 /bin/sh
Process /bin/sh created; pid = 4445
Listening on port 1234
```
(not possible to build lldb-server, to fit there)
My host:
```
(lldb) file ./sh
Current executable set to '/tmp/dd/sh' (mipsr2).
(lldb) log enable gdb-remote all
(lldb) gdb-remote 192.168.1.1:1234
Process 4445 stopped
* thread #1, stop reason = signal SIGTRAP
frame #0: 0x77f3abc0
-> 0x77f3abc0: bal 0x77f3abd4
0x77f3abc4: move $fp, $zero
(lldb)
(lldb) register read sp
r29 = 0x7fffbda0
(lldb) p/x $sp
(unsigned int) 0xa0bdff7f
```
`p/x $sp` should return `0x7fffbda0`, but instead I see: `0xa0bdff7f`
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs