Skip to content

Commit 2cfa97d

Browse files
bcheng0127igcbot
authored andcommitted
Update DPAS latency
The latency will be used in the instruction scheduling and SWSB dependence tracking.
1 parent d9f3a71 commit 2cfa97d

File tree

3 files changed

+14
-3
lines changed

3 files changed

+14
-3
lines changed

visa/G4_IR.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7702,6 +7702,15 @@ bool G4_InstDpas::isInt() const {
77027702
return false;
77037703
}
77047704

7705+
bool G4_InstDpas::isInt8() const {
7706+
if (Src1Precision == GenPrecision::S8 || Src1Precision == GenPrecision::U8 ||
7707+
Src2Precision == GenPrecision::S8 || Src2Precision == GenPrecision::U8) {
7708+
return true;
7709+
}
7710+
7711+
return false;
7712+
}
7713+
77057714
bool G4_InstDpas::is2xInt8() const {
77067715
if ((Src1Precision == GenPrecision::S4 || Src1Precision == GenPrecision::U4 ||
77077716
Src1Precision == GenPrecision::S2 ||

visa/G4_IR.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1006,6 +1006,7 @@ class G4_InstDpas : public G4_INST {
10061006
bool isFP16() const { return Src1Precision == GenPrecision::FP16; }
10071007
bool isTF32() const { return Src1Precision == GenPrecision::TF32; }
10081008
bool isInt() const;
1009+
bool isInt8() const;
10091010
bool is2xInt8() const; // true if it is 2xint8 dpas
10101011

10111012
uint8_t getOpsPerChan() const;

visa/LocalScheduler/LatencyTable.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -306,9 +306,10 @@ LatencyTableXe<PlatformGen::XE>::getMathLatency(const G4_INST *Inst) const {
306306
return value_of(LI::MATH) + value_of(LI::DELTA_MATH) * Scale;
307307
}
308308

309-
template<>
310-
uint16_t LatencyTableXe<PlatformGen::XE>::getDPASLatency(
311-
const G4_InstDpas *dpas) const {
309+
template <>
310+
uint16_t
311+
LatencyTableXe<PlatformGen::XE>::getDPASLatency(const G4_InstDpas *dpas) const {
312+
312313
return getDPASLatency(dpas->getRepeatCount());
313314
}
314315

0 commit comments

Comments
 (0)