llvm-project/lldb/source/Plugins/SymbolFile/PDB/SymbolFilePDBProperties.td
nerix 7b208e04b2
[LLDB] Add setting for native PDB reader (#151490)
Initially suggested in
https://github.com/llvm/llvm-project/pull/149305#issuecomment-3113413702
- this PR adds the setting `plugin.symbol-file.pdb.use-native-reader`.
It doesn't remove support for `LLDB_USE_NATIVE_PDB_READER` to allow some
backwards compatibility. This was the suggested way to use the native
reader - changing that would mean users who set this, now use the DIA
reader. The setting has priority over the environment variable, though.
If the default gets flipped on Windows, the environment variable could
probably be removed as well.

This would make it possible to test both native PDB and DIA PDB in the
API tests (see linked PR).
2025-08-04 09:43:01 -07:00

15 lines
810 B
TableGen

include "../../../../include/lldb/Core/PropertiesBase.td"
let Definition = "symbolfilepdb" in {
def Reader: Property<"reader", "Enum">,
Global,
DefaultEnumValue<"ePDBReaderDefault">,
EnumValues<"OptionEnumValues(g_pdb_reader_enums)">,
Desc<"Selects the reader for PDB symbol files. "
"The native PDB reader that uses LLVM's PDB support is always available (value: 'native'). "
"Secondly, the DIA PDB reader is only available if LLVM was comppiled with Microsoft's DIA SDK on Windows (value: 'DIA'). "
"By default, the DIA PDB reader is used if available. "
"The LLDB_USE_NATIVE_PDB_READER environment variable can be used to switch to the native reader when this setting has the default value. "
"Otherwise, the setting always has priority.">;
}