diff options
author | GeorgeHuyubo <113479859+GeorgeHuyubo@users.noreply.github.com> | 2023-11-17 09:53:12 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-17 09:53:12 -0800 |
commit | e2fb816c4f0286ddf8b1030148a343d5efc14e01 (patch) | |
tree | 29a5cf8418152c7053c13d42322358488b753f57 /llvm/lib/Object/ELF.cpp | |
parent | 4263b2ecf8c4b9b62094a731bb92c501197531b0 (diff) | |
download | llvm-e2fb816c4f0286ddf8b1030148a343d5efc14e01.zip llvm-e2fb816c4f0286ddf8b1030148a343d5efc14e01.tar.gz llvm-e2fb816c4f0286ddf8b1030148a343d5efc14e01.tar.bz2 |
Add new API in SBTarget for loading core from SBFile (#71769)
Add a new API in SBTarget to Load Core from a SBFile.
This will enable a target to load core from a file descriptor.
So that in coredumper, we don't need to write core file to disk, instead
we can pass the input file descriptor to lldb directly.
Test:
```
(lldb) script
Python Interactive Interpreter. To exit, type 'quit()', 'exit()' or Ctrl-D.
>>> file_object = open("/home/hyubo/210hda79ms32sr0h", "r")
>>> fd=file_object.fileno()
>>> file = lldb.SBFile(fd,'r', True)
>>> error = lldb.SBError()
>>> target = lldb.debugger.CreateTarget(None)
>>> target.LoadCore(file,error)
SBProcess: pid = 56415, state = stopped, threads = 1
```
Diffstat (limited to 'llvm/lib/Object/ELF.cpp')
0 files changed, 0 insertions, 0 deletions