Skip to content

Commit 994fe32

Browse files
Revert "Add new llvm.dbg.coroframe_entry intrinsic."
This reverts commit e88254b.
1 parent 26af861 commit 994fe32

16 files changed

+0
-179
lines changed

llvm/docs/SourceLevelDebugging.rst

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -401,21 +401,6 @@ This intrinsic is equivalent to ``#dbg_assign``:
401401
metadata ptr %i.addr, metadata !DIExpression(), metadata !3), !dbg !3
402402
403403
404-
``llvm.dbg.coroframe_entry``
405-
^^^^^^^^^^^^^^^^^^^^
406-
407-
.. code-block:: llvm
408-
409-
void @llvm.dbg.coroframe_entry(metadata, metadata, metadata)
410-
411-
This intrinsic is equivalent to ``#dbg_coroframe_entry``:
412-
413-
.. code-block:: llvm
414-
415-
#dbg_coroframe_entry(i32 %i., !1, !DIExpression(), !2)
416-
call void @llvm.dbg.coroframe_entry(metadata i32 %i., metadata !1,
417-
metadata !DIExpression()), !dbg !2
418-
419404
Object lifetimes and scoping
420405
============================
421406

llvm/include/llvm/Bitcode/LLVMBitCodes.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -687,8 +687,6 @@ enum FunctionCodes {
687687
FUNC_CODE_DEBUG_RECORD_VALUE_SIMPLE =
688688
64, // [DILocation, DILocalVariable, DIExpression, Value]
689689
FUNC_CODE_DEBUG_RECORD_LABEL = 65, // [DILocation, DILabel]
690-
FUNC_CODE_DEBUG_RECORD_COROFRAME_ENTRY =
691-
66, // [DILocation, DILocalVariable, DIExpression, ValueAsMetadata]
692690
};
693691

694692
enum UseListCodes {

llvm/include/llvm/IR/DIBuilder.h

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1155,18 +1155,6 @@ namespace llvm {
11551155
DIExpression *Expr, const DILocation *DL,
11561156
InsertPosition InsertPt);
11571157

1158-
/// Insert a new llvm.dbg.coroframe_entry intrinsic call.
1159-
/// \param Storage llvm::Value of the variable
1160-
/// \param VarInfo Variable's debug info descriptor.
1161-
/// \param Expr A complex location expression.
1162-
/// \param DL Debug info location.
1163-
/// \param InsertPt Location for the new intrinsic.
1164-
LLVM_ABI DbgInstPtr insertCoroFrameEntry(llvm::Value *Storage,
1165-
DILocalVariable *VarInfo,
1166-
DIExpression *Expr,
1167-
const DILocation *DL,
1168-
InsertPosition InsertPt);
1169-
11701158
/// Insert a new llvm.dbg.label intrinsic call.
11711159
/// \param LabelInfo Label's debug info descriptor.
11721160
/// \param DL Debug info location.

llvm/include/llvm/IR/DebugInfo.h

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -44,15 +44,6 @@ class Module;
4444
LLVM_ABI TinyPtrVector<DbgDeclareInst *> findDbgDeclares(Value *V);
4545
/// As above, for DVRDeclares.
4646
LLVM_ABI TinyPtrVector<DbgVariableRecord *> findDVRDeclares(Value *V);
47-
/// Finds dbg.coroframe_entry intrinsics declaring local variables as living in
48-
/// the memory that 'V' points to.
49-
// FIXME: Combine the findDbgCoroFrameEntrys and findDbgDeclares APIs into one
50-
// that can take a 'kind' parameter, do the same for findDVRCoroFrameEntrys and
51-
// findDVRCoroFrameEntrys
52-
LLVM_ABI TinyPtrVector<DbgCoroFrameEntryInst *>
53-
findDbgCoroFrameEntrys(Value *V);
54-
/// As above, for DVRCoroFrameEntrys.
55-
LLVM_ABI TinyPtrVector<DbgVariableRecord *> findDVRCoroFrameEntrys(Value *V);
5647
/// As above, for DVRValues.
5748
LLVM_ABI TinyPtrVector<DbgVariableRecord *> findDVRValues(Value *V);
5849

llvm/include/llvm/IR/DebugProgramInstruction.h

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,6 @@ class DbgVariableRecord : public DbgRecord, protected DebugValueUser {
282282
Declare,
283283
Value,
284284
Assign,
285-
CoroFrameEntry,
286285

287286
End, ///< Marks the end of the concrete types.
288287
Any, ///< To indicate all LocationTypes in searches.
@@ -365,14 +364,6 @@ class DbgVariableRecord : public DbgRecord, protected DebugValueUser {
365364
createDVRDeclare(Value *Address, DILocalVariable *DV, DIExpression *Expr,
366365
const DILocation *DI, DbgVariableRecord &InsertBefore);
367366

368-
LLVM_ABI static DbgVariableRecord *
369-
createDVRCoroFrameEntry(Value *Address, DILocalVariable *DV,
370-
DIExpression *Expr, const DILocation *DI);
371-
LLVM_ABI static DbgVariableRecord *
372-
createDVRCoroFrameEntry(Value *Address, DILocalVariable *DV,
373-
DIExpression *Expr, const DILocation *DI,
374-
DbgVariableRecord &InsertBefore);
375-
376367
/// Iterator for ValueAsMetadata that internally uses direct pointer iteration
377368
/// over either a ValueAsMetadata* or a ValueAsMetadata**, dereferencing to the
378369
/// ValueAsMetadata .
@@ -423,9 +414,6 @@ class DbgVariableRecord : public DbgRecord, protected DebugValueUser {
423414

424415
bool isDbgDeclare() const { return Type == LocationType::Declare; }
425416
bool isDbgValue() const { return Type == LocationType::Value; }
426-
bool isDbgCoroFrameEntry() const {
427-
return Type == LocationType::CoroFrameEntry;
428-
}
429417

430418
/// Get the locations corresponding to the variable referenced by the debug
431419
/// info intrinsic. Depending on the intrinsic, this could be the

llvm/include/llvm/IR/IntrinsicInst.h

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -428,7 +428,6 @@ class DbgVariableIntrinsic : public DbgInfoIntrinsic {
428428
case Intrinsic::dbg_declare:
429429
case Intrinsic::dbg_value:
430430
case Intrinsic::dbg_assign:
431-
case Intrinsic::dbg_coroframe_entry:
432431
return true;
433432
default:
434433
return false;
@@ -465,26 +464,6 @@ class DbgDeclareInst : public DbgVariableIntrinsic {
465464
/// @}
466465
};
467466

468-
/// This represents the llvm.dbg.coro instruction.
469-
class DbgCoroFrameEntryInst : public DbgVariableIntrinsic {
470-
public:
471-
Value *getAddress() const {
472-
assert(getNumVariableLocationOps() == 1 &&
473-
"dbg.coro must have exactly 1 location operand.");
474-
return getVariableLocationOp(0);
475-
}
476-
477-
/// \name Casting methods
478-
/// @{
479-
static bool classof(const IntrinsicInst *I) {
480-
return I->getIntrinsicID() == Intrinsic::dbg_coroframe_entry;
481-
}
482-
static bool classof(const Value *V) {
483-
return isa<IntrinsicInst>(V) && classof(cast<IntrinsicInst>(V));
484-
}
485-
/// @}
486-
};
487-
488467
/// This represents the llvm.dbg.value instruction.
489468
class DbgValueInst : public DbgVariableIntrinsic {
490469
public:

llvm/include/llvm/IR/Intrinsics.td

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1474,10 +1474,6 @@ let IntrProperties = [IntrNoMem, IntrSpeculatable] in {
14741474
llvm_metadata_ty]>;
14751475
def int_dbg_label : DefaultAttrsIntrinsic<[],
14761476
[llvm_metadata_ty]>;
1477-
def int_dbg_coroframe_entry : DefaultAttrsIntrinsic<[],
1478-
[llvm_metadata_ty,
1479-
llvm_metadata_ty,
1480-
llvm_metadata_ty]>;
14811477
}
14821478

14831479
//===------------------ Exception Handling Intrinsics----------------------===//

llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,6 @@ GetCodeName(unsigned CodeID, unsigned BlockID,
272272
STRINGIFY_CODE(FUNC_CODE, INST_CALLBR)
273273
STRINGIFY_CODE(FUNC_CODE, BLOCKADDR_USERS)
274274
STRINGIFY_CODE(FUNC_CODE, DEBUG_RECORD_DECLARE)
275-
STRINGIFY_CODE(FUNC_CODE, DEBUG_RECORD_COROFRAME_ENTRY)
276275
STRINGIFY_CODE(FUNC_CODE, DEBUG_RECORD_VALUE)
277276
STRINGIFY_CODE(FUNC_CODE, DEBUG_RECORD_ASSIGN)
278277
STRINGIFY_CODE(FUNC_CODE, DEBUG_RECORD_VALUE_SIMPLE)

llvm/lib/Bitcode/Reader/BitcodeReader.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6644,7 +6644,6 @@ Error BitcodeReader::parseFunctionBody(Function *F) {
66446644
case bitc::FUNC_CODE_DEBUG_RECORD_VALUE_SIMPLE:
66456645
case bitc::FUNC_CODE_DEBUG_RECORD_VALUE:
66466646
case bitc::FUNC_CODE_DEBUG_RECORD_DECLARE:
6647-
case bitc::FUNC_CODE_DEBUG_RECORD_COROFRAME_ENTRY:
66486647
case bitc::FUNC_CODE_DEBUG_RECORD_ASSIGN: {
66496648
// DbgVariableRecords are placed after the Instructions that they are
66506649
// attached to.
@@ -6661,8 +6660,6 @@ Error BitcodeReader::parseFunctionBody(Function *F) {
66616660
// ..., Value
66626661
// dbg_declare (FUNC_CODE_DEBUG_RECORD_DECLARE)
66636662
// ..., LocationMetadata
6664-
// dbg_coroframe_entry (FUNC_CODE_DEBUG_RECORD_COROFRAME_ENTRY)
6665-
// ..., LocationMetadata
66666663
// dbg_assign (FUNC_CODE_DEBUG_RECORD_ASSIGN)
66676664
// ..., LocationMetadata, DIAssignID, DIExpression, LocationMetadata
66686665
unsigned Slot = 0;
@@ -6704,11 +6701,6 @@ Error BitcodeReader::parseFunctionBody(Function *F) {
67046701
DVR = new DbgVariableRecord(RawLocation, Var, Expr, DIL,
67056702
DbgVariableRecord::LocationType::Declare);
67066703
break;
6707-
case bitc::FUNC_CODE_DEBUG_RECORD_COROFRAME_ENTRY:
6708-
DVR = new DbgVariableRecord(
6709-
RawLocation, Var, Expr, DIL,
6710-
DbgVariableRecord::LocationType::CoroFrameEntry);
6711-
break;
67126704
case bitc::FUNC_CODE_DEBUG_RECORD_ASSIGN: {
67136705
DIAssignID *ID = cast<DIAssignID>(getFnMetadataByID(Record[Slot++]));
67146706
DIExpression *AddrExpr =

llvm/lib/Bitcode/Writer/BitcodeWriter.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3828,10 +3828,6 @@ void ModuleBitcodeWriter::writeFunction(
38283828
} else if (DVR.isDbgDeclare()) {
38293829
Vals.push_back(VE.getMetadataID(DVR.getRawLocation()));
38303830
Stream.EmitRecord(bitc::FUNC_CODE_DEBUG_RECORD_DECLARE, Vals);
3831-
} else if (DVR.isDbgCoroFrameEntry()) {
3832-
Vals.push_back(VE.getMetadataID(DVR.getRawLocation()));
3833-
Stream.EmitRecord(bitc::FUNC_CODE_DEBUG_RECORD_COROFRAME_ENTRY,
3834-
Vals);
38353831
} else {
38363832
assert(DVR.isDbgAssign() && "Unexpected DbgRecord kind");
38373833
Vals.push_back(VE.getMetadataID(DVR.getRawLocation()));

0 commit comments

Comments
 (0)