nv50/ir: resolve -Woverloaded-virtual=1 warnings

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23656>
This commit is contained in:
Karol Herbst
2023-06-15 17:33:24 +02:00
committed by Marge Bot
parent 6c73c6cec6
commit c9a00d6676
3 changed files with 14 additions and 12 deletions

View File

@@ -1399,15 +1399,15 @@ public:
bool run(Function *, bool ordered = false, bool skipPhi = false);
private:
bool doRun(Program *, bool ordered, bool skipPhi);
bool doRun(Function *, bool ordered, bool skipPhi);
protected:
// return false to continue with next entity on next higher level
virtual bool visit(Function *) { return true; }
virtual bool visit(BasicBlock *) { return true; }
virtual bool visit(Instruction *) { return false; }
bool doRun(Program *, bool ordered, bool skipPhi);
bool doRun(Function *, bool ordered, bool skipPhi);
protected:
bool err;
Function *func;
Program *prog;

View File

@@ -6,7 +6,8 @@ class GM107LoweringPass : public NVC0LoweringPass
{
public:
GM107LoweringPass(Program *p) : NVC0LoweringPass(p) {}
private:
protected:
using NVC0LoweringPass::visit;
bool visit(Instruction *) override;
bool handleManualTXD(TexInstruction *) override;
@@ -18,10 +19,10 @@ private:
class GM107LegalizeSSA : public NVC0LegalizeSSA
{
private:
protected:
using NVC0LegalizeSSA::visit;
bool visit(Instruction *) override;
protected:
void handlePFETCH(Instruction *);
void handleLOAD(Instruction *);
void handleQUADON(Instruction *);

View File

@@ -56,7 +56,8 @@ namespace nv50_ir {
class NVC0LegalizeSSA : public Pass
{
private:
protected:
using Pass::visit;
bool visit(BasicBlock *) override;
bool visit(Function *) override;
@@ -69,7 +70,6 @@ private:
void handleShift(Instruction *);
void handleBREV(Instruction *);
protected:
void handleFTZ(Instruction *);
BuildUtil bld;
@@ -80,10 +80,12 @@ class NVC0LegalizePostRA : public Pass
public:
NVC0LegalizePostRA(const Program *);
private:
protected:
using Pass::visit;
bool visit(Function *) override;
bool visit(BasicBlock *) override;
private:
void replaceCvt(Instruction *);
void replaceZero(Instruction *);
bool tryReplaceContWithBra(BasicBlock *);
@@ -156,11 +158,10 @@ protected:
Value *loadMsAdjInfo32(TexInstruction::Target targ, uint32_t index, int slot, Value *ind, bool bindless);
bool visit(Instruction *) override;
private:
bool visit(Function *) override;
bool visit(BasicBlock *) override;
private:
void readTessCoord(LValue *dst, int c);
Value *loadResInfo32(Value *ptr, uint32_t off, uint16_t base);