mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-24 23:28:41 +00:00
Allow creation of GEP constantexprs with a vector of value* operands as
well as a vector of constant*'s. It turns out that this is more efficient and all of the clients want to do that, so we should cater to them. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16923 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -533,7 +533,7 @@ protected:
|
||||
static Constant *getSelectTy(const Type *Ty,
|
||||
Constant *C1, Constant *C2, Constant *C3);
|
||||
static Constant *getGetElementPtrTy(const Type *Ty, Constant *C,
|
||||
const std::vector<Constant*> &IdxList);
|
||||
const std::vector<Value*> &IdxList);
|
||||
|
||||
public:
|
||||
// Static methods to construct a ConstantExpr of different kinds. Note that
|
||||
@@ -584,10 +584,13 @@ public:
|
||||
static Constant *getUShr(Constant *C1, Constant *C2); // unsigned shr
|
||||
static Constant *getSShr(Constant *C1, Constant *C2); // signed shr
|
||||
|
||||
/// Getelementptr form...
|
||||
/// Getelementptr form. std::vector<Value*> is only accepted for convenience:
|
||||
/// all elements must be Constant's.
|
||||
///
|
||||
static Constant *getGetElementPtr(Constant *C,
|
||||
const std::vector<Constant*> &IdxList);
|
||||
static Constant *getGetElementPtr(Constant *C,
|
||||
const std::vector<Value*> &IdxList);
|
||||
|
||||
/// isNullValue - Return true if this is the value that would be returned by
|
||||
/// getNullValue.
|
||||
|
Reference in New Issue
Block a user