| 160 | } |
| 161 | |
| 162 | std::string DumpModuleIR(const llvm::Module& module) { |
| 163 | std::string ir; |
| 164 | llvm::raw_string_ostream stream(ir); |
| 165 | module.print(stream, nullptr); |
| 166 | return ir; |
| 167 | } |
| 168 | |
| 169 | void AddAbsoluteSymbol(llvm::orc::LLJIT& lljit, const std::string& name, |
| 170 | void* function_ptr) { |