Skip to content

8388115: Provide os::vm_min_address() for BSD - #67

Merged
bsdkurt merged 1 commit into
battleblow:bsd-portfrom
bsdkurt:bsd.vm
Jul 18, 2026
Merged

8388115: Provide os::vm_min_address() for BSD#67
bsdkurt merged 1 commit into
battleblow:bsd-portfrom
bsdkurt:bsd.vm

Conversation

@bsdkurt

@bsdkurt bsdkurt commented Jul 16, 2026

Copy link
Copy Markdown
Collaborator

https://bugs.openjdk.org/browse/JDK-8388115 requests implementation of os::vm_min_address() and os::vm_max_address() for BSD. os::vm_max_address() has not yet been merged into master but I have discussed the current BSD implementation of os::vm_min_address() with @tstuefe and came up with this change.

This PR is for correctness and does not change the return value of os::vm_min_address() on BSD because VM_MIN_ADDRESS is less then _vm_min_address_default on FreeBSD, OpenBSD and NetBSD. However, if some future architecture or future change to VM_MIN_ADDRESS makes it greater then _vm_min_address_default, the jdk is prepared for that change.

Of note is that _vm_min_address_default not only is the default value but also serves as a minimum value the JDK supports. When openjdk#31864 lands in master, I will follow up with BSD implementation of os::vm_max_address() that uses VM_MAXUSER_ADDRESS.


@bsdkurt
bsdkurt requested review from battleblow and snake66 July 16, 2026 15:12

@tstuefe tstuefe left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Looks good to me (but I have no official role in the bsd project I think)

@snake66 snake66 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Looked at the discussion in the OpenJDK bug issue, and this change makes sense to me.

@bsdkurt
bsdkurt merged commit 19e96ae into battleblow:bsd-port Jul 18, 2026
246 of 250 checks passed
@bsdkurt
bsdkurt deleted the bsd.vm branch July 18, 2026 13:12
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