[Bug bootstrap/70422] [6 regression] Bootstrap comparison failure

wilson at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon Mar 28 02:36:00 GMT 2016


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70422

Jim Wilson <wilson at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |wilson at gcc dot gnu.org

--- Comment #3 from Jim Wilson <wilson at gcc dot gnu.org> ---
I can reproduce on armhf and aarch64, but not on x86_64.

stage2 is built with -g -gtoggle.  stage3 is built with -g.  Debug info is
stripped before the compare, so in theory that shouldn't matter.

I am looking at statistics.c, as it is a conveniently small file.  On aarch64,
in stage2 statistics.s, I see
        .section       
.rodata._ZN10hash_tableI20stats_counter_hasher11xcallocatorE6expandEv.str1.8,"aMS",@progbits,1
        .align  3
.LC17:
        .string "alloc_entries"

In stage3 statistics.s I see
        .section        .rodata.str1.8,"aMS",@progbits,1
        .align  3
        ...
        .LC17:
        .string "alloc_entries"
        .zero   2
        ...
        .section        .debug_str,"MS",@progbits,1
        ...
.LASF1861:
        .string "alloc_entries"

So something about debug info caused the string to move from the function
specific rodata section to the general rodata section, and that causes the
comparison failure.  On x86_64, the string is in the function specific rodata
section in both cases, so no comparison failure.


More information about the Gcc-bugs mailing list