This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 1/6] Convert gimple types from a union to C++ inheritance
- From: Jeff Law <law at redhat dot com>
- To: David Malcolm <dmalcolm at redhat dot com>, gcc-patches at gcc dot gnu dot org, Andrew MacLeod <amacleod at redhat dot com>
- Date: Thu, 14 Nov 2013 14:51:19 -0700
- Subject: Re: [PATCH 1/6] Convert gimple types from a union to C++ inheritance
- Authentication-results: sourceware.org; auth=none
- References: <5271CBF9 dot 2070005 at redhat dot com> <1383236801-13234-1-git-send-email-dmalcolm at redhat dot com> <1383236801-13234-2-git-send-email-dmalcolm at redhat dot com>
On 10/31/13 10:26, David Malcolm wrote:
* Makefile.in (GIMPLE_H): Add dep on is-a.h.
Not asking you, but I'd like to hope many of the *_H things in
Makefile.in should be going away...
diff --git a/gcc/Makefile.in b/gcc/Makefile.in
index cc88fb8..7fbb533 100644
--- a/gcc/Makefile.in
+++ b/gcc/Makefile.in
@@ -887,7 +887,7 @@ BASIC_BLOCK_H = basic-block.h $(PREDICT_H) $(VEC_H) $(FUNCTION_H) \
cfg-flags.def cfghooks.h
GIMPLE_H = gimple.h gimple.def gsstruct.def pointer-set.h $(VEC_H) \
$(GGC_H) $(BASIC_BLOCK_H) $(TREE_H) tree-ssa-operands.h \
- tree-ssa-alias.h $(INTERNAL_FN_H) $(HASH_TABLE_H)
+ tree-ssa-alias.h $(INTERNAL_FN_H) $(HASH_TABLE_H) is-a.h
GCOV_IO_H = gcov-io.h gcov-iov.h auto-host.h
RECOG_H = recog.h
EMIT_RTL_H = emit-rtl.h
Ugh. OK I guess. I hate all these _H thingies. Ideally they'll go
away at some point. I think their biggest use now is for
PLUGIN_HEADERS. But that's not an issue for this patch to go forward.
diff --git a/gcc/ggc.h b/gcc/ggc.h
index b31bc80..bb8f939 100644
--- a/gcc/ggc.h
+++ b/gcc/ggc.h
@@ -269,10 +269,10 @@ ggc_alloc_cleared_tree_node_stat (size_t s MEM_STAT_DECL)
return (union tree_node *) ggc_internal_cleared_alloc_stat (s PASS_MEM_STAT);
}
-static inline union gimple_statement_d *
-ggc_alloc_cleared_gimple_statement_d_stat (size_t s MEM_STAT_DECL)
+static inline struct gimple_statement_base *
+ggc_alloc_cleared_gimple_statement_stat (size_t s MEM_STAT_DECL)
{
- return (union gimple_statement_d *)
+ return (struct gimple_statement_base *)
ggc_internal_cleared_alloc_stat (s PASS_MEM_STAT);
}
Didn't I see something in the last 48hrs indicating that we don't need
"static inline" anymore, just "inline"? If so, can you drop the static
here since you're changing it already.
With that, this, IMO is OK and a definite step forward.
Given the contention over this, please give other maintainers 24hrs to
object before installing the set.
jeff