Author: asmith Date: Thu Mar 22 12:21:34 2018 New Revision: 328230 URL: http://llvm.org/viewvc/llvm-project?rev=328230&view=rev Log: [SymbolFilePDB] Ignore compiler generated functions when creating the LLDB type from a PDB
Modified: lldb/trunk/source/Plugins/SymbolFile/PDB/PDBASTParser.cpp lldb/trunk/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp Modified: lldb/trunk/source/Plugins/SymbolFile/PDB/PDBASTParser.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/PDB/PDBASTParser.cpp?rev=328230&r1=328229&r2=328230&view=diff ============================================================================== --- lldb/trunk/source/Plugins/SymbolFile/PDB/PDBASTParser.cpp (original) +++ lldb/trunk/source/Plugins/SymbolFile/PDB/PDBASTParser.cpp Thu Mar 22 12:21:34 2018 @@ -312,6 +312,9 @@ lldb::TypeSP PDBASTParser::CreateLLDBTyp std::string name; PDBSymbolTypeFunctionSig *func_sig = nullptr; if (auto pdb_func = llvm::dyn_cast<PDBSymbolFunc>(&type)) { + if (pdb_func->isCompilerGenerated()) + return nullptr; + auto sig = pdb_func->getSignature(); if (!sig) return nullptr; Modified: lldb/trunk/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp?rev=328230&r1=328229&r2=328230&view=diff ============================================================================== --- lldb/trunk/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp (original) +++ lldb/trunk/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp Thu Mar 22 12:21:34 2018 @@ -130,7 +130,7 @@ uint32_t SymbolFilePDB::CalculateAbiliti } } } - if (!m_session_up.get()) + if (!m_session_up) return 0; auto enum_tables_up = m_session_up->getEnumTables(); @@ -507,7 +507,7 @@ lldb_private::Type *SymbolFilePDB::Resol return nullptr; lldb::TypeSP result = pdb->CreateLLDBTypeFromPDBType(*pdb_type); - if (result.get()) { + if (result) { m_types.insert(std::make_pair(type_uid, result)); auto type_list = GetTypeList(); if (type_list) @@ -637,7 +637,7 @@ uint32_t SymbolFilePDB::ResolveSymbolCon SymbolContext sc; auto cu = ParseCompileUnitForUID(compiland->getSymIndexId()); - if (!cu.get()) + if (!cu) continue; sc.comp_unit = cu.get(); sc.module_sp = cu->GetModule(); @@ -1132,7 +1132,7 @@ size_t SymbolFilePDB::GetTypes(lldb_priv } else { for (uint32_t cu_idx = 0; cu_idx < GetNumCompileUnits(); ++cu_idx) { auto cu_sp = ParseCompileUnitAtIndex(cu_idx); - if (cu_sp.get()) { + if (cu_sp) { if (auto compiland_up = GetPDBCompilandByUID(cu_sp->GetID())) GetTypesForPDBSymbol(*compiland_up, type_mask, type_collection); } _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits