mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-22 21:51:36 +08:00
[Darwin, Objective-C] Switch Objective-C meta-data sections properly.
We were emitting the directives to switch, but not recording the change in varasm. This means that subsequent switches might be omitted (since varasm incorrectly concludes that the wrong section is current). 2019-09-03 Iain Sandoe <iain@sandoe.co.uk> Backport from mainline 2019-05-18 Iain Sandoe <iain@sandoe.co.uk> * config/darwin.c (darwin_file_end): Use switch_to_section () instead of direct output of the asm. From-SVN: r275349
This commit is contained in:
parent
de935e9c93
commit
825c1d10fa
@ -1,3 +1,11 @@
|
||||
2019-09-03 Iain Sandoe <iain@sandoe.co.uk>
|
||||
|
||||
Backport from mainline
|
||||
2019-05-18 Iain Sandoe <iain@sandoe.co.uk>
|
||||
|
||||
* config/darwin.c (darwin_file_end): Use switch_to_section ()
|
||||
instead of direct output of the asm.
|
||||
|
||||
2019-09-03 Iain Sandoe <iain@sandoe.co.uk>
|
||||
|
||||
Backport from mainline
|
||||
|
@ -2908,12 +2908,10 @@ darwin_file_end (void)
|
||||
if (flag_objc_abi >= 2)
|
||||
{
|
||||
flags = 16;
|
||||
output_section_asm_op
|
||||
(darwin_sections[objc2_image_info_section]->unnamed.data);
|
||||
switch_to_section (darwin_sections[objc2_image_info_section]);
|
||||
}
|
||||
else
|
||||
output_section_asm_op
|
||||
(darwin_sections[objc_image_info_section]->unnamed.data);
|
||||
switch_to_section (darwin_sections[objc_image_info_section]);
|
||||
|
||||
ASM_OUTPUT_ALIGN (asm_out_file, 2);
|
||||
fputs ("L_OBJC_ImageInfo:\n", asm_out_file);
|
||||
|
Loading…
x
Reference in New Issue
Block a user