Skip to content

Commit 0d80e92

Browse files
kychendevigcbot
authored andcommitted
Update ARF restriction for ternary instruction source operand.
Revised the verifier restriction to allow state register as src0 in ternary instruction.
1 parent 72595b3 commit 0d80e92

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

visa/G4_Verifier.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*========================== begin_copyright_notice ============================
22
3-
Copyright (C) 2017-2021 Intel Corporation
3+
Copyright (C) 2017-2024 Intel Corporation
44
55
SPDX-License-Identifier: MIT
66
@@ -470,7 +470,8 @@ void G4Verifier::verifyOpnd(G4_Operand *opnd, G4_INST *inst) {
470470
} else {
471471
// Only valid ARF type are NULL and Accumulator for ternary instructions
472472
if (inst->getNumSrc() == 3) {
473-
if (opnd->isAreg() && !opnd->isNullReg() && !opnd->isAccReg())
473+
if (opnd->isAreg() && !opnd->isNullReg() && !opnd->isAccReg() &&
474+
!(opnd == inst->getSrc(0) && opnd->isSrReg()))
474475
vISA_ASSERT(false, "Not allowed ARF in ternary instruction");
475476
}
476477

0 commit comments

Comments
 (0)