public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libgomp/37938]  New: libgomp testsuite failures on ia64-linux
@ 2008-10-28 14:41 jakub at gcc dot gnu dot org
  2008-10-28 15:04 ` [Bug libgomp/37938] " jakub at gcc dot gnu dot org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-10-28 14:41 UTC (permalink / raw)
  To: gcc-bugs

In one bootstrap/regtest on 16way Itanium 2 I saw
FAIL: libgomp.c/atomic-4.c execution test
FAIL: libgomp.c/nqueens-1.c execution test
FAIL: libgomp.c/pr29947-1.c execution test
FAIL: libgomp.c/sort-1.c execution test
FAIL: libgomp.c++/task-3.C  -O3 -fomit-frame-pointer  execution test
FAIL: libgomp.c++/task-3.C  -O3 -fomit-frame-pointer -funroll-all-loops
-finline-functions  execution test
FAIL: libgomp.c++/task-5.C  -O1  execution test
FAIL: libgomp.c++/task-5.C  -O3 -g  execution test
in another one:
FAIL: libgomp.c/nqueens-1.c execution test
FAIL: libgomp.c/sort-1.c execution test
FAIL: libgomp.c++/collapse-2.C  -O2  execution test
FAIL: libgomp.c++/task-3.C  -Os  execution test
WARNING: program timed out.
FAIL: libgomp.c++/task-5.C  -O1  execution test
WARNING: program timed out.
FAIL: libgomp.c++/task-5.C  -O2  execution test

Trying atomic-4.c by hand, I see it aborts most of the time and even:
extern void abort (void);

int
main (void)
{
  int d = 0;
  int i;

#pragma omp parallel for shared (d)
    for (i = 0; i < 100000; i++)
      {
        GOMP_atomic_start ();
d = d + 1;
        GOMP_atomic_end ();
      }
  if (d != 100000)
    {
      __builtin_printf ("d is %d\n", d);
      return 1;
    }
  return 0;
}
fails quite often (with OMP_NUM_THREADS=16 very soon, 50% in the first
invocation, with e.g. OMP_NUM_THREADS=4 less often, but still within first 40
invocations).  When it fails (both for original atomic-4.c and this testcase) d
is (slightly) smaller than it should be (say 1 through 10 smaller than
expected), but the test never hangs.  If just __sync builtin is used instead of
GOMP_atomic_{start,end} pair (e.g. when double instead of long double is used
in atomic-4.c, or int), then I couldn't reproduce any failures.  This happens
both with trunk libgomp and 4.1.2-RH system libgomp.  I wonder if we need a
barrier somewhere in ia64 specific code or something.

GOMP_atomic_start just uses gomp_mutex_lock (&atomic_lock); and GOMP_atomic_end
gomp_mutex_unlock (&atomic_lock);.  I haven't seen similar problems on other
arches, so I'm afraid this is ia64 specific.


-- 
           Summary: libgomp testsuite failures on ia64-linux
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Keywords: openmp
          Severity: normal
          Priority: P3
         Component: libgomp
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: jakub at gcc dot gnu dot org
GCC target triplet: ia64-linux


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37938


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libgomp/37938] libgomp testsuite failures on ia64-linux
  2008-10-28 14:41 [Bug libgomp/37938] New: libgomp testsuite failures on ia64-linux jakub at gcc dot gnu dot org
@ 2008-10-28 15:04 ` jakub at gcc dot gnu dot org
  2008-10-31 20:05 ` sje at cup dot hp dot com
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-10-28 15:04 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from jakub at gcc dot gnu dot org  2008-10-28 15:02 -------
BTW, using + reduction in the same loop (and with asm optimization barrier for
that variable) I see the reduction computed value always correct, so the loop
body is executed the correct number of times.  That means in some cases the
memory reads/writes between GOMP_atomic_{start,end} must overlap between
threads.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37938


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libgomp/37938] libgomp testsuite failures on ia64-linux
  2008-10-28 14:41 [Bug libgomp/37938] New: libgomp testsuite failures on ia64-linux jakub at gcc dot gnu dot org
  2008-10-28 15:04 ` [Bug libgomp/37938] " jakub at gcc dot gnu dot org
@ 2008-10-31 20:05 ` sje at cup dot hp dot com
  2008-10-31 20:16 ` jakub at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: sje at cup dot hp dot com @ 2008-10-31 20:05 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from sje at cup dot hp dot com  2008-10-31 20:03 -------
It looks like it is Linux specific in addition to being IA64 specific.  I can
make the included test case fail on my Debian Linux box but not on my HP-UX
box.  If I do not optimize (-O0) then it fails more often then if I do optimize
(-O2).


-- 

sje at cup dot hp dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |sje at cup dot hp dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37938


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libgomp/37938] libgomp testsuite failures on ia64-linux
  2008-10-28 14:41 [Bug libgomp/37938] New: libgomp testsuite failures on ia64-linux jakub at gcc dot gnu dot org
  2008-10-28 15:04 ` [Bug libgomp/37938] " jakub at gcc dot gnu dot org
  2008-10-31 20:05 ` sje at cup dot hp dot com
@ 2008-10-31 20:16 ` jakub at gcc dot gnu dot org
  2008-10-31 23:31 ` hjl dot tools at gmail dot com
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-10-31 20:16 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from jakub at gcc dot gnu dot org  2008-10-31 20:15 -------
Linux specific because for non-Linux it uses libpthread pthread_mutex_lock etc.
to do the locking, only on Linux (--enable-linux-futex) it uses __sync_*
builtins for mutex.h locking.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37938


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libgomp/37938] libgomp testsuite failures on ia64-linux
  2008-10-28 14:41 [Bug libgomp/37938] New: libgomp testsuite failures on ia64-linux jakub at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2008-10-31 20:16 ` jakub at gcc dot gnu dot org
@ 2008-10-31 23:31 ` hjl dot tools at gmail dot com
  2008-11-04 16:55 ` sje at cup dot hp dot com
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: hjl dot tools at gmail dot com @ 2008-10-31 23:31 UTC (permalink / raw)
  To: gcc-bugs



-- 

hjl dot tools at gmail dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hjl dot tools at gmail dot
                   |                            |com
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2008-10-31 23:30:14
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37938


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libgomp/37938] libgomp testsuite failures on ia64-linux
  2008-10-28 14:41 [Bug libgomp/37938] New: libgomp testsuite failures on ia64-linux jakub at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2008-10-31 23:31 ` hjl dot tools at gmail dot com
@ 2008-11-04 16:55 ` sje at cup dot hp dot com
  2008-11-13 21:09 ` sje at gcc dot gnu dot org
  2008-11-13 21:14 ` jakub at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: sje at cup dot hp dot com @ 2008-11-04 16:55 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from sje at cup dot hp dot com  2008-11-04 16:54 -------
I have submitted a patch at

http://gcc.gnu.org/ml/gcc-patches/2008-11/msg00125.html

and will check it in tomorrow.  It should fix all the libgomp failures on IA64
Linux.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37938


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libgomp/37938] libgomp testsuite failures on ia64-linux
  2008-10-28 14:41 [Bug libgomp/37938] New: libgomp testsuite failures on ia64-linux jakub at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2008-11-04 16:55 ` sje at cup dot hp dot com
@ 2008-11-13 21:09 ` sje at gcc dot gnu dot org
  2008-11-13 21:14 ` jakub at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: sje at gcc dot gnu dot org @ 2008-11-13 21:09 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from sje at gcc dot gnu dot org  2008-11-13 21:08 -------
Subject: Bug 37938

Author: sje
Date: Thu Nov 13 21:06:38 2008
New Revision: 141830

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=141830
Log:
        PR libgomp/37938
        * config/linux/ia64/mutex.h: New.

Added:
    trunk/libgomp/config/linux/ia64/mutex.h
Modified:
    trunk/libgomp/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37938


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libgomp/37938] libgomp testsuite failures on ia64-linux
  2008-10-28 14:41 [Bug libgomp/37938] New: libgomp testsuite failures on ia64-linux jakub at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2008-11-13 21:09 ` sje at gcc dot gnu dot org
@ 2008-11-13 21:14 ` jakub at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-11-13 21:14 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from jakub at gcc dot gnu dot org  2008-11-13 21:12 -------
Fixed.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37938


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2008-11-13 21:14 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-10-28 14:41 [Bug libgomp/37938] New: libgomp testsuite failures on ia64-linux jakub at gcc dot gnu dot org
2008-10-28 15:04 ` [Bug libgomp/37938] " jakub at gcc dot gnu dot org
2008-10-31 20:05 ` sje at cup dot hp dot com
2008-10-31 20:16 ` jakub at gcc dot gnu dot org
2008-10-31 23:31 ` hjl dot tools at gmail dot com
2008-11-04 16:55 ` sje at cup dot hp dot com
2008-11-13 21:09 ` sje at gcc dot gnu dot org
2008-11-13 21:14 ` jakub at gcc dot gnu dot org

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).