forked from rui314/mold
-
Notifications
You must be signed in to change notification settings - Fork 0
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
[pull] main from rui314:main #318
Open
pull
wants to merge
89
commits into
VitalyAnkh:main
Choose a base branch
from
rui314:main
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains 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
GCC doesn't accept a path as an argument to `-fuse-ld`. `-fuse-ld=mold` is enough. Tested with ``` gcc (GCC) 13.2.1 20231205 (Red Hat 13.2.1-6) ```
Old zlib does not support crc32_z. The difference between the two is that crc32() takes an input size as an unsigned int while crc32_z() takes as size_t. For our use case, size is guranteed to be short, so crc32() is safe to use.
Fixes #1326
The LoongArch extreme code model uses the following instructions to materialize a 64-bit value in a regiter. pcalau12i $t1, %pc_hi20(g2) addi.d $t0, $zero, %pc_lo12(g2) lu32i.d $t0, %pc64_lo20(g2) lu52i.d $t0, $t0, %pc64_hi12(g2) The previous relocation formula expected that `page(pc)` would be consistent for all the instructions, but this assumption is incorrect if the instruction sequence crosses a 4 KiB boundary. Now, the LoongArch psABI requires that the machine instructions must be consecutive, and the relocations for lu32.d and lu52i.d uses `page(pc - 8)` and `page(pc - 16)` instead of `page(pc)`. This psABI change gave me an impression that the LoongArch's extreme code model was poorly designed and inadequately tested. If these instructions must be consecutive, only a single relocation referring to the beginning of the instructions would suffice, which relocates all the following four instructions at once. Maybe we do not need to support the relocations for the extreme code model because the code model was buggy at the spec level, which suggests that no one is using them. But I'm not sure if it is safe to remove them, so let's just follow the psABI change.
It looks like Linux kernel reads this program header to enable BTI on ARM64.
alloca(3) is defined in stdlib.h on NetBSD Reference: https://man.netbsd.org/alloca.3 Signed-off-by: leleliu008 <leleliu008@gmail.com>
Word-size absolute relocations, such as R_X86_64_64, are special from the linker's point of view because only such symbols can be promoted to dynamic symbols. This patch handles them separately.
Assume both `foo.a` and `bar.so` define the same symbol `baz`. If `baz`'s symbol visibility is hidden, it needs to be resolved within the output file, i.e., from `foo.a`. However, previously, such symbol was resolved to the one in `bar.so`. To fix the problem, we'll lower the symbol priority for DSOs. Fixes #1342
This commit reverts 0612ea4 and instead solves the original issue with a different approach. Now, if a hidden symbol was resolved to a DSO symbol, we'll redo symbol resolution so that the symbol won't be resolved to the same one next time. This should fix our build-all buildbot.
Fixes #1340 Signed-off-by: Andreas Schwab <schwab@suse.de>
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.
See Commits and Changes for more details.
Created by pull[bot]
Can you help keep this open source service alive? 💖 Please sponsor : )