[Lldb-commits] [PATCH] D46669: Retrieve the deployment target when retrieving an object file's triple

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu May 10 01:40:05 PDT 2018


labath added a comment.

The test you copied this from predates `lldb-test` (and it tests some behavior quirks which are not nicely expressible in text output). We should have nicer ways of testing things like this now. It should be sufficient to add a print line which displays the triple in the `dumpModules` function in `lldb-test.cpp`. Then you can just run `lldb-test module-sections your-file` and FileCheck that.

The other thing you will need to do is make this test darwin-only as right now our MachO parsing code does not work on non-apple platforms. The reason for that is very silly - ObjectFileMachO depends on RegisterContextDarwin_XXX (presumably to read register information from core files), which use constants like `KERN_SUCCESS` from system headers. (I've looked at this recently because I wanted to make some cross-platform tests for apple debug info and got stuck here.)


https://reviews.llvm.org/D46669





More information about the lldb-commits mailing list