[Lldb-commits] [PATCH] D55718: [ARC] Basic support in gdb-remote process plugin

Tatyana Krasnukha via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Dec 19 11:32:11 PST 2018

tatyana-krasnukha added inline comments.

Comment at: source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp:4707
+        arc::AdjustRegisterInfo(m_register_info, arch_to_use);
clayborg wrote:
> ok, makes sense. Clearing the register info would be a good idea. One extra question: why do we need to fix up this information? Does it come over incorrectly and in the XML data and then need to be fixed up? I would prefer to fix the data if possible so this doesn't have to be done. Another way to make things work when registers are incorrect is to specify a target definition file for GDB remote with:
> ```
> (lldb) settings set plugin.process.gdb-remote.target-definition-file /path/to/regs.py
> ```
"dwarf" field doesn't exist in standard target register description given by a gdb-server (it looks like an LLDB's extension), that's why the adjustment is required.

Since the ARC is a configurable architecture, we have to create a huge count of regs.py files. This is not only ARC_rf16/ARC_rf32, some modules like floating point unit may be disabled in current configuration and related registers are absent.

As an alternative way we could have a super-target-definition-file with full set of possible registers and remove absent registers during this step. But I don't think it is much better than current adjustment.




More information about the lldb-commits mailing list