//
//===------------------------------------------------------------------------------------------===//
-#define DEBUG_TYPE "double barriers"
-
#include "ARM.h"
-#include "ARMMachineFunctionInfo.h"
#include "ARMInstrInfo.h"
+#include "ARMMachineFunctionInfo.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/CodeGen/MachineFunctionPass.h"
using namespace llvm;
+#define DEBUG_TYPE "double barriers"
+
STATISTIC(NumDMBsRemoved, "Number of DMBs removed");
namespace {
static char ID;
ARMOptimizeBarriersPass() : MachineFunctionPass(ID) {}
- virtual bool runOnMachineFunction(MachineFunction &Fn);
+ bool runOnMachineFunction(MachineFunction &Fn) override;
- virtual const char *getPassName() const {
+ const char *getPassName() const override {
return "optimise barriers pass";
}
-
-private:
};
char ARMOptimizeBarriersPass::ID = 0;
-}
+} // namespace
// Returns whether the instruction can safely move past a DMB instruction
// The current implementation allows this iif MI does not have any possible