aboutsummaryrefslogtreecommitdiff
path: root/gcc/java/constants.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/java/constants.c')
-rw-r--r--gcc/java/constants.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/gcc/java/constants.c b/gcc/java/constants.c
index c51cec9..e3642d5 100644
--- a/gcc/java/constants.c
+++ b/gcc/java/constants.c
@@ -326,20 +326,12 @@ write_constant_pool (cpool, buffer, length)
CPool *outgoing_cpool;
+static GTY(()) tree tag_nodes[13];
static tree
get_tag_node (tag)
int tag;
{
/* A Cache for build_int_2 (CONSTANT_XXX, 0). */
- static tree tag_nodes[13];
- static int initialized_p;
-
- /* Register the TAG_NODES with the garbage collector. */
- if (!initialized_p)
- {
- ggc_add_tree_root (tag_nodes, 13);
- initialized_p = 1;
- }
if (tag_nodes[tag] == NULL_TREE)
tag_nodes[tag] = build_int_2 (tag, 0);
@@ -492,3 +484,5 @@ build_constants_constructor ()
FINISH_RECORD_CONSTRUCTOR (cons);
return cons;
}
+
+#include "gt-java-constants.h"