llvm.org GIT mirror llvm / 98e3b1a
Revert "Bitcode: Move the DEBUG_LOC record to DEBUG_LOC_OLD" This reverts commit r225498 (but leaves r225499, which was a worthy cleanup). My plan was to change `DEBUG_LOC` to store the `MDNode` directly rather than its operands (patch was to go out this morning), but on reflection it's not clear that it's strictly better. (I had missed that the current code is unlikely to emit the `MDNode` at all.) Conflicts: lib/Bitcode/Reader/BitcodeReader.cpp (due to r225499) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225531 91177308-0d34-0410-b5e6-96231b3b80d8 Duncan P. N. Exon Smith 4 years ago
4 changed file(s) with 4 addition(s) and 4 deletion(s). Raw diff Collapse all Expand all
313313
314314 FUNC_CODE_INST_CALL = 34, // CALL: [attr, cc, fnty, fnid, args...]
315315
316 FUNC_CODE_DEBUG_LOC_OLD = 35, // DEBUG_LOC: [Line,Col,ScopeVal, IAVal]
316 FUNC_CODE_DEBUG_LOC = 35, // DEBUG_LOC: [Line,Col,ScopeVal, IAVal]
317317 FUNC_CODE_INST_FENCE = 36, // FENCE: [ordering, synchscope]
318318 FUNC_CODE_INST_CMPXCHG = 37, // CMPXCHG: [ptrty,ptr,cmp,new, align, vol,
319319 // ordering, synchscope]
25602560 I = nullptr;
25612561 continue;
25622562
2563 case bitc::FUNC_CODE_DEBUG_LOC_OLD: { // DEBUG_LOC_OLD: [line,col,scope,ia]
2563 case bitc::FUNC_CODE_DEBUG_LOC: { // DEBUG_LOC: [line, col, scope, ia]
25642564 I = getLastInstruction();
25652565 if (!I || Record.size() < 4)
25662566 return Error(BitcodeError::InvalidRecord);
17171717 Vals.push_back(DL.getCol());
17181718 Vals.push_back(Scope ? VE.getMetadataID(Scope) + 1 : 0);
17191719 Vals.push_back(IA ? VE.getMetadataID(IA) + 1 : 0);
1720 Stream.EmitRecord(bitc::FUNC_CODE_DEBUG_LOC_OLD, Vals);
1720 Stream.EmitRecord(bitc::FUNC_CODE_DEBUG_LOC, Vals);
17211721 Vals.clear();
17221722
17231723 LastDL = DL;
246246 case bitc::FUNC_CODE_INST_VSELECT: return "INST_VSELECT";
247247 case bitc::FUNC_CODE_DEBUG_LOC_AGAIN: return "DEBUG_LOC_AGAIN";
248248 case bitc::FUNC_CODE_INST_CALL: return "INST_CALL";
249 case bitc::FUNC_CODE_DEBUG_LOC_OLD: return "DEBUG_LOC_OLD";
249 case bitc::FUNC_CODE_DEBUG_LOC: return "DEBUG_LOC";
250250 }
251251 case bitc::VALUE_SYMTAB_BLOCK_ID:
252252 switch (CodeID) {