search for: lfunc2

Displaying 1 result from an estimated 1 matches for "lfunc2".

Did you mean: func2
2019 May 17
3
Copy Function from one LLVM IR file to another
...F2; *5.* Assign them values so that F1 points to the first function and F2 to the second function: for(Module::iterator func = Mod_ptr->begin(), Lfunc = Mod_ptr->end(); func!=Lfunc; ++func) { F1 = func; } for(Module::iterator func2 = Mod_ptr2->begin(), Lfunc2 = Mod_ptr2->end(); func2!=Lfunc2; ++func2) { if(func2->getName() == F.getName()) //F.getName() gives the same name as the function that was extracted { F2 = func2; } } *6.* Replacing each instruction of F2 with instruction from F1 usi...