summaryrefslogtreecommitdiff
path: root/gcc/rtl.h
diff options
context:
space:
mode:
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2000-11-14 17:37:19 +0000
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2000-11-14 17:37:19 +0000
commitabf74c5b070a30ccb6f884472e9aacb47c420dda (patch)
treeb5c71843b63df50a1d55b0f1bf1e75e0c89fa1d2 /gcc/rtl.h
parent59201b02cd18cb878f380ae05815fde4eba01d1d (diff)
downloadgcc-abf74c5b070a30ccb6f884472e9aacb47c420dda.tar.gz
* varasm.c (struct deferred_string): New structure.
(const_str_htab): New variable. (STRHASH): New macro. (mark_const_str_htab_1, mark_const_str_htab, const_str_htab_hash, constr_str_htab_eq, const_str_htab_del): New functions. (output_constant_def): Add DEFER argument, defer string constants until mark_constant_pool time if requested. (mark_constant_pool): Walk the insn chain even if const_str_htab is not empty. (mark_constants): If a SYMBOL_REF for deferred string is found, output it and remove from hash table. (output_addressed_constants): Set DEFER to 0 in call to output_constant_def. * rtl.h (STRING_POOL_ADDRESS_P): Define. (output_constant_def): Adjust prototype. * expr.c (expand_expr): Set DEFER to 1 in call to output_constant_def. * gcc.c-torture/execute/20000801-4.c: Make sure the second string is output. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@37459 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/rtl.h')
-rw-r--r--gcc/rtl.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/gcc/rtl.h b/gcc/rtl.h
index b25c8abee80..762226cd3d4 100644
--- a/gcc/rtl.h
+++ b/gcc/rtl.h
@@ -168,7 +168,9 @@ typedef struct rtx_def
either changing how we compute the frame address or saving and
restoring registers in the prologue and epilogue.
1 in a MEM if the MEM refers to a scalar, rather than a member of
- an aggregate. */
+ an aggregate.
+ 1 in a SYMBOL_REF if it addresses something in the per-function
+ constant string pool. */
unsigned frame_related : 1;
/* The first element of the operands of this rtx.
@@ -904,6 +906,9 @@ extern const char * const note_insn_name[NOTE_INSN_MAX - NOTE_INSN_BIAS];
/* 1 in a SYMBOL_REF if it addresses this function's constants pool. */
#define CONSTANT_POOL_ADDRESS_P(RTX) ((RTX)->unchanging)
+/* 1 in a SYMBOL_REF if it addresses this function's string constant pool. */
+#define STRING_POOL_ADDRESS_P(RTX) ((RTX)->frame_related)
+
/* Flag in a SYMBOL_REF for machine-specific purposes. */
#define SYMBOL_REF_FLAG(RTX) ((RTX)->volatil)
@@ -1587,7 +1592,7 @@ extern rtx gen_rtx_MEM PARAMS ((enum machine_mode, rtx));
extern rtx find_next_ref PARAMS ((rtx, rtx));
extern rtx *find_single_use PARAMS ((rtx, rtx, rtx *));
-extern rtx output_constant_def PARAMS ((union tree_node *));
+extern rtx output_constant_def PARAMS ((union tree_node *, int));
extern rtx immed_real_const PARAMS ((union tree_node *));
extern union tree_node *make_tree PARAMS ((union tree_node *, rtx));