From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1851) id 68B1F3857C6F; Tue, 14 Sep 2021 12:35:54 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 68B1F3857C6F Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Martin Liska To: gcc-cvs@gcc.gnu.org Subject: [gcc(refs/users/marxin/heads/casm-state-v3)] Clean up. X-Act-Checkin: gcc X-Git-Author: Martin Liska X-Git-Refname: refs/users/marxin/heads/casm-state-v3 X-Git-Oldrev: 266aac9cf2a3e02320f230dc0c57f6cefd74d51b X-Git-Newrev: f437cedde73b0b476c34c173fefb540a4ac22ae6 Message-Id: <20210914123554.68B1F3857C6F@sourceware.org> Date: Tue, 14 Sep 2021 12:35:54 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Sep 2021 12:35:54 -0000 https://gcc.gnu.org/g:f437cedde73b0b476c34c173fefb540a4ac22ae6 commit f437cedde73b0b476c34c173fefb540a4ac22ae6 Author: Martin Liska Date: Thu Sep 9 13:55:50 2021 +0200 Clean up. Diff: --- gcc/langhooks.c | 2 +- gcc/output.h | 2 ++ gcc/targhooks.c | 2 +- gcc/varasm.c | 18 +++++++++--------- 4 files changed, 13 insertions(+), 11 deletions(-) diff --git a/gcc/langhooks.c b/gcc/langhooks.c index b2c5ccb3b5e..a25a4f84eba 100644 --- a/gcc/langhooks.c +++ b/gcc/langhooks.c @@ -803,7 +803,7 @@ lhd_begin_section (const char *name) /* Save the old section so we can restore it in lto_end_asm_section. */ gcc_assert (!saved_section); - saved_section = casm->casm->in_section; + saved_section = casm->in_section; if (!saved_section) saved_section = casm->sections.text; diff --git a/gcc/output.h b/gcc/output.h index 37764208ec2..3fdc559fec5 100644 --- a/gcc/output.h +++ b/gcc/output.h @@ -321,6 +321,8 @@ struct section_hasher : ggc_ptr_hash
static bool equal (section *, const char *); }; +/* Assembly output state. */ + struct GTY(()) asm_out_state { asm_out_state (): out_file (NULL), in_section (NULL), diff --git a/gcc/targhooks.c b/gcc/targhooks.c index c10dc877a80..68660186ec5 100644 --- a/gcc/targhooks.c +++ b/gcc/targhooks.c @@ -1962,7 +1962,7 @@ default_print_patchable_function_entry_1 (FILE *file, { char buf[256]; static int patch_area_number; - section *previous_section = casm->casm->in_section; + section *previous_section = casm->in_section; const char *asm_op = integer_asm_op (POINTER_SIZE_UNITS, false); gcc_assert (asm_op != NULL); diff --git a/gcc/varasm.c b/gcc/varasm.c index 0c776d477e1..61064df9dc8 100644 --- a/gcc/varasm.c +++ b/gcc/varasm.c @@ -1969,7 +1969,7 @@ assemble_end_function (tree decl, const char *fnname ATTRIBUTE_UNUSED) { section *save_text_section; - save_text_section = casm->casm->in_section; + save_text_section = casm->in_section; switch_to_section (unlikely_text_section ()); #ifdef ASM_DECLARE_COLD_FUNCTION_SIZE if (cold_function_name != NULL_TREE) @@ -1999,7 +1999,7 @@ assemble_zeros (unsigned HOST_WIDE_INT size) #ifdef ASM_NO_SKIP_IN_TEXT /* The `space' pseudo in the text section outputs nop insns rather than 0s, so we must output 0s explicitly in the text section. */ - if (ASM_NO_SKIP_IN_TEXT && (casm->casm->in_section->common.flags & SECTION_CODE) != 0) + if (ASM_NO_SKIP_IN_TEXT && (casm->in_section->common.flags & SECTION_CODE) != 0) { unsigned HOST_WIDE_INT i; for (i = 0; i < size; i++) @@ -4141,8 +4141,8 @@ output_constant_pool_1 (class constant_descriptor_rtx *desc, /* Make sure all constants in SECTION_MERGE and not SECTION_STRINGS sections have proper size. */ if (align > GET_MODE_BITSIZE (desc->mode) - && casm->casm->in_section - && (casm->casm->in_section->common.flags & SECTION_MERGE)) + && casm->in_section + && (casm->in_section->common.flags & SECTION_MERGE)) assemble_align (align); #ifdef ASM_OUTPUT_SPECIAL_POOL_ENTRY @@ -7766,13 +7766,13 @@ switch_to_section (section *new_section, tree decl) "%qD was declared here", used_decl); } } - else if (casm->casm->in_section == new_section) + else if (casm->in_section == new_section) return; if (new_section->common.flags & SECTION_FORGET) - casm->casm->in_section = NULL; + casm->in_section = NULL; else - casm->casm->in_section = new_section; + casm->in_section = new_section; switch (SECTION_STYLE (new_section)) { @@ -8417,7 +8417,7 @@ handle_vtv_comdat_section (section *sect, const_tree decl ATTRIBUTE_UNUSED) sect->named.common.flags | SECTION_LINKONCE, DECL_NAME (decl)); - casm->casm->in_section = sect; + casm->in_section = sect; #else /* Neither OBJECT_FORMAT_PE, nor OBJECT_FORMAT_COFF is set here. Therefore the following check is used. @@ -8443,7 +8443,7 @@ handle_vtv_comdat_section (section *sect, const_tree decl ATTRIBUTE_UNUSED) sect->named.common.flags | SECTION_LINKONCE, DECL_NAME (decl)); - casm->casm->in_section = sect; + casm->in_section = sect; } else switch_to_section (sect);