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

Update java8 openj9 unsafe test for new off-heap case #20436

Merged
merged 1 commit into from
Nov 1, 2024

Conversation

LinHu2016
Copy link
Contributor

In TestUnsafeCopyMemory.testCopyLargeArrayIntoRawMemory(), arrayBaseOffset has been used to generate the arbitrary arrayOffsets for copy, the original test assume that arrayBaseOffset is positive number( array header size), but for off-heap enabled case arrayBaseOffset =0, which could cause negative offset for testing copy(trigger exceptions), update the test code to avoid negative offset for copying.

@LinHu2016
Copy link
Contributor Author

@llxia please review the changes, Thanks

@llxia
Copy link
Contributor

llxia commented Oct 30, 2024

In TestUnsafeCopyMemory.testCopyLargeArrayIntoRawMemory(),
arrayBaseOffset has been used to generate the arbitrary arrayOffsets for
copy, the original test assume that arrayBaseOffset is positive number(
array header size), but for off-heap enabled case arrayBaseOffset =0,
which could cause negative offset for testing copy(trigger exceptions),
update the test code to avoid negative offset for copying.

Signed-off-by: lhu <linhu@ca.ibm.com>
Copy link
Contributor

@llxia llxia left a comment

Choose a reason for hiding this comment

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

LGTM

@llxia llxia merged commit 1fb0961 into eclipse-openj9:master Nov 1, 2024
2 checks passed
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.

2 participants