MCPcopy Create free account
hub / github.com/apache/impala / CloneFunction

Method CloneFunction

be/src/codegen/llvm-codegen.cc:1111–1121  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1109}
1110
1111llvm::Function* LlvmCodeGen::CloneFunction(llvm::Function* fn) {
1112 DCHECK(!is_compiled_);
1113 llvm::ValueToValueMapTy dummy_vmap;
1114 // Verifies that 'fn' has been materialized already. Callers are expected to use
1115 // GetFunction() to obtain the Function object.
1116 DCHECK(!fn->isMaterializable());
1117 // CloneFunction() automatically gives the new function a unique name
1118 llvm::Function* fn_clone = llvm::CloneFunction(fn, dummy_vmap);
1119 fn_clone->copyAttributesFrom(fn);
1120 return fn_clone;
1121}
1122
1123llvm::Function* LlvmCodeGen::FinalizeFunction(llvm::Function* function) {
1124 SetCPUAttrs(function);

Callers 5

CodegenInsertBatchMethod · 0.80
GetLenOptimizedHashFnFunction · 0.80
TEST_FFunction · 0.80

Calls

no outgoing calls

Tested by 1

TEST_FFunction · 0.64