Skip to content

Commit 8525567

Browse files
weiyu-chenigcbot
authored andcommitted
[Autobackout][FuncReg]Revert of change: 797fc52
Enable accumulator usage for sel instruction.
1 parent f5607a5 commit 8525567

File tree

2 files changed

+8
-16
lines changed

2 files changed

+8
-16
lines changed

visa/AccSubstitution.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,7 @@ bool AccSubPass::isAccCandidate(G4_INST* inst, int& lastUse, bool& mustBeAcc0, i
441441
return false;
442442
}
443443

444-
if (inst->hasCondModWithFlag())
444+
if (inst->getCondMod())
445445
{
446446
// since our du-chain is on inst instead of operand, the presence of conditional modifier complicates the checks later.
447447
// This is somewhat conservative but shouldn't matter too much as inst with both dst and conditional modifiers are rare.

visa/Gen4_IR.hpp

Lines changed: 7 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -918,16 +918,13 @@ typedef struct _SWSBInfo
918918
// add (8|M8) ...
919919
// will have 0xFF00, which lane 8-15
920920
uint32_t getExecLaneMask() const;
921-
G4_ExecSize getExecSize() const { return execSize; }
922-
923-
const G4_CondMod* getCondMod() const { return mod; }
924-
G4_CondMod* getCondMod() { return mod; }
925-
const G4_VarBase* getCondModBase() const;
926-
G4_VarBase* getCondModBase() {
927-
return const_cast<G4_VarBase*>(((const G4_INST*)this)->getCondModBase());
928-
}
929-
bool hasCondModWithFlag() const;
930-
921+
G4_ExecSize getExecSize() const {return execSize;}
922+
const G4_CondMod* getCondMod() const {return mod;}
923+
G4_CondMod* getCondMod() {return mod;}
924+
const G4_VarBase* getCondModBase() const;
925+
G4_VarBase* getCondModBase() {
926+
return const_cast<G4_VarBase*>(((const G4_INST*)this)->getCondModBase());
927+
}
931928
void setCondMod(G4_CondMod* m);
932929

933930
bool isDead() const {return dead;}
@@ -4221,11 +4218,6 @@ inline G4_Declare *G4_Operand::getBaseRegVarRootDeclare() const
42214218
return getBase()->asRegVar()->getDeclare()->getRootDeclare();
42224219
}
42234220

4224-
inline bool G4_INST::hasCondModWithFlag() const
4225-
{
4226-
return mod && mod->getBase();
4227-
}
4228-
42294221
} // namespace vISA
42304222

42314223
#endif

0 commit comments

Comments
 (0)