Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion llvm/include/llvm/Analysis/AliasAnalysis.h
Original file line number Diff line number Diff line change
Expand Up @@ -861,7 +861,7 @@ class AAResultBase {

// Provide all the copy and move constructors so that derived types aren't
// constrained.
AAResultBase(const AAResultBase &Arg) {}
AAResultBase(const AAResultBase &Arg) = default;
AAResultBase(AAResultBase &&Arg) {}

public:
Expand Down
2 changes: 1 addition & 1 deletion llvm/include/llvm/Analysis/ConstraintSystem.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ class ConstraintSystem {
SmallVector<std::string> getVarNamesList() const;

public:
ConstraintSystem() {}
ConstraintSystem() = default;
ConstraintSystem(ArrayRef<Value *> FunctionArgs) {
NumVariables += FunctionArgs.size();
for (auto *Arg : FunctionArgs) {
Expand Down
4 changes: 2 additions & 2 deletions llvm/include/llvm/Analysis/DOTGraphTraitsPass.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ struct DOTGraphTraitsViewer
/// virtual destructor needed. Making this dtor protected stops accidental
/// invocation when the derived class destructor should have been called.
/// Those derived classes sould be marked final to avoid the warning.
~DOTGraphTraitsViewer() {}
~DOTGraphTraitsViewer() = default;

private:
StringRef Name;
Expand Down Expand Up @@ -161,7 +161,7 @@ struct DOTGraphTraitsPrinter
/// virtual destructor needed. Making this dtor protected stops accidental
/// invocation when the derived class destructor should have been called.
/// Those derived classes sould be marked final to avoid the warning.
~DOTGraphTraitsPrinter() {}
~DOTGraphTraitsPrinter() = default;

private:
StringRef Name;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class BasicBlockSectionsProfileReader {
BasicBlockSectionsProfileReader(const MemoryBuffer *Buf)
: MBuf(Buf), LineIt(*Buf, /*SkipBlanks=*/true, /*CommentMarker=*/'#'){};

BasicBlockSectionsProfileReader(){};
BasicBlockSectionsProfileReader() = default;

// Returns true if basic block sections profile exist for function \p
// FuncName.
Expand Down
2 changes: 1 addition & 1 deletion llvm/include/llvm/CodeGen/MachineScheduler.h
Original file line number Diff line number Diff line change
Expand Up @@ -829,7 +829,7 @@ class ResourceSegments {

public:
// constructor for empty set
explicit ResourceSegments(){};
explicit ResourceSegments() = default;
bool empty() const { return _Intervals.empty(); }
explicit ResourceSegments(const std::list<IntervalTy> &Intervals)
: _Intervals(Intervals) {
Expand Down
2 changes: 1 addition & 1 deletion llvm/include/llvm/CodeGen/WindowScheduler.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ class WindowScheduler {

public:
WindowScheduler(MachineSchedContext *C, MachineLoop &ML);
virtual ~WindowScheduler() {}
virtual ~WindowScheduler() = default;

bool run();

Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Analysis/AliasAnalysis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ AAResults::AAResults(const TargetLibraryInfo &TLI) : TLI(TLI) {}
AAResults::AAResults(AAResults &&Arg)
: TLI(Arg.TLI), AAs(std::move(Arg.AAs)), AADeps(std::move(Arg.AADeps)) {}

AAResults::~AAResults() {}
AAResults::~AAResults() = default;

bool AAResults::invalidate(Function &F, const PreservedAnalyses &PA,
FunctionAnalysisManager::Invalidator &Inv) {
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/CodeGen/CodeGenPrepare.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ class CodeGenPrepare {
std::unique_ptr<DominatorTree> DT;

public:
CodeGenPrepare(){};
CodeGenPrepare() = default;
CodeGenPrepare(const TargetMachine *TM) : TM(TM){};
/// If encounter huge function, we need to limit the build time.
bool IsHugeFunc = false;
Expand Down
4 changes: 2 additions & 2 deletions llvm/lib/CodeGen/MachineScheduler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ class MachineSchedulerImpl : public MachineSchedulerBase {
LiveIntervals &LIS;
};

MachineSchedulerImpl() {}
MachineSchedulerImpl() = default;
// Migration only
void setLegacyPass(MachineFunctionPass *P) { this->P = P; }
void setMFAM(MachineFunctionAnalysisManager *MFAM) { this->MFAM = MFAM; }
Expand All @@ -358,7 +358,7 @@ class PostMachineSchedulerImpl : public MachineSchedulerBase {
MachineLoopInfo &MLI;
AAResults &AA;
};
PostMachineSchedulerImpl() {}
PostMachineSchedulerImpl() = default;
// Migration only
void setLegacyPass(MachineFunctionPass *P) { this->P = P; }
void setMFAM(MachineFunctionAnalysisManager *MFAM) { this->MFAM = MFAM; }
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/CodeGen/RegAllocFast.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ class RegAllocFastImpl {
bool Error = false; ///< Could not allocate.

explicit LiveReg(Register VirtReg) : VirtReg(VirtReg) {}
explicit LiveReg() {}
explicit LiveReg() = default;

unsigned getSparseSetIndex() const { return VirtReg.virtRegIndex(); }
};
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/CodeGen/RegisterCoalescer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,7 @@ class RegisterCoalescer : private LiveRangeEdit::Delegate {

public:
// For legacy pass only.
RegisterCoalescer() {}
RegisterCoalescer() = default;
RegisterCoalescer &operator=(RegisterCoalescer &&Other) = default;

RegisterCoalescer(LiveIntervals *LIS, SlotIndexes *SI,
Expand Down
2 changes: 1 addition & 1 deletion llvm/unittests/CodeGen/AsmPrinterDwarfTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ class AsmPrinterHandlerTest : public AsmPrinterFixtureBase {

public:
TestHandler(AsmPrinterHandlerTest &Test) : Test(Test) {}
~TestHandler() override {}
~TestHandler() override = default;
void setSymbolSize(const MCSymbol *Sym, uint64_t Size) override {}
void beginModule(Module *M) override { Test.BeginCount++; }
void endModule() override { Test.EndCount++; }
Expand Down
4 changes: 2 additions & 2 deletions llvm/unittests/CodeGen/MFCommon.inc
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public:
: TargetSubtargetInfo(Triple(""), "", "", "", {}, {}, {}, nullptr,
nullptr, nullptr, nullptr, nullptr, nullptr),
FL(), TL(TM) {}
~BogusSubtarget() override {}
~BogusSubtarget() override = default;

const TargetFrameLowering *getFrameLowering() const override { return &FL; }

Expand Down Expand Up @@ -117,7 +117,7 @@ public:
Reloc::Static, CodeModel::Small, CodeGenOptLevel::Default),
ST(*this) {}

~BogusTargetMachine() override {}
~BogusTargetMachine() override = default;

const TargetSubtargetInfo *getSubtargetImpl(const Function &) const override {
return &ST;
Expand Down