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

webgpu: fix notEqual error #6669

Merged
merged 3 commits into from
Jul 27, 2022
Merged

webgpu: fix notEqual error #6669

merged 3 commits into from
Jul 27, 2022

Conversation

xhcao
Copy link
Contributor

@xhcao xhcao commented Jul 25, 2022

To see the logs from the Cloud Build CI, please join either our discussion or announcement mailing list.


This change is Reviewable

@gyagp
Copy link

gyagp commented Jul 25, 2022

Can we add some test cases to cover this?

@@ -109,8 +109,31 @@ const INT_DIV_VEC4 = `
return vec4<f32>(resultTemp);
`;

const NOT_EQUAL = 'return f32(a != b);';
const NOT_EQUAL_VEC4 = 'return vec4<f32>(a != b);';
const NOT_EQUAL = `
Copy link
Contributor

Choose a reason for hiding this comment

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

It seems that webgl also doesn't check isnan. Can you verify whether webgl has the similar issue on Linux?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

There is no the same issue on the webgl backend. I think the underlying driver or the bin of shader are not the same for these two backends. There are also some situations that webgl check isnan, but webgpu does not check.

Copy link
Contributor

@qjia7 qjia7 left a comment

Choose a reason for hiding this comment

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

LGTM, thanks.

Copy link

@gyagp gyagp left a comment

Choose a reason for hiding this comment

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

LGTM. Offline talked and we already have unit test cases to cover this.

@qjia7 qjia7 merged commit cfdc254 into tensorflow:master Jul 27, 2022
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