MCPcopy Create free account
hub / github.com/avast/retdec / dumpModuleToFile

Function dumpModuleToFile

src/bin2llvmir/utils/debug.cpp:55–69  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

53//
54
55void dumpModuleToFile(
56 const llvm::Module* m,
57 fs::path dirName,
58 const std::string& fileName)
59{
60 static unsigned cntr = 0;
61 std::string n = fileName.empty()
62 ? "dump_" + std::to_string(cntr++) + ".ll"
63 : fileName;
64
65 dirName.append(n);
66
67 std::ofstream myfile(dirName.string());
68 myfile << llvmObjToString(m) << std::endl;
69}
70
71//
72//==============================================================================

Callers 3

runOnModuleMethod · 0.85
runMethod · 0.85
splitFunctionOnMethod · 0.85

Calls 2

llvmObjToStringFunction · 0.70
emptyMethod · 0.45

Tested by

no test coverage detected