ANDROID: kbuild: merge more sections with LTO

Merge the following new data sections generated by current
LLVM versions:

  .bss..L* .bss..compoundliteral*
  .data..L* .data..compoundliteral*
  .rodata..L* .rodata..compoundliteral*

Also drop the unnecessary rules to merge .rela sections.

Bug: 158605670
Change-Id: I098212bc74dfb6b54d4fd60d90957fea29122a6c
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
This commit is contained in:
Sami Tolvanen 2020-06-10 10:14:32 -07:00
parent d39c24f5c2
commit 23cbf245be

View file

@ -15,12 +15,20 @@ SECTIONS {
*(.eh_frame)
}
.bss : { *(.bss .bss.[0-9a-zA-Z_]*) }
.data : { *(.data .data.[0-9a-zA-Z_]*) }
.rela.data : { *(.rela.data .rela.data.[0-9a-zA-Z_]*) }
.rela.rodata : { *(.rela.rodata .rela.rodata.[0-9a-zA-Z_]*) }
.rela.text : { *(.rela.text .rela.text.[0-9a-zA-Z_]*) }
.rodata : { *(.rodata .rodata.[0-9a-zA-Z_]*) }
.bss : {
*(.bss .bss.[0-9a-zA-Z_]*)
*(.bss..L* .bss..compoundliteral*)
}
.data : {
*(.data .data.[0-9a-zA-Z_]*)
*(.data..L* .data..compoundliteral*)
}
.rodata : {
*(.rodata .rodata.[0-9a-zA-Z_]*)
*(.rodata..L* .rodata..compoundliteral*)
}
/*
* With CFI_CLANG, ensure __cfi_check is at the beginning of the
@ -30,5 +38,4 @@ SECTIONS {
*(.text.__cfi_check)
*(.text .text.[0-9a-zA-Z_]* .text..L.cfi*)
}
}