Skip to content

support reduce op with fast implementation #314

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 10, 2024

Conversation

WangJialei-A
Copy link
Contributor

Try to resolve #175

@@ -131,16 +132,18 @@ def get_dtype(dtype: str) -> torch.dtype:
return torch.bfloat16
elif dtype == "u8" or dtype == "ui8":
return torch.uint8
elif dtype == "s8" or dtype == "i8":
elif dtype in ["s8", "i8", "si8"]:
Copy link
Contributor

@ZhennanQin ZhennanQin Sep 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do si8 and si32 mean?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

signless -> i32/i8
signed -> si32/si8
unsigned -> ui32/ui8

@WangJialei-A WangJialei-A force-pushed the wangjial/benchgc_reduce branch from 11ed38f to 9ef7f69 Compare September 9, 2024 04:07
@@ -42,6 +42,19 @@ def ref_constant(
)
else:
raise Exception("only support splat value now")
elif isinstance(value, gc_mlir._mlir_libs._mlir.ir.IntegerAttr):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gc_mlir._mlir_libs._mlir.ir -> ir

@WangJialei-A WangJialei-A force-pushed the wangjial/benchgc_reduce branch from 9ef7f69 to 92be909 Compare September 9, 2024 07:57
@WangJialei-A WangJialei-A force-pushed the wangjial/benchgc_reduce branch from 92be909 to b3cbfaa Compare September 9, 2024 08:10
Copy link
Contributor

@xurui1995 xurui1995 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@WangJialei-A WangJialei-A merged commit 2d27682 into main Sep 10, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fast reduce op reference support in benchgc
3 participants