#include "llvm/Instruction.h"
#include "llvm/Target/TargetData.h"
#include "llvm/DerivedTypes.h"
-#include "llvm/ConstantVals.h"
+#include "llvm/Constants.h"
#include <map>
#include <set>
static inline int getConstantValue(const ConstantInt *CPI) {
if (const ConstantSInt *CSI = dyn_cast<ConstantSInt>(CPI))
- return CSI->getValue();
- return cast<ConstantUInt>(CPI)->getValue();
+ return (int)CSI->getValue();
+ return (int)cast<ConstantUInt>(CPI)->getValue();
}