[Bug rtl-optimization/85862] New: infinite loop in find_base_term()

matthew.weber at rockwellcollins dot com gcc-bugzilla@gcc.gnu.org
Mon May 21 18:48:00 GMT 2018


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

            Bug ID: 85862
           Summary: infinite loop in find_base_term()
           Product: gcc
           Version: 6.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: rtl-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: matthew.weber at rockwellcollins dot com
  Target Milestone: ---

Posted a comment on this
(https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85180#c20)  bug as the patch
proposed their resolved this issue as well.

libnss 3.35 fails to build on the microblaze arch (uclibc) with any of the 6.x
series and this patch resolves that
(https://github.com/gcc-mirror/gcc/commit/df03ebc3574a0d7893127e3b9754a01abf2d8b70). 

microblazeel-buildroot-linux-uclibc-gcc -o
Linux2.6_microblazeel_microblazeel-buildroot-linux-uclibc-gcc.br_real_glibc_PTH_OPT.OBJ/sslgrp.o
-c -O2 -fPIC   -pipe -ffunction-sections -fdata-sections -DHAVE_STRERROR
-DLINUX -Dlinux -Wall -Werror -DXP_UNIX -UDEBUG -DNDEBUG -D_REENTRANT
-DNSS_NO_INIT_SUPPORT -DUSE_UTIL_DIRECTLY -DNO_NSPR_10_SUPPORT
-DSSL_DISABLE_DEPRECATED_CIPHER_SUITE_NAMES -Isysroot/usr/include/nspr
-Ilibnss-3.35/dist/include -I../../../dist/public/nss
-I../../../dist/private/nss  sslgrp.c
(Buildroot failure link:
http://autobuild.buildroot.net/results/158e8ebb39713e1b436a5cc1a1916f46c30694df)

However the libnss build works fine with the 7.x branch and master.  I've been
bisecting all 3 branches for a few days and figured I should just try that
patch before debugging the 6.x branch further.  I even went back and tried to
find common ancestors between the 6.x and 7.x and couldn't get a point where
the good/bad builds matched up.  Guessing backports on 6.x from master
introduced the libnss bug variant, as the gcc/cse* and gcc/alias.x files had a
lot of updates from 5.x to 7.x.

Here's the stack trace on cc1 when its hung building a libnss sslgrp.c
file.......
( A lot more find_base_terms() before this one)
#71 0x00000000005ae67d in find_base_term(rtx_def*) ()
#72 0x00000000005ae532 in find_base_term(rtx_def*) ()
#73 0x00000000005ae67d in find_base_term(rtx_def*) ()
#74 0x00000000005ae532 in find_base_term(rtx_def*) ()
#75 0x00000000005ae67d in find_base_term(rtx_def*) ()
#76 0x00000000005ae568 in find_base_term(rtx_def*) ()
#77 0x00000000005b137d in write_dependence_p(rtx_def const*, rtx_def const*,
machine_mode, rtx_def*, bool, bool, bool) ()
#78 0x00000000005b1585 in canon_anti_dependence(rtx_def const*, bool, rtx_def
const*, machine_mode, rtx_def*) ()
#79 0x000000000061c5e3 in cselib_invalidate_mem(rtx_def*) ()
#80 0x000000000061d32d in cselib_record_sets(rtx_insn*) ()
#81 0x000000000061e5c8 in cselib_process_insn(rtx_insn*) ()
#82 0x00000000008774b8 in reload_cse_regs_1() ()
#83 0x00000000008777dc in (anonymous
namespace)::pass_postreload_cse::execute(function*) ()
#84 0x000000000086714d in execute_one_pass(opt_pass*) ()


More information about the Gcc-bugs mailing list