Skip to content
Snippets Groups Projects
Commit 873f25a5 authored by Adel Ejjeh's avatar Adel Ejjeh
Browse files

Update DFG2LLVM_NVPTX.cpp to fix callinst of a function within the kernel.

parent 7c7949d8
No related branches found
No related tags found
No related merge requests found
......@@ -1465,6 +1465,10 @@ void CGT_NVPTX::codeGen(DFLeafNode* N) {
Function* newCalleeF = CloneFunction(calleeF, VMap);
newCalleeF->removeFromParent(); //TODO: MARIA check
KernelM->getFunctionList().push_back(newCalleeF);
CallInst *CInew = CallInst::Create(newCalleeF, CI->getArgOperand(0), CI->getName(), CI);
CI->replaceAllUsesWith(CInew);
CItoRemove.push_back(CI);
}
//TODO: how to handle address space qualifiers in load/store
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment