[gcc(refs/users/marxin/heads/casm-state-v2)] Clean up.
Martin Liska
marxin@gcc.gnu.org
Fri Sep 10 09:29:32 GMT 2021
https://gcc.gnu.org/g:2e838ce120a629e52f3a2a0fd3024423350207ca
commit 2e838ce120a629e52f3a2a0fd3024423350207ca
Author: Martin Liska <mliska@suse.cz>
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<section>
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);
More information about the Gcc-cvs
mailing list