Skip to content

Commit

Permalink
Merge branch 'main' into triton
Browse files Browse the repository at this point in the history
  • Loading branch information
yuchengliu1 authored Aug 26, 2024
2 parents 860138d + 12d7ee7 commit 7f3bc2e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/xpu/xpu_test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -659,6 +659,11 @@ def align_supported_dtypes(self, db):
backward_dtypes.add(bfloat16)
opinfo.backward_dtypes = tuple(backward_dtypes)

if "has_fp64=0" in str(torch.xpu.get_device_properties(0)):
fp64_dtypes = [ torch.float64, torch.complex128, torch.double, ]
opinfo.dtypesIfXPU = set(filter(lambda x: (x not in fp64_dtypes), list(opinfo.dtypesIfXPU)))
opinfo.backward_dtypes = tuple(filter(lambda x: (x not in fp64_dtypes), list(opinfo.backward_dtypes)))

def __enter__(self):
# Monkey patch until we have a fancy way

Expand Down

0 comments on commit 7f3bc2e

Please sign in to comment.