Re: [edk2] [PATCH v5 6/9] OvmfPkg: AcpiTimerLib: Use global variable during PEI_CORE and PEIM

Subject: Re: [edk2] [PATCH v5 6/9] OvmfPkg: AcpiTimerLib: Use global variable during PEI_CORE and PEIM

From: Andrew Fish <afish@apple.com>

To: Jordan Justen <jordan.l.justen@intel.com>

Date: 2014-11-13 03:48:43


On Nov 12, 2014, at 7:00 PM, Jordan Justen <jordan.l.justen@intel.com> wrote:

On 2014-11-12 18:16:59, Andrew Fish wrote:
On Nov 12, 2014, at 5:49 PM, Jordan Justen <jordan.l.justen@intel.com> wrote:
On 2014-11-12 16:22:59, Andrew Fish wrote:
I assumed there would be a Python script to convert to WinDBG to
gdb-remote.

Hmm. That sounds horrible. Luckily, *I think* it actually has improved
from this point. I'm not sure though.

Well it is just bits 

Saying that 'it is just bits' doesn't make it easy to setup, easy to
use, or stable.

Are there just not scripts to load symbols with gdb? 

Yeah, I kind of had something for this working. Mode changing kind of
confused things. I think it might useable in some scenarios.


Now you mention it I remember seeing some issue about gdb in that
regard. 

I wonder if you could create a gdb connection, manually send a a
packet, use the response from that packet to launch gdb for the
correct CPU arch.

In lldb we figure out the CPU mode as part of the connect sequence.
We can reconnect and reload symbols after a mode change without
exiting the debugger.

Something that was lldb based would be fine with me if the full stack
was open source, it was easy to setup and stable.

Unfortunately the QEMU gdb-remote is too primitive for lldb right now. So Id have to write some Python to pipe the connection through to dumb it down to speak to QEMU :(. 

All the lldb bits you would need are open source: http://lldb.llvm.org/download.html

There is an lldb script checked in for the Emulator, but it does not have magic to load symbols on real hardware. 
https://svn.code.sf.net/p/edk2/code/trunk/edk2/EmulatorPkg/Unix/lldbefi.py

Thanks,

Andrew Fish