Skip to content

Commit cce4066

Browse files
Merge pull request #25548 from andportnoy:aportnoy/mosaic-gpu-scalar-argument-64-bit-fix
PiperOrigin-RevId: 707295328
2 parents 83ca7c3 + 6ea4708 commit cce4066

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

tests/mosaic/gpu_test.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -371,6 +371,13 @@ def kernel(ctx, inp, out, _):
371371

372372
@parameterized.parameters(jnp.uint64, jnp.uint32, jnp.uint16, jnp.uint8)
373373
def test_scalar_argument(self, dtype):
374+
if dtype == jnp.uint64 and not config.enable_x64.value:
375+
self.skipTest(
376+
"64-bit types are disabled: this leads to the input scalar being"
377+
" traced as a uint32 value, which causes the top 32 bits of the 64-bit"
378+
" values read from the 32-bit input buffer to sometimes"
379+
" (nondeterministically) contain garbage.")
380+
374381
scalar = 42
375382
expected = np.full((128, 128), scalar, dtype=dtype)
376383

0 commit comments

Comments
 (0)