[Lldb-commits] [PATCH] D127234: [lldb] Add setting to override PE/COFF ABI by module name

David Spickett via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Mon Jun 20 07:00:17 PDT 2022


DavidSpickett added a reviewer: DavidSpickett.
DavidSpickett added inline comments.


================
Comment at: lldb/source/Plugins/ObjectFile/PECOFF/ObjectFilePECOFFProperties.td:13
+    EnumValues<"OptionEnumValues(g_abi_enums)">,
+    Desc<"A mapping of ABI override to use for specific modules. The module name is matched by its file name with extension. These versions are checked in sequence: exact, lowercase, exact with '.debug' suffix stripped, lowercase with '.debug' suffix stripped.">;
 }
----------------
What are the values accepted for this?


================
Comment at: lldb/test/Shell/ObjectFile/PECOFF/settings-abi.yaml:37
+# RUN:   FileCheck -DABI=msvc -DFILENAME=%basename_t.tmp.debug %s
+
 # CHECK-LABEL: image list --triple --basename
----------------
You should test that `UPPER_CASE` and `UPPER_CASE.debug` still find the module abi.

I think you could test the priority order too.

Start with 1 setting `foo=msvc`, check it gets msvc.
Add the next highest priority `Foo=gnu`, check it gets gnu.
Remove `foo=msvc`, add the next highest priority as `foo.debug=msvc`, check it gets msvc.
Remove `Foo=gnu` and add `Foo.debug=gnu`, check it gets gnu.

At each stage you're proving that it'll choose one of a pair, put that all together you've proved the order overall.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D127234/new/

https://reviews.llvm.org/D127234



More information about the lldb-commits mailing list