Adjust ASM_CONST indexes when building with -s RELOCATABLE#9747
Merged
Adjust ASM_CONST indexes when building with -s RELOCATABLE#9747
-s RELOCATABLE#9747Conversation
Collaborator
Author
|
I should have landed this before: WebAssembly/binaryen#2408 This is now blocking binaryen from rolling in emscripten-releases. Once we land this PR binaryen should be able to roll again. |
jgravelle-google
approved these changes
Oct 31, 2019
| if shared.Settings.RELOCATABLE: | ||
| # TODO(sbc): remove this conidtion after | ||
| # https://github.com/WebAssembly/binaryen/pull/2408 lands | ||
| preamble += '\n if (core > %s) code -= %s;\n' % (shared.Settings.GLOBAL_BASE, shared.Settings.GLOBAL_BASE) |
Contributor
There was a problem hiding this comment.
Nit: in general can use '{0} foo {0}'.format(bar) to deduplicate str format args
Not really needed for this temp thing so lgtm as-is
For reloctable code (i.e. MAIN_MODULE) ASM_CONST offsets are relative to the GLOBAL_BASE.
b8cdbc1 to
4dc4c64
Compare
belraquib
pushed a commit
to belraquib/emscripten
that referenced
this pull request
Dec 23, 2020
…ten-core#9747) For reloctable code (i.e. MAIN_MODULE) ASM_CONST offsets are relative to the GLOBAL_BASE.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
For reloctable code (i.e. MAIN_MODULE) ASM_CONST offsets are relative to
the GLOBAL_BASE.