[chrome.clang] applied patch D145474 #26
Merged
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.
Back porting https://reviews.llvm.org/D145474?id=504334 Note there were 3 unit-test cases failed with this patch, but these failures exits on latest main(17) at that time, not on clang 16 we use here.
These failed cases has been fixed by
https://reviews.llvm.org/rG0ddc283a29a7a2d5415a3d363396e39c262a5dc2 and D145474 also caught up with
https://reviews.llvm.org/D145474?id=505297. But I don't catch up with it because I think they will not impact our riscv64.
The patch I apploed in this commitment fixed following two bugs:
ld.lld: error: obj/buildtools/third_party/libc++/libc++/algorithm.o:(.rodata.str1.1): offset is outside the section
compile error from third_party/crashpad/crashpad/client/crashpad_info_note.S target: //third_party/crashpad/crashpad/client:client
simplified code sample:
.section .note.sample.info,"a",%note .balign 4 _SYMBOL2: #if defined(__LP64__) .quad _SYMBOL1 - _SYMBOL2 #else .long _SYMBOL1 - _SYMBOL2 #endif // __LP64__
compiler reports error: /tmp/t-739c86.s:8:9: error: Unsupported relocation type .quad _SYMBOL1 - _SYMBOL2