mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-15 03:26:05 +00:00
COFF: Do not assign linker-weak symbols to selectany comdat sections.
It is mandatory to specify a comdat in order to receive comdat semantics for a symbol. We were previously getting this wrong in -function-sections mode; linker-weak symbols were being emitted in a selectany comdat. This change causes such symbols to use a noduplicates comdat instead, fixing the inconsistency. Also correct an inaccuracy in the docs. Differential Revision: http://reviews.llvm.org/D10828 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@241103 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -840,8 +840,6 @@ static int getSelectionForCOFF(const GlobalValue *GV) {
|
||||
} else {
|
||||
return COFF::IMAGE_COMDAT_SELECT_ASSOCIATIVE;
|
||||
}
|
||||
} else if (GV->isWeakForLinker()) {
|
||||
return COFF::IMAGE_COMDAT_SELECT_ANY;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user