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

Simplify pitch API #2092

Merged
merged 4 commits into from
Aug 29, 2023
Merged

Conversation

bernhardmgruber
Copy link
Member

@bernhardmgruber bernhardmgruber commented Aug 25, 2023

  • Add getPitchesInBytes and GetPitchesInBytes returning extents as alpaka::Vec.
  • Deprecate getPitchBytes, GetPitchBytes and getPitchBytesVec.
  • Includes 2 unrelated refactorings and an improvement to the reporting if the bytes of a view were correctly set.

Fixes: #2079

@bernhardmgruber bernhardmgruber force-pushed the pitch_ref branch 2 times, most recently from 07d5559 to bd8f64e Compare August 26, 2023 12:37
@bernhardmgruber bernhardmgruber marked this pull request as ready for review August 26, 2023 12:37
@bernhardmgruber bernhardmgruber force-pushed the pitch_ref branch 3 times, most recently from 151f378 to 5341cfd Compare August 28, 2023 07:56
Copy link
Member

@psychocoderHPC psychocoderHPC left a comment

Choose a reason for hiding this comment

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

I annotated only two lines but from our developer discussion last week I thought the pitch will be defined as the number of bytes to jump within the dimension, so
3-dim: (y-x-plane-bytes, x-line-bytes, element-bytes) if so it looks like the changes are wrong, if my definition is wrong than I missed the new definition of getPitchInBytes()

example/bufferCopy/src/bufferCopy.cpp Show resolved Hide resolved
example/randomCells2D/src/randomCells2D.cpp Show resolved Hide resolved
@psychocoderHPC
Copy link
Member

I annotated only two lines but from our developer discussion last week I thought the pitch will be defined as the number of bytes to jump within the dimension, so 3-dim: (y-x-plane-bytes, x-line-bytes, element-bytes) if so it looks like the changes are wrong, if my definition is wrong than I missed the new definition of getPitchInBytes()

Ignore this, I have not seen that there is a second PR #2093 that is changing the behavior.

@bernhardmgruber
Copy link
Member Author

The TSAN failure in the coreTest seems unreleated, but I don't have time to look into it the next days.

This fixes a warning by nvcc.
* Add getPitchesInBytes and GetPitchesInBytes returning extents as alpaka::Vec
* Deprecate getPitchBytes, GetPitchBytes and getPitchBytesVec
* Refactor BufUniformCudaHipRt to always store row pitch

Fixes: alpaka-group#2079
@psychocoderHPC psychocoderHPC merged commit a1edf6e into alpaka-group:develop Aug 29, 2023
21 checks passed
@bernhardmgruber bernhardmgruber deleted the pitch_ref branch August 29, 2023 15:39
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.

Squash extent/offset/pitch traits
4 participants