From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8098 invoked by alias); 4 Dec 2013 00:48:34 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 8073 invoked by uid 48); 4 Dec 2013 00:48:31 -0000 From: "hjl.tools at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/59379] gomp_init_num_threads is compiled into an infinite loop with --with-arch=corei7 --with-cpu=slm Date: Wed, 04 Dec 2013 00:48:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: hjl.tools at gmail dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_status cf_reconfirmed_on everconfirmed Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-12/txt/msg00244.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59379 H.J. Lu changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2013-12-04 Ever confirmed|0 |1 --- Comment #5 from H.J. Lu --- The difference starts in ivopts pass: diff -upr good/test.c.120t.ivopts bad/test.c.120t.ivopts --- good/test.c.120t.ivopts 2013-12-03 16:46:21.995210047 -0800 +++ bad/test.c.120t.ivopts 2013-12-03 16:46:34.847986232 -0800 @@ -13,6 +13,7 @@ gomp_init_num_threads () long unsigned int _13; long unsigned int gomp_cpuset_size.2_14; void * gomp_cpusetp.3_17; + long unsigned int _19; long unsigned int gomp_cpuset_size.1_20; int _22; long unsigned int gomp_cpuset_size.1_25; @@ -39,6 +40,7 @@ gomp_init_num_threads () struct cpu_set_t * prephitmp_89; struct cpu_set_t * prephitmp_90; long unsigned int pretmp_91; + long unsigned int _92; long unsigned int pretmp_93; long unsigned int pretmp_95; long unsigned int prephitmp_96; @@ -93,7 +95,9 @@ gomp_init_num_threads () : # i_76 = PHI i_48 = i_76 + 18446744073709551615; - if (i_47 > i_48) + _92 = i_47 * 18446744069414584320; + i_94 = i_48 + _92; + if (i_47 > i_94) goto ; else goto ; @@ -118,7 +122,9 @@ gomp_init_num_threads () goto ; : - if (i_48 != 0) + _19 = i_47 * 18446744069414584320; + i_69 = _19 + i_48; + if (i_69 != 0) goto ; else goto ;