diff options
-rw-r--r-- | include/llvm/Argument.h | 2 | ||||
-rw-r--r-- | include/llvm/BasicBlock.h | 2 | ||||
-rw-r--r-- | include/llvm/Constant.h | 4 | ||||
-rw-r--r-- | include/llvm/Constants.h | 18 | ||||
-rw-r--r-- | include/llvm/Function.h | 2 | ||||
-rw-r--r-- | include/llvm/GlobalValue.h | 4 | ||||
-rw-r--r-- | include/llvm/GlobalVariable.h | 2 | ||||
-rw-r--r-- | include/llvm/InlineAsm.h | 2 | ||||
-rw-r--r-- | include/llvm/Instruction.h | 4 | ||||
-rw-r--r-- | include/llvm/Support/PatternMatch.h | 6 | ||||
-rw-r--r-- | include/llvm/Value.h | 20 |
11 files changed, 33 insertions, 33 deletions
diff --git a/include/llvm/Argument.h b/include/llvm/Argument.h index 8776a48..ea735b5 100644 --- a/include/llvm/Argument.h +++ b/include/llvm/Argument.h @@ -64,7 +64,7 @@ public: /// static inline bool classof(const Argument *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() == ArgumentVal; + return V->getValueID() == ArgumentVal; } }; diff --git a/include/llvm/BasicBlock.h b/include/llvm/BasicBlock.h index e15a894..d8cb538 100644 --- a/include/llvm/BasicBlock.h +++ b/include/llvm/BasicBlock.h @@ -158,7 +158,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const BasicBlock *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() == Value::BasicBlockVal; + return V->getValueID() == Value::BasicBlockVal; } /// dropAllReferences() - This function causes all the subinstructions to "let diff --git a/include/llvm/Constant.h b/include/llvm/Constant.h index 4b3547e..bfe65a6 100644 --- a/include/llvm/Constant.h +++ b/include/llvm/Constant.h @@ -88,8 +88,8 @@ public: static inline bool classof(const Constant *) { return true; } static inline bool classof(const GlobalValue *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() >= ConstantFirstVal && - V->getValueType() <= ConstantLastVal; + return V->getValueID() >= ConstantFirstVal && + V->getValueID() <= ConstantLastVal; } /// replaceUsesOfWithOnConstant - This method is a special form of diff --git a/include/llvm/Constants.h b/include/llvm/Constants.h index 0659f3b..2bec1d4 100644 --- a/include/llvm/Constants.h +++ b/include/llvm/Constants.h @@ -201,7 +201,7 @@ public: /// @brief Methods to support type inquiry through isa, cast, and dyn_cast. static inline bool classof(const ConstantInt *) { return true; } static bool classof(const Value *V) { - return V->getValueType() == ConstantIntVal; + return V->getValueID() == ConstantIntVal; } static void ResetTrueFalse() { TheTrueVal = TheFalseVal = 0; } private: @@ -239,7 +239,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const ConstantFP *) { return true; } static bool classof(const Value *V) { - return V->getValueType() == ConstantFPVal; + return V->getValueID() == ConstantFPVal; } }; @@ -267,7 +267,7 @@ public: /// static bool classof(const ConstantAggregateZero *) { return true; } static bool classof(const Value *V) { - return V->getValueType() == ConstantAggregateZeroVal; + return V->getValueID() == ConstantAggregateZeroVal; } }; @@ -331,7 +331,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const ConstantArray *) { return true; } static bool classof(const Value *V) { - return V->getValueType() == ConstantArrayVal; + return V->getValueID() == ConstantArrayVal; } }; @@ -376,7 +376,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const ConstantStruct *) { return true; } static bool classof(const Value *V) { - return V->getValueType() == ConstantStructVal; + return V->getValueID() == ConstantStructVal; } }; @@ -428,7 +428,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const ConstantVector *) { return true; } static bool classof(const Value *V) { - return V->getValueType() == ConstantVectorVal; + return V->getValueID() == ConstantVectorVal; } }; @@ -464,7 +464,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const ConstantPointerNull *) { return true; } static bool classof(const Value *V) { - return V->getValueType() == ConstantPointerNullVal; + return V->getValueID() == ConstantPointerNullVal; } }; @@ -673,7 +673,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const ConstantExpr *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() == ConstantExprVal; + return V->getValueID() == ConstantExprVal; } }; @@ -704,7 +704,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const UndefValue *) { return true; } static bool classof(const Value *V) { - return V->getValueType() == UndefValueVal; + return V->getValueID() == UndefValueVal; } }; diff --git a/include/llvm/Function.h b/include/llvm/Function.h index 101de8a..751d1a3 100644 --- a/include/llvm/Function.h +++ b/include/llvm/Function.h @@ -220,7 +220,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const Function *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() == Value::FunctionVal; + return V->getValueID() == Value::FunctionVal; } /// dropAllReferences() - This method causes all the subinstructions to "let diff --git a/include/llvm/GlobalValue.h b/include/llvm/GlobalValue.h index 576fbe6..72a45f4 100644 --- a/include/llvm/GlobalValue.h +++ b/include/llvm/GlobalValue.h @@ -133,8 +133,8 @@ public: // Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const GlobalValue *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() == Value::FunctionVal || - V->getValueType() == Value::GlobalVariableVal; + return V->getValueID() == Value::FunctionVal || + V->getValueID() == Value::GlobalVariableVal; } }; diff --git a/include/llvm/GlobalVariable.h b/include/llvm/GlobalVariable.h index 6575dde..ba869b8 100644 --- a/include/llvm/GlobalVariable.h +++ b/include/llvm/GlobalVariable.h @@ -132,7 +132,7 @@ public: // Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const GlobalVariable *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() == Value::GlobalVariableVal; + return V->getValueID() == Value::GlobalVariableVal; } }; diff --git a/include/llvm/InlineAsm.h b/include/llvm/InlineAsm.h index 98f254f..1ba791c 100644 --- a/include/llvm/InlineAsm.h +++ b/include/llvm/InlineAsm.h @@ -124,7 +124,7 @@ public: // Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const InlineAsm *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() == Value::InlineAsmVal; + return V->getValueID() == Value::InlineAsmVal; } }; diff --git a/include/llvm/Instruction.h b/include/llvm/Instruction.h index bda59e9..ed0357f 100644 --- a/include/llvm/Instruction.h +++ b/include/llvm/Instruction.h @@ -110,7 +110,7 @@ public: /// Subclass classification... getOpcode() returns a member of /// one of the enums that is coming soon (down below)... /// - unsigned getOpcode() const { return getValueType() - InstructionVal; } + unsigned getOpcode() const { return getValueID() - InstructionVal; } const char *getOpcodeName() const { return getOpcodeName(getOpcode()); } @@ -193,7 +193,7 @@ public: /// Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const Instruction *) { return true; } static inline bool classof(const Value *V) { - return V->getValueType() >= Value::InstructionVal; + return V->getValueID() >= Value::InstructionVal; } //---------------------------------------------------------------------- diff --git a/include/llvm/Support/PatternMatch.h b/include/llvm/Support/PatternMatch.h index ab9e45f..d8099a9 100644 --- a/include/llvm/Support/PatternMatch.h +++ b/include/llvm/Support/PatternMatch.h @@ -81,7 +81,7 @@ struct BinaryOp_match { template<typename OpTy> bool match(OpTy *V) { - if (V->getValueType() == Value::InstructionVal + Opcode) { + if (V->getValueID() == Value::InstructionVal + Opcode) { ConcreteTy *I = cast<ConcreteTy>(V); return I->getOpcode() == Opcode && L.match(I->getOperand(0)) && R.match(I->getOperand(1)); @@ -195,8 +195,8 @@ struct Shr_match { template<typename OpTy> bool match(OpTy *V) { - if (V->getValueType() == Value::InstructionVal + Instruction::LShr || - V->getValueType() == Value::InstructionVal + Instruction::AShr) { + if (V->getValueID() == Value::InstructionVal + Instruction::LShr || + V->getValueID() == Value::InstructionVal + Instruction::AShr) { ConcreteTy *I = cast<ConcreteTy>(V); return (I->getOpcode() == Instruction::AShr || I->getOpcode() == Instruction::LShr) && diff --git a/include/llvm/Value.h b/include/llvm/Value.h index 3be3c5e..fc65e74 100644 --- a/include/llvm/Value.h +++ b/include/llvm/Value.h @@ -178,7 +178,7 @@ public: ConstantLastVal = ConstantPointerNullVal }; - /// getValueType - Return an ID for the concrete type of this object. This is + /// getValueID - Return an ID for the concrete type of this object. This is /// used to implement the classof checks. This should not be used for any /// other purpose, as the values may change as LLVM evolves. Also, note that /// for instructions, the Instruction's opcode is added to InstructionVal. So @@ -187,7 +187,7 @@ public: /// # there are more possible values for the value type than in ValueTy enum. /// # the InstructionVal enumerator must be the highest valued enumerator in /// the ValueTy enum. - unsigned getValueType() const { + unsigned getValueID() const { return SubclassID; } @@ -227,26 +227,26 @@ void Use::set(Value *V) { // the subtype header files to test to see if the value is a subclass... // template <> inline bool isa_impl<Constant, Value>(const Value &Val) { - return Val.getValueType() >= Value::ConstantFirstVal && - Val.getValueType() <= Value::ConstantLastVal; + return Val.getValueID() >= Value::ConstantFirstVal && + Val.getValueID() <= Value::ConstantLastVal; } template <> inline bool isa_impl<Argument, Value>(const Value &Val) { - return Val.getValueType() == Value::ArgumentVal; + return Val.getValueID() == Value::ArgumentVal; } template <> inline bool isa_impl<InlineAsm, Value>(const Value &Val) { - return Val.getValueType() == Value::InlineAsmVal; + return Val.getValueID() == Value::InlineAsmVal; } template <> inline bool isa_impl<Instruction, Value>(const Value &Val) { - return Val.getValueType() >= Value::InstructionVal; + return Val.getValueID() >= Value::InstructionVal; } template <> inline bool isa_impl<BasicBlock, Value>(const Value &Val) { - return Val.getValueType() == Value::BasicBlockVal; + return Val.getValueID() == Value::BasicBlockVal; } template <> inline bool isa_impl<Function, Value>(const Value &Val) { - return Val.getValueType() == Value::FunctionVal; + return Val.getValueID() == Value::FunctionVal; } template <> inline bool isa_impl<GlobalVariable, Value>(const Value &Val) { - return Val.getValueType() == Value::GlobalVariableVal; + return Val.getValueID() == Value::GlobalVariableVal; } template <> inline bool isa_impl<GlobalValue, Value>(const Value &Val) { return isa<GlobalVariable>(Val) || isa<Function>(Val); |