search for: to_be_print

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

2013 Dec 20
0
[LLVMdev] A problem about convert a string to a *i8 pointer
...instruction executed. While passing the opcode to the printf fucntion ,I used such way to convert the string to i8* (the same as http://lists.cs.uiuc.edu/pipermail/llvmdev/2012-September/053206.html does): StringRef s = ins_temp->getOpcodeName(); //ins_temp is an Instruction* type Constant *to_be_print = ConstantDataArray::getString(ctx, s); GlobalVariable *g_print = new GlobalVariable(M, to_be_print->getType(), true, GlobalValue::InternalLinkage, to_be_print, "print_str"); Constant *zero = Constant::getNullValue(llvm::IntegerType::getInt32Ty(ctx)); // what's the function of the...