mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-03 08:51:43 +00:00
Add generic binary op and cast builder functions.
llvm-svn: 97370
This commit is contained in:
parent
6faa3e69cf
commit
b405437c48
@ -827,6 +827,9 @@ LLVMValueRef LLVMBuildOr(LLVMBuilderRef, LLVMValueRef LHS, LLVMValueRef RHS,
|
||||
const char *Name);
|
||||
LLVMValueRef LLVMBuildXor(LLVMBuilderRef, LLVMValueRef LHS, LLVMValueRef RHS,
|
||||
const char *Name);
|
||||
LLVMValueRef LLVMBuildBinOp(LLVMBuilderRef B, LLVMOpcode Op,
|
||||
LLVMValueRef LHS, LLVMValueRef RHS,
|
||||
const char *Name);
|
||||
LLVMValueRef LLVMBuildNeg(LLVMBuilderRef, LLVMValueRef V, const char *Name);
|
||||
LLVMValueRef LLVMBuildFNeg(LLVMBuilderRef, LLVMValueRef V, const char *Name);
|
||||
LLVMValueRef LLVMBuildNot(LLVMBuilderRef, LLVMValueRef V, const char *Name);
|
||||
@ -886,6 +889,8 @@ LLVMValueRef LLVMBuildSExtOrBitCast(LLVMBuilderRef, LLVMValueRef Val,
|
||||
LLVMTypeRef DestTy, const char *Name);
|
||||
LLVMValueRef LLVMBuildTruncOrBitCast(LLVMBuilderRef, LLVMValueRef Val,
|
||||
LLVMTypeRef DestTy, const char *Name);
|
||||
LLVMValueRef LLVMBuildCast(LLVMBuilderRef B, LLVMOpcode Op, LLVMValueRef Val,
|
||||
LLVMTypeRef DestTy, const char *Name);
|
||||
LLVMValueRef LLVMBuildPointerCast(LLVMBuilderRef, LLVMValueRef Val,
|
||||
LLVMTypeRef DestTy, const char *Name);
|
||||
LLVMValueRef LLVMBuildIntCast(LLVMBuilderRef, LLVMValueRef Val, /*Signed cast!*/
|
||||
|
@ -1716,6 +1716,13 @@ LLVMValueRef LLVMBuildXor(LLVMBuilderRef B, LLVMValueRef LHS, LLVMValueRef RHS,
|
||||
return wrap(unwrap(B)->CreateXor(unwrap(LHS), unwrap(RHS), Name));
|
||||
}
|
||||
|
||||
LLVMValueRef LLVMBuildBinOp(LLVMBuilderRef B, LLVMOpcode Op,
|
||||
LLVMValueRef LHS, LLVMValueRef RHS,
|
||||
const char *Name) {
|
||||
return wrap(unwrap(B)->CreateBinOp(Instruction::BinaryOps(Op), unwrap(LHS),
|
||||
unwrap(RHS), Name));
|
||||
}
|
||||
|
||||
LLVMValueRef LLVMBuildNeg(LLVMBuilderRef B, LLVMValueRef V, const char *Name) {
|
||||
return wrap(unwrap(B)->CreateNeg(unwrap(V), Name));
|
||||
}
|
||||
@ -1887,6 +1894,12 @@ LLVMValueRef LLVMBuildTruncOrBitCast(LLVMBuilderRef B, LLVMValueRef Val,
|
||||
Name));
|
||||
}
|
||||
|
||||
LLVMValueRef LLVMBuildCast(LLVMBuilderRef B, LLVMOpcode Op, LLVMValueRef Val,
|
||||
LLVMTypeRef DestTy, const char *Name) {
|
||||
return wrap(unwrap(B)->CreateCast(Instruction::CastOps(Op), unwrap(Val),
|
||||
unwrap(DestTy), Name));
|
||||
}
|
||||
|
||||
LLVMValueRef LLVMBuildPointerCast(LLVMBuilderRef B, LLVMValueRef Val,
|
||||
LLVMTypeRef DestTy, const char *Name) {
|
||||
return wrap(unwrap(B)->CreatePointerCast(unwrap(Val), unwrap(DestTy), Name));
|
||||
|
Loading…
Reference in New Issue
Block a user