[llvm] [RemoveDIs] Update DIBuilder C API with DbgRecord functions. (PR #95535)
Carlos Alberto Enciso via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 14 07:13:25 PDT 2024
================
@@ -137,38 +140,13 @@ int llvm_test_dibuilder(bool NewDebugInfoFormat) {
LLVMDIBuilderCreateParameterVariable(DIB, FunctionMetadata, "a", 1, 1, File,
42, Int64Ty, true, 0);
- if (LLVMIsNewDbgInfoFormat(M))
- LLVMDIBuilderInsertDeclareAtEnd(
- DIB, LLVMConstInt(LLVMInt64Type(), 0, false), FooParamVar1,
- FooParamExpression, FooParamLocation, FooEntryBlock);
- else
- LLVMDIBuilderInsertDeclareIntrinsicAtEnd(
- DIB, LLVMConstInt(LLVMInt64Type(), 0, false), FooParamVar1,
- FooParamExpression, FooParamLocation, FooEntryBlock);
----------------
CarlosAlbertoEnciso wrote:
Good point.
Added for all 3: `FooParamVar1`, `FooParamVar2`, `FooParamVar3`
```
LLVMDIBuilderInsertDeclareRecordAtEnd(
DIB, LLVMConstInt(LLVMInt64Type(), 0, false), FooParamVar1,
FooParamExpression, FooParamLocation, FooEntryBlock);
```
https://github.com/llvm/llvm-project/pull/95535
More information about the llvm-commits
mailing list