kazutakahirata wrote:

> LGTM. Is DXIL the only remaining user? (We also have 
> Instruction::isDebugOrPseudoInst(), which should (probably separately) be 
> replaced with `isa<PseudoProbeInst>()` or removed (with preference to 
> removal).)

Thanks for the review!

Yes. In production `llvm/` code, the DirectX backend is the only remaining 
caller of `Module::convertFromNewDbgValues()` in `DXILDebugInfo.cpp`, which 
materializes `DbgRecord`s back into debug intrinsics right before serializing 
to LLVM 3.7-based DXIL bitcode.

Outside of DirectX, the only remaining references to `Dbg*Intrinsic` / 
`Intrinsic::dbg_*` are:
- The bitcode/IR reader upgrade path:
  - `AutoUpgrade.cpp`
  - `BitcodeReader.cpp`
  - `LLParser.cpp`
- Dead debug-intrinsic handling in subprojects:
  - `mlir/lib/Target/LLVMIR/ModuleImport.cpp`
  - `lldb/source/Expression/IRInterpreter.cpp`
- `StripDebugDeclarePass` in `StripSymbols.cpp`, which only checks for 
`Intrinsic::dbg_declare` and is now a no-op
- `LLVM_FOR_EACH_VALUE_SUBCLASS` in `llvm-c/Core.h`
- Unit tests:
  - `BitReaderTest.cpp`
  - `CloningTest.cpp`
  - `DebugInfoTest.cpp`
  - `MetadataTest.cpp`

Agreed on `Instruction::isDebugOrPseudoInst()`. I'll follow up with a separate 
patch to replace its call sites with `isa<PseudoProbeInst>()` and remove 
`Instruction::isDebugOrPseudoInst()`.

https://github.com/llvm/llvm-project/pull/231379
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to