This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
The attached patch makes it safe to include basic-block.h and tree-flow.h from C++. Something similar will be necessary in order to LLVM to able to access the basic block info. bootstraped on a GNU/Linux/x86 Rafael gcc/ChangeLog: tree-flow.h: (edge_prediction): use struct edge_def * instead of edge varray.h: (varray_data_tag): use struct rtx_def * instead of rtx use struct rtvec_def * instead of rtvec use union tree_node * instead of tree
Index: gcc/tree-flow.h =================================================================== --- gcc/tree-flow.h (revision 108280) +++ gcc/tree-flow.h (working copy) @@ -336,7 +336,7 @@ static inline tree default_def (tree); struct edge_prediction GTY((chain_next ("%h.next"))) { struct edge_prediction *next; - edge edge; + struct edge_def *edge; enum br_predictor predictor; int probability; }; Index: gcc/varray.h =================================================================== --- gcc/varray.h (revision 108280) +++ gcc/varray.h (working copy) @@ -90,11 +90,11 @@ typedef union varray_data_tag GTY (()) { tag ("VARRAY_DATA_GENERIC_NOGC"))) generic_nogc[1]; char *GTY ((length ("%0.num_elements"), tag ("VARRAY_DATA_CPTR"))) cptr[1]; - rtx GTY ((length ("%0.num_elements"), + struct rtx_def *GTY ((length ("%0.num_elements"), tag ("VARRAY_DATA_RTX"))) rtx[1]; - rtvec GTY ((length ("%0.num_elements"), + struct rtvec_def *GTY ((length ("%0.num_elements"), tag ("VARRAY_DATA_RTVEC"))) rtvec[1]; - tree GTY ((length ("%0.num_elements"), + union tree_node *GTY ((length ("%0.num_elements"), tag ("VARRAY_DATA_TREE"))) tree[1]; struct bitmap_head_def *GTY ((length ("%0.num_elements"), tag ("VARRAY_DATA_BITMAP"))) bitmap[1]; @@ -106,7 +106,7 @@ typedef union varray_data_tag GTY (()) { tag ("VARRAY_DATA_TE"))) te[1]; struct edge_def *GTY ((length ("%0.num_elements"), tag ("VARRAY_DATA_EDGE"))) e[1]; - tree *GTY ((length ("%0.num_elements"), skip (""), + union tree_node *GTY ((length ("%0.num_elements"), skip (""), tag ("VARRAY_DATA_TREE_PTR"))) tp[1]; } varray_data;
Attachment:
pgp00000.pgp
Description: PGP signature
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |