public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libgomp/58462] New: gomp4: invalid controlling predicate for != (< is ok)
@ 2013-09-18 13:16 vincenzo.innocente at cern dot ch
2013-09-18 15:07 ` [Bug libgomp/58462] " vincenzo.innocente at cern dot ch
0 siblings, 1 reply; 2+ messages in thread
From: vincenzo.innocente at cern dot ch @ 2013-09-18 13:16 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58462
Bug ID: 58462
Summary: gomp4: invalid controlling predicate for != (< is ok)
Product: gcc
Version: 4.9.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libgomp
Assignee: unassigned at gcc dot gnu.org
Reporter: vincenzo.innocente at cern dot ch
CC: jakub at gcc dot gnu.org
took me years to learn and teach to use != instead of "<"….
float a[1024];
float b[1024];
void err() {
#pragma omp simd
for (int i=0;i!=1024;++i) {
a[i]=b[i];
}
}
void ok() {
#pragma omp simd
for (int i=0;i<1024;++i) {
a[i]=b[i];
}
}
c++ -std=c++11 -O2 -march=core-avx2 -S twoif.cc -fopenmp
twoif.cc: In function ‘void err()’:
twoif.cc:7:3: error: invalid controlling predicate
for (int i=0;i!=1024;++i) {
^
pb-d-128-141-131-26:vectorize innocent$ c++ -v
Using built-in specs.
COLLECT_GCC=c++
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-apple-darwin12.4.0/4.9.0/lto-wrapper
Target: x86_64-apple-darwin12.4.0
Configured with: ./configure --disable-multilib --disable-bootstrap
--enable-lto -disable-libitm --enable-languages=c,c++,fortran,lto
--disable-libsanitizer
Thread model: posix
gcc version 4.9.0 20130918 (experimental) (GCC)
>From gcc-bugs-return-430109-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Sep 18 13:21:22 2013
Return-Path: <gcc-bugs-return-430109-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 24153 invoked by alias); 18 Sep 2013 13:21:22 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 24120 invoked by uid 48); 18 Sep 2013 13:21:20 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgomp/58462] gomp4: invalid controlling predicate for != (< is ok)
Date: Wed, 18 Sep 2013 13:21:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgomp
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
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 resolution
Message-ID: <bug-58462-4-BtgvEk3qJw@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-58462-4@http.gcc.gnu.org/bugzilla/>
References: <bug-58462-4@http.gcc.gnu.org/bugzilla/>
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-09/txt/msg01349.txt.bz2
Content-length: 509
http://gcc.gnu.org/bugzilla/show_bug.cgi?idX462
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution|--- |INVALID
--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
That is invalid.
See OpenMP 4.0, section 2.6.
!= is valid only in Cilk+ (i.e. #pragma simd).
^ permalink raw reply [flat|nested] 2+ messages in thread
* [Bug libgomp/58462] gomp4: invalid controlling predicate for != (< is ok)
2013-09-18 13:16 [Bug libgomp/58462] New: gomp4: invalid controlling predicate for != (< is ok) vincenzo.innocente at cern dot ch
@ 2013-09-18 15:07 ` vincenzo.innocente at cern dot ch
0 siblings, 0 replies; 2+ messages in thread
From: vincenzo.innocente at cern dot ch @ 2013-09-18 15:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58462
--- Comment #2 from vincenzo Innocente <vincenzo.innocente at cern dot ch> ---
Thanks Jakub.
Downloaded the standard.
waiting for more examples of usage
It is a pity that it does not support c++ range loop
Let me highjack this bug to congratulate you and your collaborators for the
great and fast work to implement openmp 4.0 simd syntax.
I already found out that at the moment is the only way to convince gcc that a
pointer is "restrict"!
I hope it will go in main-stream 4.9 soon.
Vincenzo
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-09-18 15:07 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-18 13:16 [Bug libgomp/58462] New: gomp4: invalid controlling predicate for != (< is ok) vincenzo.innocente at cern dot ch
2013-09-18 15:07 ` [Bug libgomp/58462] " vincenzo.innocente at cern dot ch
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).