Skip to content

Another INIT_DEBUG_VALUE_JPRB hack#152

Merged
awnawab merged 1 commit into
mainfrom
naan-field-defaults-jprb-hack
Jun 22, 2026
Merged

Another INIT_DEBUG_VALUE_JPRB hack#152
awnawab merged 1 commit into
mainfrom
naan-field-defaults-jprb-hack

Conversation

@awnawab

@awnawab awnawab commented Jun 18, 2026

Copy link
Copy Markdown
Collaborator

This PR contributes yet another INIT_DEBUG_VALUE_JPRB hack. In certain situations we can get memory corruptions because a precision dependent symbol is being linked to precision independent object libraries, which can be worked around by making it the last defined variable in the module.

field_api took a very intentional design decision to keep JPRB only as an aliased symbol, that's why INIT_DEBUG_VALUE_JPRB is unused throughout the code. It would be great if we could remove it and clean up all related workarounds.

This also causes other issues with flang, as outlined in #138.

@mlange05 mlange05 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.

Looks good to me. 👍

@awnawab awnawab merged commit 584ebe3 into main Jun 22, 2026
243 of 252 checks passed
@awnawab awnawab deleted the naan-field-defaults-jprb-hack branch June 22, 2026 12:28
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