Skip to content
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

[MLIR][TOSA] Fix f16/bf16 support for MaxPool2D (#69332) #107

Merged
merged 1 commit into from
Feb 22, 2024

Conversation

ljfitz
Copy link
Collaborator

@ljfitz ljfitz commented Feb 22, 2024

Cherry-pick https://github.com/llvm/llvm-project/pull 69332

Currently, the MaxPool2D operation in the TOSA MLIR dialect does not accept half-precision Fp16 and Bf16 tensors, converse to what is stated in the TOSA
Specification
.

This patch fixes the verifier to accept the two datatypes for input/output tensors, and adds related LIT test cases in Tosa/ops.mlir

Currently, the MaxPool2D operation in the TOSA MLIR dialect does not
accept half-precision Fp16 and Bf16 tensors, converse to what is stated
in the [TOSA
Specification](https://www.mlplatform.org/tosa/tosa_spec.html#_max_pool2d).

This patch fixes the verifier to accept the two datatypes for
input/output tensors, and adds related LIT test cases in Tosa/ops.mlir
@ljfitz ljfitz requested a review from ttjost February 22, 2024 09:36
@ttjost ttjost merged commit 2b2a9fc into feature/fused-ops Feb 22, 2024
3 checks passed
@ttjost ttjost deleted the ljfitz.tosa_maxpool_bf16_to_linalg branch February 22, 2024 12:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants