Skip to content

Commit 33a954c

Browse files
krystian-andrzejewskiigcbot
authored andcommitted
Remove redundant guard for a pattern of global imm offsets
This simplifies the control flow for a pattern of global imm offsets.
1 parent 349f3e9 commit 33a954c

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

IGC/Compiler/CISACodeGen/PatternMatchPass.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2418,9 +2418,6 @@ bool CodeGenPatternMatch::MatchImmOffsetLSC(llvm::Instruction &I) {
24182418

24192419
llvm::Value *varOffset = isConstant0 ? addSubInst->getOperand(1) : addSubInst->getOperand(0);
24202420

2421-
if (!isA64AddressingModel && m_ctx->type != ShaderType::OPENCL_SHADER && IGC_GET_FLAG_VALUE(LscImmOffsMatch) < 2)
2422-
return false;
2423-
24242421
// HW does an early bounds check on varOffset for A32 messages. Thus, if varOffset
24252422
// is negative, then the bounds check fails early even though the immediate offset
24262423
// would bring the final calculation to a positive number.

IGC/Compiler/tests/EmitVISAPass/fold-immediates.ll

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@
55
; SPDX-License-Identifier: MIT
66
;
77
;============================ end_copyright_notice =============================
8-
9-
; REQUIRES: temporarily-disabled, regkeys
8+
; REQUIRES: regkeys
109
;
1110
; RUN: igc_opt -platformbmg -igc-emit-visa %s -dx12 -inputcs -regkey DumpVISAASMToConsole | FileCheck %s
1211
; ------------------------------------------------

0 commit comments

Comments
 (0)