File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -800,7 +800,8 @@ void MCELFStreamer::createAttributesWithSubsection(
800800 if (AttributeSection) {
801801 switchSection (AttributeSection);
802802 } else {
803- AttributeSection = getContext ().getELFSection (Section, Type, 0 );
803+ AttributeSection =
804+ getContext ().getELFSection (Section, Type, ELF::SHF_EXCLUDE);
804805 switchSection (AttributeSection);
805806
806807 // Format version
Original file line number Diff line number Diff line change 11; RUN: llc %s -o - | FileCheck %s --check-prefix=ASM
2- ; RUN: llc %s -filetype=obj -o - | llvm-readelf --hex-dump=.ARM.attributes - | FileCheck %s --check-prefix=ELF
2+ ; RUN: llc %s -filetype=obj -o - | llvm-readelf --section-details -- hex-dump=.ARM.attributes - | FileCheck %s --check-prefix=ELF
33
44; ASM: .aeabi_subsection aeabi_feature_and_bits, optional, uleb128
55; ASM-NEXT: .aeabi_attribute Tag_Feature_BTI, 1
66; ASM-NEXT: .aeabi_attribute Tag_Feature_PAC, 1
77; ASM-NEXT: .aeabi_attribute Tag_Feature_GCS, 1
88
9+ ; ELF: Section Headers:
10+ ; ELF: .ARM.attributes
11+ ; ELF-NEXT: 0000000000000000
12+ ; ELF-NEXT: EXCLUDE
13+
914; ELF: Hex dump of section '.ARM.attributes':
1015; ELF-NEXT: 0x00000000 41230000 00616561 62695f66 65617475 A#...aeabi_featu
1116; ELF-NEXT: 0x00000010 72655f61 6e645f62 69747300 01000001 re_and_bits.....
You can’t perform that action at this time.
0 commit comments