[Lldb-commits] [lldb] r361672 - [DWARFExpression] Remove commented-out code (NFC)
Jonas Devlieghere via lldb-commits
lldb-commits at lists.llvm.org
Fri May 24 14:26:30 PDT 2019
Author: jdevlieghere
Date: Fri May 24 14:26:30 2019
New Revision: 361672
URL: http://llvm.org/viewvc/llvm-project?rev=361672&view=rev
Log:
[DWARFExpression] Remove commented-out code (NFC)
Modified:
lldb/trunk/source/Expression/DWARFExpression.cpp
Modified: lldb/trunk/source/Expression/DWARFExpression.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Expression/DWARFExpression.cpp?rev=361672&r1=361671&r2=361672&view=diff
==============================================================================
--- lldb/trunk/source/Expression/DWARFExpression.cpp (original)
+++ lldb/trunk/source/Expression/DWARFExpression.cpp Fri May 24 14:26:30 2019
@@ -483,23 +483,6 @@ void DWARFExpression::DumpLocation(Strea
case DW_OP_call_ref: // 0x9a DWARF3 1 4- or 8-byte offset of DIE
s->Printf("DW_OP_call_ref(0x%8.8" PRIx64 ")", m_data.GetAddress(&offset));
break;
- // case DW_OP_call_frame_cfa: s << "call_frame_cfa"; break;
- // // 0x9c DWARF3
- // case DW_OP_bit_piece: // 0x9d DWARF3 2
- // s->Printf("DW_OP_bit_piece(0x%x, 0x%x)",
- // m_data.GetULEB128(&offset), m_data.GetULEB128(&offset));
- // break;
- // case DW_OP_lo_user: s->PutCString("DW_OP_lo_user"); break;
- // // 0xe0
- // case DW_OP_hi_user: s->PutCString("DW_OP_hi_user"); break;
- // // 0xff
- // case DW_OP_APPLE_extern:
- // s->Printf("DW_OP_APPLE_extern(%" PRIu64 ")",
- // m_data.GetULEB128(&offset));
- // break;
- // case DW_OP_APPLE_array_ref:
- // s->PutCString("DW_OP_APPLE_array_ref");
- // break;
case DW_OP_form_tls_address:
s->PutCString("DW_OP_form_tls_address"); // 0x9b
break;
@@ -521,62 +504,6 @@ void DWARFExpression::DumpLocation(Strea
case DW_OP_APPLE_uninit:
s->PutCString("DW_OP_APPLE_uninit"); // 0xF0
break;
- // case DW_OP_APPLE_assign: // 0xF1 - pops value off and
- // assigns it to second item on stack (2nd item must have
- // assignable context)
- // s->PutCString("DW_OP_APPLE_assign");
- // break;
- // case DW_OP_APPLE_address_of: // 0xF2 - gets the address of
- // the top stack item (top item must be a variable, or have
- // value_type that is an address already)
- // s->PutCString("DW_OP_APPLE_address_of");
- // break;
- // case DW_OP_APPLE_value_of: // 0xF3 - pops the value off the
- // stack and pushes the value of that object (top item must be a
- // variable, or expression local)
- // s->PutCString("DW_OP_APPLE_value_of");
- // break;
- // case DW_OP_APPLE_deref_type: // 0xF4 - gets the address of
- // the top stack item (top item must be a variable, or a clang
- // type)
- // s->PutCString("DW_OP_APPLE_deref_type");
- // break;
- // case DW_OP_APPLE_expr_local: // 0xF5 - ULEB128 expression
- // local index
- // s->Printf("DW_OP_APPLE_expr_local(%" PRIu64 ")",
- // m_data.GetULEB128(&offset));
- // break;
- // case DW_OP_APPLE_constf: // 0xF6 - 1 byte float size,
- // followed by constant float data
- // {
- // uint8_t float_length = m_data.GetU8(&offset);
- // s->Printf("DW_OP_APPLE_constf(<%u> ", float_length);
- // m_data.Dump(s, offset, eFormatHex, float_length, 1,
- // UINT32_MAX, DW_INVALID_ADDRESS, 0, 0);
- // s->PutChar(')');
- // // Consume the float data
- // m_data.GetData(&offset, float_length);
- // }
- // break;
- // case DW_OP_APPLE_scalar_cast:
- // s->Printf("DW_OP_APPLE_scalar_cast(%s)",
- // Scalar::GetValueTypeAsCString
- // ((Scalar::Type)m_data.GetU8(&offset)));
- // break;
- // case DW_OP_APPLE_clang_cast:
- // {
- // clang::Type *clang_type = (clang::Type
- // *)m_data.GetMaxU64(&offset, sizeof(void*));
- // s->Printf("DW_OP_APPLE_clang_cast(%p)", clang_type);
- // }
- // break;
- // case DW_OP_APPLE_clear:
- // s->PutCString("DW_OP_APPLE_clear");
- // break;
- // case DW_OP_APPLE_error: // 0xFF - Stops expression
- // evaluation and returns an error (no args)
- // s->PutCString("DW_OP_APPLE_error");
- // break;
}
}
}
@@ -691,52 +618,6 @@ static bool ReadRegisterValueAsScalar(Re
return false;
}
-// bool
-// DWARFExpression::LocationListContainsLoadAddress (Process* process, const
-// Address &addr) const
-//{
-// return LocationListContainsLoadAddress(process,
-// addr.GetLoadAddress(process));
-//}
-//
-// bool
-// DWARFExpression::LocationListContainsLoadAddress (Process* process, addr_t
-// load_addr) const
-//{
-// if (load_addr == LLDB_INVALID_ADDRESS)
-// return false;
-//
-// if (IsLocationList())
-// {
-// lldb::offset_t offset = 0;
-//
-// addr_t loc_list_base_addr = m_loclist_slide.GetLoadAddress(process);
-//
-// if (loc_list_base_addr == LLDB_INVALID_ADDRESS)
-// return false;
-//
-// while (m_data.ValidOffset(offset))
-// {
-// // We need to figure out what the value is for the location.
-// addr_t lo_pc = m_data.GetAddress(&offset);
-// addr_t hi_pc = m_data.GetAddress(&offset);
-// if (lo_pc == 0 && hi_pc == 0)
-// break;
-// else
-// {
-// lo_pc += loc_list_base_addr;
-// hi_pc += loc_list_base_addr;
-//
-// if (lo_pc <= load_addr && load_addr < hi_pc)
-// return true;
-//
-// offset += m_data.GetU16(&offset);
-// }
-// }
-// }
-// return false;
-//}
-
static offset_t GetOpcodeDataSize(const DataExtractor &data,
const lldb::offset_t data_offset,
const uint8_t op) {
More information about the lldb-commits
mailing list