Skip to content

Commit b3558fc

Browse files
DianaChensys_zuul
authored andcommitted
IGA: fix a bug in swsb setter to remove the assert for checking DepSet companion
Change-Id: I907290b64f06aa9cbe7e876f2c1f5d62ddfe20e3
1 parent e5a121b commit b3558fc

File tree

5 files changed

+21
-14
lines changed

5 files changed

+21
-14
lines changed

visa/iga/GEDLibrary/GED_external/Source/common/version.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
2424
2525
======================= end_copyright_notice ==================================*/
2626

27-
const char* gedVersion = "0.36 (cd0b9a7e)";
27+
const char* gedVersion = "0.37 (8a8db73d)";

visa/iga/IGALibrary/Frontend/KernelParser.cpp

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1906,8 +1906,15 @@ class KernelParser : GenParser
19061906
if (dty != Type::INVALID) {
19071907
int typeSize = TypeSizeInBits(dty)/8;
19081908
if (!ri.isSubRegByteOffsetValid(regNum, subregNum * typeSize, m_model.getGRFByteSize())) {
1909-
Error(subregLoc,
1910-
"subregister out of bounds for data type", ToSyntax(dty));
1909+
if (ri.regName == RegName::GRF_R) {
1910+
Error(subregLoc,
1911+
"subregister out of bounds for data type", ToSyntax(dty));
1912+
} else {
1913+
// Print warning for non-GRF register, in case for those valid but strange case
1914+
// e.g. null0.20:f
1915+
Warning(subregLoc,
1916+
"subregister out of bounds for data type");
1917+
}
19111918
} else if (typeSize < ri.accGran) {
19121919
Warning(regnameLoc, "access granularity too small for data type");
19131920
}

visa/iga/IGALibrary/IR/SWSBSetter.cpp

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ void SWSBAnalyzer::calculateDependence(DepSet &currDep, SWSB &distanceDependency
335335
}
336336
// clear this instruction's dependency since it is satisfied
337337
clearDepBuckets(*dep);
338-
assert(dep->getCompanion() != nullptr);
338+
339339
// clear its companion because when an in-order instruction is synced, both its
340340
// input and output dependency are satisfied. The only case is that if it has
341341
// read/write_always_interfere dependency, it should be reserved.
@@ -346,9 +346,13 @@ void SWSBAnalyzer::calculateDependence(DepSet &currDep, SWSB &distanceDependency
346346
// mov (1|M0) r104.0<1>:ud sr0.1<0;1,0>:ud
347347
// cmp(16 | M0) (ne)f0.0 null:ud r104.0<0; 1, 0> : ub r62.4<0; 1, 0> : uw
348348
// A@1 is required for cmp instead of I@1
349-
if (dep->getCompanion()->getDepType() != DEP_TYPE::WRITE_ALWAYS_INTERFERE &&
350-
dep->getCompanion()->getDepType() != DEP_TYPE::READ_ALWAYS_INTERFERE)
351-
clearDepBuckets(*dep->getCompanion());
349+
if (dep->getCompanion() != nullptr) {
350+
// In the case that this DepSet is generated from math_wa_info, it won't have companion
351+
if (dep->getCompanion()->getDepType() != DEP_TYPE::WRITE_ALWAYS_INTERFERE &&
352+
dep->getCompanion()->getDepType() != DEP_TYPE::READ_ALWAYS_INTERFERE) {
353+
clearDepBuckets(*dep->getCompanion());
354+
}
355+
}
352356
} // end of if (prevDepClass == DEP_CLASS::IN_ORDER)
353357
else // prev is out of order
354358
{

visa/iga/IGALibrary/Models/Models.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,7 @@ static const struct RegInfo REGISTER_SPECIFICATIONS[] = {
7575
0x2, 0,
7676
1,
7777
2, (32,32)),
78-
IGA_REGISTER_SPEC_GE(
79-
Platform::GEN12P1,
78+
IGA_REGISTER_SPEC(Platform::GEN12P1, Platform::GEN12P1,
8079
RegName::ARF_ACC, "acc", "Accumulator",
8180
0x2, 0,
8281
1,
@@ -87,14 +86,11 @@ static const struct RegInfo REGISTER_SPECIFICATIONS[] = {
8786
0x2, 2, // offset by 2 "acc2-9"
8887
4,
8988
8, (32,32,32,32,32,32,32,32)),
90-
IGA_REGISTER_SPEC_GE(
91-
Platform::GEN12P1,
89+
IGA_REGISTER_SPEC(Platform::GEN12P1, Platform::GEN12P1,
9290
RegName::ARF_MME, "mme", "Math Macro",
9391
0x2, 8, // offset by 8 "acc8-15"
9492
4,
9593
8, (32,32,32,32,32,32,32,32)),
96-
97-
9894
IGA_REGISTER_SPEC_UNIFORM(
9995
RegName::ARF_F, "f", "Flag Register",
10096
0x3, 0,

visa/iga/IGALibrary/version.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,6 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
2626

2727
#ifndef _IGA_VERSION_HPP_
2828
#define _IGA_VERSION_HPP_
29-
#define IGA_VERSION_STRING "0.15.12"
29+
#define IGA_VERSION_STRING "0.15.13"
3030

3131
#endif // _IGA_VERSION_HPP_

0 commit comments

Comments
 (0)