#include "llvm/Transforms/Utils/Local.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/Support/CommandLine.h"
-#include "llvm/Support/Compiler.h"
#include "llvm/Target/TargetLowering.h"
#include <csetjmp>
#include <set>
// This is a cluster of orthogonal Transforms
AU.addPreservedID(PromoteMemoryToRegisterID);
AU.addPreservedID(LowerSwitchID);
- AU.addPreservedID(LowerAllocationsID);
}
private:
// Insert a return instruction. This really should be a "barrier", as it
// is unreachable.
ReturnInst::Create(F.getContext(),
- F.getReturnType() == Type::getVoidTy(F.getContext()) ?
+ F.getReturnType()->isVoidTy() ?
0 : Constant::getNullValue(F.getReturnType()), UI);
// Remove the unwind instruction now.