Skip to content

Commit 6d2d081

Browse files
pratikashargfxbot
authored andcommitted
Report 32-byte aligned scratch offset to gtpin
Change-Id: Ia747ffc36d6178b3d99586f3a83b89fefa287d91
1 parent cc0e9f3 commit 6d2d081

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

visa/FlowGraph.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1167,7 +1167,10 @@ class gtPinData
11671167
// return igc_info_t format buffer. caller casts it to igc_info_t.
11681168
void* getGTPinInfoBuffer(unsigned int &bufferSize);
11691169

1170-
void setScratchNextFree(unsigned int next) { nextScratchFree = next; }
1170+
void setScratchNextFree(unsigned int next)
1171+
{
1172+
nextScratchFree = ((next + G4_GRF_REG_NBYTES - 1) / G4_GRF_REG_NBYTES) * G4_GRF_REG_NBYTES;
1173+
}
11711174
uint8_t getNumBytesScratchUse()
11721175
{
11731176
if (gtpin_init)

0 commit comments

Comments
 (0)