Skip to content

Conversation

@haonanya
Copy link

@haonanya haonanya commented Sep 13, 2021

This fixes incorrect translation for FP-typed atomic_fetch_sub function
and addes tests.
Atomic functions which do not support floating types should be translted
to FunctionCall such as atomic_inc and atomic_or and so on. When
cl_ext_float_atomics is enabled, there are atomic_fetch_sub function
declaration on clang headers, but there are no corresponding SPIRV Atomic
instructions, so atomic_fetch_sub should be translted to FunctionCall as
before.

Signed-off-by: haonanya haonan.yang@intel.com

Copy link
Contributor

@wenju-he wenju-he left a comment

Choose a reason for hiding this comment

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

LGTM

This fixes incorrect translation for FP-typed atomic_fetch_sub function
and addes tests.
Atomic functions which do not support floating types should be translted
to FunctionCall such as atomic_inc and atomic_or and so on. When
cl_ext_float_atomics is enabled, there are atomic_fetch_sub function
declaration on clang headers, but there are no corresponding SPIRV Atomic
instructions, so atomic_fetch_sub should be translted to FunctionCall as
before.

Signed-off-by: haonanya <haonan.yang@intel.com>
@haonanya haonanya merged commit 4393ffb into intel:ocl-open-100 Sep 15, 2021
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