This is the mail archive of the 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]

Re: Turn DECL_SECTION_NAME into string


On Thu, 12 Jun 2014 06:33:25 +0200, Jan Hubicka <> wrote:
> this lenghtly patch makes the legwork to put section names out of tree representation.
> Originally they were STRING_CST. I ended up implementing on-side reference counted
> string voclabulary that is done in bit baroque way to be GGC and PCH safe (uff).

As reported in <>, this causes a build failure
with --enable-checking=fold:

    /home/dimhen/src/gcc_current/gcc/fold-const.c: In function 'void fold_checksum_tree(const_tree, md5_ctx*, hash_table<pointer_hash<tree_node>)':
    /home/dimhen/src/gcc_current/gcc/fold-const.c:14863:55: error: cannot convert 'const char*' to 'const_tree {aka const tree_node*}' for argument '1' to 'void fold_checksum_tree(const_tree, md5_ctx*, hash_table<pointer_hash<tree_node> >)'
      fold_checksum_tree (DECL_SECTION_NAME (expr), ctx, ht);

From light testing the following seems to get around this -- is it the
appropriate fix?

diff --git gcc/fold-const.c gcc/fold-const.c
index 24daaa3..978b854 100644
--- gcc/fold-const.c
+++ gcc/fold-const.c
@@ -14859,8 +14859,6 @@ fold_checksum_tree (const_tree expr, struct md5_ctx *ctx,
 	  fold_checksum_tree (DECL_ABSTRACT_ORIGIN (expr), ctx, ht);
 	  fold_checksum_tree (DECL_ATTRIBUTES (expr), ctx, ht);
-	fold_checksum_tree (DECL_SECTION_NAME (expr), ctx, ht);


Attachment: pgpRptaXVvupr.pgp
Description: PGP signature

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]