Skip to content

Add hipcub::AliasTemporaries and some macros - #438

Merged
stanleytsang-amd merged 3 commits into
ROCm:release-staging/rocm-rel-6.4from
StreamHPC:alias_temporaries_and_macros
Dec 4, 2024
Merged

stanleytsang-amd merged 3 commits into
ROCm:release-staging/rocm-rel-6.4from
StreamHPC:alias_temporaries_and_macros

Conversation

@NB4444

@NB4444 NB4444 commented Nov 29, 2024 •

Copy link
Copy Markdown
Contributor

For CUDA parity added some missing functionality. The hipcub::AliasTemporaries and some missing macros.
First ROCm/rocPRIM#658 needs to be merged.

@NB4444
NB4444 force-pushed the alias_temporaries_and_macros branch from 14564dd to 749f85c Compare November 29, 2024 15:16
spolifroni-amd
spolifroni-amd previously approved these changes Nov 29, 2024

@spolifroni-amd spolifroni-amd left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I left a review comment. I won't block merging because it's a minor thing, but it would be good if it were addressed.

Comment thread CHANGELOG.md Outdated
* Added `--emulation` option for `rtest.py`
* Unit tests can be run with `[--emulation|-e|--test|-t]=<test_name>`
* Added `DeviceSelect::FlaggedIf` and its inplace overload.
* Added CUB macros missing from hipCUB

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This needs a bit more detail. Listing the macros would be helpful for users. If the macros can't be listed because the list is to long, say, then generally saying which broad categories of macros or similar would be good.

Suggested change
* Added CUB macros missing from hipCUB
* Added CUB macros missing from hipCUB.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Added a list of macros.

@stanleytsang-amd

Copy link
Copy Markdown
Collaborator

@NB4444 Can you target this PR to the release-staging/rocm-rel-6.4 branch as well? Thanks.

@NB4444
NB4444 changed the base branch from develop to release-staging/rocm-rel-6.4 December 2, 2024 06:38
@NB4444
NB4444 dismissed spolifroni-amd’s stale review December 2, 2024 06:38

The base branch was changed.

@NguyenNhuDi NguyenNhuDi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

lgtm

@stanleytsang-amd
stanleytsang-amd merged commit 5701ac4 into ROCm:release-staging/rocm-rel-6.4 Dec 4, 2024
stanleytsang-amd pushed a commit that referenced this pull request Dec 9, 2024
* Include device_copy header (#433)

The device/device_copy.hpp header was missing from the main hipcub.hpp
header file. This change just adds it back.

* [windows][hipCUB] Removed usage of std::unary_function and std::binary_function to prevent syntax error (#435)

* removed ussage of std::unary/binary_function

* updated changelog

* Enable CMake HIP language (#434)

If the HIP language can be used, the HIP_USECXX variable sets rocThrust to use the CMake HIP language rather than CXX.

Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>

* Add hipcub::AliasTemporaries and some macros (#438)

* Resolve "Add missing macros in HIPCUB API"

* Resolve "Add AliasTemporaries function"

* Added macro names to CHANGELOG

---------

Co-authored-by: Wayne Franz <wayfranz@amd.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
umfranzw added a commit that referenced this pull request Apr 22, 2025
* Include device_copy header (#433)

The device/device_copy.hpp header was missing from the main hipcub.hpp
header file. This change just adds it back.

* [windows][hipCUB] Removed usage of std::unary_function and std::binary_function to prevent syntax error (#435)

* removed ussage of std::unary/binary_function

* updated changelog

* Enable CMake HIP language (#434)

If the HIP language can be used, the HIP_USECXX variable sets rocThrust to use the CMake HIP language rather than CXX.

Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>

* Add hipcub::AliasTemporaries and some macros (#438)

* Resolve "Add missing macros in HIPCUB API"

* Resolve "Add AliasTemporaries function"

* Added macro names to CHANGELOG

* Created installation section (#440) (#458)

* these files aren't used. part of them is in What Is

* changed 'integral' to 'integer'

* Added installation files

* Update README.md

* changing the link

* reworded what is and data type support

* Update docs/install/hipCUB-prerequisites.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* Update docs/install/hipCUB-install-on-Windows.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* added link to cmake

* uppercases.

---------

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>
(cherry picked from commit 0c83055)

* Limit test_hipcub_device_radix_sort memory usage (#454)

* Limit test_hipcub_device_radix_sort memory usage

On Windows, HipcubDeviceRadixSort.SortKeysLargeSizes fails due to an
out of memory error on some devices. This happens because of an issue
that sometimes causes hipMalloc to return hipSuccess for some allocation
requests that are too large. This prevents us from being able to
reliably detect whether a data size is too large for the test.

This change works around the problem for now by limiting the data sizes
that used are used for the test.

* Update CHANGELOG.md

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>

* Update test/hipcub/test_hipcub_device_radix_sort.hpp

Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: Wayne Franz <wayfranz@amd.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>
umfranzw added a commit that referenced this pull request Apr 28, 2025
* [hipCUB] Mergeback 6.4 changes (#466)

* Include device_copy header (#433)

The device/device_copy.hpp header was missing from the main hipcub.hpp
header file. This change just adds it back.

* [windows][hipCUB] Removed usage of std::unary_function and std::binary_function to prevent syntax error (#435)

* removed ussage of std::unary/binary_function

* updated changelog

* Enable CMake HIP language (#434)

If the HIP language can be used, the HIP_USECXX variable sets rocThrust to use the CMake HIP language rather than CXX.

Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>

* Add hipcub::AliasTemporaries and some macros (#438)

* Resolve "Add missing macros in HIPCUB API"

* Resolve "Add AliasTemporaries function"

* Added macro names to CHANGELOG

* Created installation section (#440) (#458)

* these files aren't used. part of them is in What Is

* changed 'integral' to 'integer'

* Added installation files

* Update README.md

* changing the link

* reworded what is and data type support

* Update docs/install/hipCUB-prerequisites.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* Update docs/install/hipCUB-install-on-Windows.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* added link to cmake

* uppercases.

---------

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>
(cherry picked from commit 0c83055)

* Limit test_hipcub_device_radix_sort memory usage (#454)

* Limit test_hipcub_device_radix_sort memory usage

On Windows, HipcubDeviceRadixSort.SortKeysLargeSizes fails due to an
out of memory error on some devices. This happens because of an issue
that sometimes causes hipMalloc to return hipSuccess for some allocation
requests that are too large. This prevents us from being able to
reliably detect whether a data size is too large for the test.

This change works around the problem for now by limiting the data sizes
that used are used for the test.

* Update CHANGELOG.md

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>

* Update test/hipcub/test_hipcub_device_radix_sort.hpp

Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: Wayne Franz <wayfranz@amd.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

* Update version number for ROCm 6.5.0 release (#477)

This change updated the hipCUB version number to 3.5.0.
It also removes the "(unreleased)" note from the changelog
heading for this release.

---------

Co-authored-by: Di Nguyen <dinguyennhu@gmail.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>
umfranzw added a commit that referenced this pull request May 2, 2025
* [hipCUB] Mergeback 6.4 changes (#466)

* Include device_copy header (#433)

The device/device_copy.hpp header was missing from the main hipcub.hpp
header file. This change just adds it back.

* [windows][hipCUB] Removed usage of std::unary_function and std::binary_function to prevent syntax error (#435)

* removed ussage of std::unary/binary_function

* updated changelog

* Enable CMake HIP language (#434)

If the HIP language can be used, the HIP_USECXX variable sets rocThrust to use the CMake HIP language rather than CXX.

Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>

* Add hipcub::AliasTemporaries and some macros (#438)

* Resolve "Add missing macros in HIPCUB API"

* Resolve "Add AliasTemporaries function"

* Added macro names to CHANGELOG

* Created installation section (#440) (#458)

* these files aren't used. part of them is in What Is

* changed 'integral' to 'integer'

* Added installation files

* Update README.md

* changing the link

* reworded what is and data type support

* Update docs/install/hipCUB-prerequisites.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* Update docs/install/hipCUB-install-on-Windows.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* added link to cmake

* uppercases.

---------

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>
(cherry picked from commit 0c83055)

* Limit test_hipcub_device_radix_sort memory usage (#454)

* Limit test_hipcub_device_radix_sort memory usage

On Windows, HipcubDeviceRadixSort.SortKeysLargeSizes fails due to an
out of memory error on some devices. This happens because of an issue
that sometimes causes hipMalloc to return hipSuccess for some allocation
requests that are too large. This prevents us from being able to
reliably detect whether a data size is too large for the test.

This change works around the problem for now by limiting the data sizes
that used are used for the test.

* Update CHANGELOG.md

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>

* Update test/hipcub/test_hipcub_device_radix_sort.hpp

Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: Wayne Franz <wayfranz@amd.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

* Update version number for ROCm 6.5.0 release (#477)

This change updated the hipCUB version number to 3.5.0.
It also removes the "(unreleased)" note from the changelog
heading for this release.

---------

Co-authored-by: Di Nguyen <dinguyennhu@gmail.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>
ammallya pushed a commit that referenced this pull request Oct 28, 2025
* Include device_copy header (#433)

The device/device_copy.hpp header was missing from the main hipcub.hpp
header file. This change just adds it back.

* [windows][hipCUB] Removed usage of std::unary_function and std::binary_function to prevent syntax error (#435)

* removed ussage of std::unary/binary_function

* updated changelog

* Enable CMake HIP language (#434)

If the HIP language can be used, the HIP_USECXX variable sets rocThrust to use the CMake HIP language rather than CXX.

Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>

* Add hipcub::AliasTemporaries and some macros (#438)

* Resolve "Add missing macros in HIPCUB API"

* Resolve "Add AliasTemporaries function"

* Added macro names to CHANGELOG

---------

Co-authored-by: Wayne Franz <wayfranz@amd.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>

[ROCm/hipCUB commit: d781413]
ammallya pushed a commit that referenced this pull request Oct 28, 2025
* [hipCUB] Mergeback 6.4 changes (#466)

* Include device_copy header (#433)

The device/device_copy.hpp header was missing from the main hipcub.hpp
header file. This change just adds it back.

* [windows][hipCUB] Removed usage of std::unary_function and std::binary_function to prevent syntax error (#435)

* removed ussage of std::unary/binary_function

* updated changelog

* Enable CMake HIP language (#434)

If the HIP language can be used, the HIP_USECXX variable sets rocThrust to use the CMake HIP language rather than CXX.

Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>

* Add hipcub::AliasTemporaries and some macros (#438)

* Resolve "Add missing macros in HIPCUB API"

* Resolve "Add AliasTemporaries function"

* Added macro names to CHANGELOG

* Created installation section (#440) (#458)

* these files aren't used. part of them is in What Is

* changed 'integral' to 'integer'

* Added installation files

* Update README.md

* changing the link

* reworded what is and data type support

* Update docs/install/hipCUB-prerequisites.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* Update docs/install/hipCUB-install-on-Windows.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* added link to cmake

* uppercases.

---------

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>
(cherry picked from commit 51efcae)

* Limit test_hipcub_device_radix_sort memory usage (#454)

* Limit test_hipcub_device_radix_sort memory usage

On Windows, HipcubDeviceRadixSort.SortKeysLargeSizes fails due to an
out of memory error on some devices. This happens because of an issue
that sometimes causes hipMalloc to return hipSuccess for some allocation
requests that are too large. This prevents us from being able to
reliably detect whether a data size is too large for the test.

This change works around the problem for now by limiting the data sizes
that used are used for the test.

* Update CHANGELOG.md

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>

* Update test/hipcub/test_hipcub_device_radix_sort.hpp

Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: Wayne Franz <wayfranz@amd.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

* Update version number for ROCm 6.5.0 release (#477)

This change updated the hipCUB version number to 3.5.0.
It also removes the "(unreleased)" note from the changelog
heading for this release.

---------

Co-authored-by: Di Nguyen <dinguyennhu@gmail.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

[ROCm/hipCUB commit: 9930632]
ammallya pushed a commit that referenced this pull request Oct 28, 2025
* [hipCUB] Mergeback 6.4 changes (#466)

* Include device_copy header (#433)

The device/device_copy.hpp header was missing from the main hipcub.hpp
header file. This change just adds it back.

* [windows][hipCUB] Removed usage of std::unary_function and std::binary_function to prevent syntax error (#435)

* removed ussage of std::unary/binary_function

* updated changelog

* Enable CMake HIP language (#434)

If the HIP language can be used, the HIP_USECXX variable sets rocThrust to use the CMake HIP language rather than CXX.

Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>

* Add hipcub::AliasTemporaries and some macros (#438)

* Resolve "Add missing macros in HIPCUB API"

* Resolve "Add AliasTemporaries function"

* Added macro names to CHANGELOG

* Created installation section (#440) (#458)

* these files aren't used. part of them is in What Is

* changed 'integral' to 'integer'

* Added installation files

* Update README.md

* changing the link

* reworded what is and data type support

* Update docs/install/hipCUB-prerequisites.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* Update docs/install/hipCUB-install-on-Windows.rst

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>

* added link to cmake

* uppercases.

---------

Co-authored-by: Leo Paoletti <164940351+lpaoletti@users.noreply.github.com>
(cherry picked from commit 51efcae)

* Limit test_hipcub_device_radix_sort memory usage (#454)

* Limit test_hipcub_device_radix_sort memory usage

On Windows, HipcubDeviceRadixSort.SortKeysLargeSizes fails due to an
out of memory error on some devices. This happens because of an issue
that sometimes causes hipMalloc to return hipSuccess for some allocation
requests that are too large. This prevents us from being able to
reliably detect whether a data size is too large for the test.

This change works around the problem for now by limiting the data sizes
that used are used for the test.

* Update CHANGELOG.md

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>

* Update test/hipcub/test_hipcub_device_radix_sort.hpp

Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

---------

Co-authored-by: Wayne Franz <wayfranz@amd.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

* Update version number for ROCm 6.5.0 release (#477)

This change updated the hipCUB version number to 3.5.0.
It also removes the "(unreleased)" note from the changelog
heading for this release.

---------

Co-authored-by: Di Nguyen <dinguyennhu@gmail.com>
Co-authored-by: Lauren Wrubleski <Lauren.Wrubleski@amd.com>
Co-authored-by: Nick Breed <78807921+NB4444@users.noreply.github.com>
Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
Co-authored-by: Nara <naraenda@prasetya.eu>

[ROCm/hipCUB commit: 040c29d]
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.

4 participants