comparison lib/DebugInfo/PDB/PDB.cpp @ 95:afa8332a0e37 LLVM3.8

LLVM 3.8
author Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
date Tue, 13 Oct 2015 17:48:58 +0900
parents 60c9769439b8
children 7d135dc70f03
comparison
equal deleted inserted replaced
84:f3e34b893a5f 95:afa8332a0e37
18 #include "llvm/DebugInfo/PDB/DIA/DIASession.h" 18 #include "llvm/DebugInfo/PDB/DIA/DIASession.h"
19 #endif 19 #endif
20 20
21 using namespace llvm; 21 using namespace llvm;
22 22
23 std::unique_ptr<IPDBSession> llvm::createPDBReader(PDB_ReaderType Type, 23 PDB_ErrorCode llvm::loadDataForPDB(PDB_ReaderType Type, StringRef Path,
24 StringRef Path) { 24 std::unique_ptr<IPDBSession> &Session) {
25 // Create the correct concrete instance type based on the value of Type. 25 // Create the correct concrete instance type based on the value of Type.
26 #if HAVE_DIA_SDK 26 #if HAVE_DIA_SDK
27 return std::unique_ptr<DIASession>(DIASession::createFromPdb(Path)); 27 return DIASession::createFromPdb(Path, Session);
28 #endif 28 #endif
29 return nullptr; 29 return PDB_ErrorCode::NoPdbImpl;
30 } 30 }
31
32 PDB_ErrorCode llvm::loadDataForEXE(PDB_ReaderType Type, StringRef Path,
33 std::unique_ptr<IPDBSession> &Session) {
34 // Create the correct concrete instance type based on the value of Type.
35 #if HAVE_DIA_SDK
36 return DIASession::createFromExe(Path, Session);
37 #endif
38 return PDB_ErrorCode::NoPdbImpl;
39 }