OSDN Git Service

* tree-scalar-evolution.c (compute_overall_effect_of_inner_loop,
[pf3gnuchains/gcc-fork.git] / libgomp / ChangeLog
1 2006-03-21  Jakub Jelinek  <jakub@redhat.com>
2
3         PR c++/26691
4         * testsuite/libgomp.c++/pr26691.C: New test.
5
6 2006-03-13  Jakub Jelinek  <jakub@redhat.com>
7
8         * testsuite/libgomp.fortran/retval2.f90: New test.
9
10 2006-03-09  Diego Novillo  <dnovillo@redhat.com>
11
12         * testsuite/libgomp.c++: New directory.
13
14 2006-02-25  Shantonu Sen  <ssen@opendarwin.org>
15
16         * config/posix/sem.h: Define BROKEN_POSIX_SEMAPHORES functions.
17         * config/posix/sem.c: Implement the above.
18
19 2006-02-25  Andreas Tobler  <a.tobler@schweiz.ch>
20
21         * configure.ac (HAVE_BROKEN_POSIX_SEMAPHORES): Check for darwin and
22         define HAVE_BROKEN_POSIX_SEMAPHORES.
23         * configure: Rebuilt.
24         * config.h.in: Rebuilt.
25
26 2006-02-17  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
27
28         PR bootstrap/26161
29         * configure.ac: Remove AC_CHECK_HEADER for pthread.h. Add comment
30         for the other pthread check.
31         * configure: Regenerate.
32         * config.h.in: Regenerate.
33
34 2006-02-15  Jakub Jelinek  <jakub@redhat.com>
35
36         PR libgomp/25938
37         PR libgomp/25984
38         * Makefile.am (fincludedir): New variable.
39         (nodist_include_HEADERS): Remove Fortran files.
40         (nodist_finclude_HEADERS): New variable.
41         * Makefile.in: Regenerated.
42
43 2006-02-13  Jakub Jelinek  <jakub@redhat.com>
44
45         * testsuite/libgomp.fortran/vla7.f90: Add -w to options.
46         Remove tests for returning assumed character length arrays.
47
48 2006-02-12  Roger Sayle  <roger@eyesopen.com>
49             John David Anglin  <dave@hiauly1.hia.nrc.ca>
50
51         PR libgomp/25936
52         * configure.tgt: Link against -lrt for sem_init on HPUX v11 systems.
53  
54 2006-02-08  Ulrich Weigand  <uweigand@de.ibm.com>
55
56         * testsuite/lib/libgomp-dg.exp: Load scanrtl.exp library.
57
58 2006-02-07  Eric Botcazou  <ebotcazou@libertysurf.fr>
59
60         * testsuite/lib/libgomp-dg.exp (libgomp_init): Compute multilib related
61         part of LD_LIBRARY_PATH manually.
62
63 2006-02-03  H.J. Lu  <hongjiu.lu@intel.com>
64
65         PR libgomp/25852
66         * testsuite/lib/libgomp-dg.exp (blddir): Set it in
67         libgomp_init.
68
69 2005-01-25  Paolo Bonzini  <bonzini@gnu.org>
70
71         PR libgomp/25884
72         * Makefile.am (omp.h, omp_lib.h, omp_lib.f90, libgomp_f.h): Remove.
73         * configure.ac (PERL): Don't set.
74         (gstdint.h, omp.h, omp_lib.h, omp_lib.f90, libgomp_f.h): Create here.
75         (OMP_LOCK_SIZE, OMP_LOCK_ALIGN, OMP_LOCK_KIND, OMP_NEST_LOCK_SIZE,
76         OMP_NEST_LOCK_ALIGN, OMP_NEST_LOCK_KIND): New substitutions.
77         * omp.h.in: Wrap the new configure substitutions with @ characters.
78         * omp_lib.h.in, omp_lib.f90.in, libgomp_f.h.in: Likewise.
79         * aclocal.m4, configure, Makefile.in: Regenerate.
80         * mkomp_h.pl: Delete.
81
82 2005-01-24  Paolo Bonzini  <bonzini@gnu.org>
83
84         PR libgomp/25259
85         * configure.ac: Use GCC_HEADER_STDINT.
86         * libgomp.h: Include gstdint.h.
87         * libgomp_f.h.in: Don't include stdint.h or inttypes.h.
88         * configure, Makefile.in, testsuite/Makefile.in, aclocal.m4: Rebuild.
89
90 2006-01-24  Richard Henderson  <rth@redhat.com>
91
92         PR libgomp/25942
93         * configure.ac: Add AM_MAINTAINER_MODE.
94         * Makefile.in, aclocal.m4, configure, testsuite/Makefile.in: Rebuild.
95
96 2006-01-24  Diego Novillo  <dnovillo@redhat.com>
97
98         * Makefile.in: Regenerate.
99         * testsuite/Makefile.in: Regenerate.
100         * aclocal.m4: Regenerate.
101
102 2006-01-23  Andreas Tobler  <a.tobler@schweiz.ch>
103
104         * config/posix/proc.c: Conditional include of sys/loadavg.h for
105         Solaris.
106         * configure.ac: Add check for loadavg.h.
107         (link_gomp): Adjust comment.
108         * configure: Regenerate.
109         * config.h.in: Regenerate.
110
111 2006-01-21  Steve Ellcey  <sje@cup.hp.com>
112
113         PR libgomp/25877
114         * configure.ac: Remove check for alloca.h.
115         * configure: Regenerate.
116         * config.h.in: Regenerate.
117         * libgomp.h: define gomp_alloca to be __builtin_alloca.
118         * team.c: Remove use of alloca.h.
119         Call gomp_alloca instead of alloca.
120
121 2006-01-20  Steve Ellcey  <sje@cup.hp.com>
122
123         PR libgomp/25877
124         * team.c: Add include of alloca.h.
125         * configure.ac: Add check for alloca.h.
126         * configure: Regenerate.
127         * config.h.in: Regenerate.
128
129 2006-01-17  Jakub Jelinek  <jakub@redhat.com>
130
131         PR fortran/25219
132         * testsuite/libgomp.fortran/pr25219.f90: New test.
133
134 2005-12-05  Uros Bizjak  <uros@kss-loka.si>
135
136         * testsuite/libgomp.c/pr24455.c, testsuite/libgomp.c/copyin-1.c,
137         testsuite/libgomp.c/copyin-2.c, testsuite/libgomp.c/copyin-3.c,
138         testsuite/libgomp.c++/copyin-1.C, testsuite/libgomp.c++/copyin-2.C,
139         testsuite/libgomp.c++/ctor-5.C, testsuite/libgomp.c++/ctor-8.C,
140         testsuite/libgomp.c++/ctor-9.C, testsuite/libgomp.c++/pr24455.C,
141         testsuite/libgomp.fortran/threadprivate1.f90,
142         testsuite/libgomp.fortran/threadprivate2.f90,
143         testsuite/libgomp.fortran/threadprivate3.f90,
144         testsuite/libgomp.fortran/appendix-a/a.22.7.f9,
145         testsuite/libgomp.fortran/appendix-a/a.22.8.f9,
146         testsuite/libgomp.fortran/omp_parse3.f90: Change required
147         effective-target to TLS runtime.
148
149         * testsuite/libgomp.fortran/pr25162.f: Require
150         effective-target TLS runtime.
151
152 2005-12-01  Jakub Jelinek  <jakub@redhat.com>
153
154         * testsuite/libgomp.fortran/nestedfn2.f90: New test.
155         * testsuite/libgomp.c/nestedfn-3.c: New test.
156
157 2005-11-30  Jakub Jelinek  <jakub@redhat.com>
158
159         PR fortran/25162
160         * testsuite/libgomp.fortran/pr25162.f: New test.
161
162 2005-11-28  Jakub Jelinek  <jakub@redhat.com>
163
164         * config/posix/time.c (omp_get_wtime, omp_get_wtick): Fall back to
165         CLOCK_REALTIME if clock_* (CLOCK_MONOTONIC, &ts) call failed.
166
167 2005-11-25  Jakub Jelinek  <jakub@redhat.com>
168
169         * alloc.c, barrier.c, critical.c, env.c, error.c, fortran.c, iter.c,
170         libgomp.h, libgomp_f.h.in, libgomp_g.h, loop.c, mkomp_h.pl, omp.h.in,
171         omp_lib.f90.in, omp_lib.h.in, ordered.c, parallel.c, sections.c,
172         single.c, team.c, work.c, config/linux/alpha/futex.h,
173         config/linux/bar.c, config/linux/bar.h, config/linux/ia64/futex.h,
174         config/linux/lock.c, config/linux/mutex.c, config/linux/mutex.h,
175         config/linux/powerpc/futex.h, config/linux/s390/futex.h,
176         config/linux/sem.c, config/linux/sem.h, config/linux/sparc/futex.h,
177         config/linux/x86/futex.h, config/posix/bar.c, config/posix/bar.h,
178         config/posix/lock.c, config/posix/mutex.h, config/posix/proc.c,
179         config/posix/sem.c, config/posix/sem.h, config/posix/time.c: Update
180         FSF address.
181
182 2005-11-18  Jakub Jelinek  <jakub@redhat.com>
183
184         * Makefile.am: Move libgomp_f.h from nodist_include_HEADERS
185         to nodist_noinst_HEADERS.
186         * Makefile.in: Rebuilt.
187
188         * config/posix/omp-lock.h (omp_nest_lock_t): Change into struct,
189         add integer count field.
190         * config/posix/lock.c (omp_destroy_nest_lock): Adjust for
191         omp_nest_lock_t type change.
192         (omp_init_nest_lock): Likewise.  Initialize count to 0.
193         (omp_set_nest_lock): Adjust for omp_nest_lock_t type change.
194         Increment count.
195         (omp_unset_nest_lock): Adjust for omp_nest_lock_t type change.
196         Decrement count.
197         (omp_test_nest_lock): Adjust for omp_nest_lock_t type change.
198         Increment count if successful and return the new nesting level.
199         * config/linux/lock.c (omp_test_nest_lock): Return new nesting level.
200         * omp_lib.f90.in (omp_test_lock): Fix LOCK argument type.
201         * testsuite/libgomp.c/lib-1.c: New test.
202         * testsuite/libgomp.fortran/lib1.f90: New test.
203         * testsuite/libgomp.fortran/lib2.f: New test.
204         * testsuite/libgomp.fortran/lib3.f: New test.
205
206 2005-11-17  Richard Henderson  <rth@redhat.com>
207
208         PR 24845
209         * Makefile.am (nodist_toolexeclib_HEADERS): New.
210         * configure.ac (link_gomp): New.  Substitute it.
211         (AC_CONFIG_FILES): Add libgomp.spec.
212         * libgomp.spec.in: New file.
213         * Makefile.in, testsuite/Makefile.in, configure: Rebuild.
214         * testsuite/lib/libgomp-dg.exp: Add -B${blddir}/ to flags.
215
216 2005-11-18  Jakub Jelinek  <jakub@redhat.com>
217
218         * testsuite/libgomp.fortran/reduction1.f90: Adjust for
219         reduction(-:var) behaving the same as reduction(+:var).
220         * testsuite/libgomp.c/reduction-4.c: New test.
221
222 2005-11-15  Uros Bizjak  <uros@kss-loka.si>
223
224         * testsuite/libgomp.c/pr24455-1.c, testsuite/libgomp.c/pr24455.c,
225         testsuite/libgomp.c/copyin-1.c, testsuite/libgomp.c/copyin-2.c,
226         testsuite/libgomp.c/copyin-3.c,
227         testsuite/libgomp.c++/copyin-1.C, testsuite/libgomp.c++/copyin-2.C,
228         testsuite/libgomp.c++/ctor-5.C, testsuite/libgomp.c++/ctor-8.C,
229         testsuite/libgomp.c++/ctor-9.C, testsuite/libgomp.c++/pr24455-1.C,
230         testsuite/libgomp.c++/pr24455.C,
231         testsuite/libgomp.fortran/threadprivate1.f90,
232         testsuite/libgomp.fortran/threadprivate2.f90,
233         testsuite/libgomp.fortran/threadprivate3.f90,
234         testsuite/libgomp.fortran/appendix-a/a.22.7.f9,
235         testsuite/libgomp.fortran/appendix-a/a.22.8.f9,
236         testsuite/libgomp.fortran/omp_parse3.f90: Require
237         effective-target TLS.
238
239 2005-11-14  Diego Novillo  <dnovillo@redhat.com>
240
241         * HEADER: Remove.
242
243 2005-11-13  Jakub Jelinek  <jakub@redhat.com>
244
245         PR libgomp/24797
246         * team.c (initialize_team): Pass NULL rather than free as
247         pthread_key_create destructor.  Initialize thread specific data
248         pointer in initial thread to a static local variable rather than
249         malloced memory.
250
251 2005-11-11  Uros Bizjak  <uros@kss-loka.si>
252
253         * testsuite/lib/libgomp-dg.exp: Locate libgcc.a and append
254         its location to ld_library_path.
255
256 2005-11-10  Diego Novillo  <dnovillo@redhat.com>
257
258         * testsuite/libgomp.c/c.exp: Rename from dg.exp.
259
260 2005-11-10  Diego Novillo  <dnovillo@redhat.com>
261
262         * testsuite/libgomp.c: Rename from libgomp.dg.
263
264 2005-11-09  Diego Novillo  <dnovillo@redhat.com>
265
266         * testsuite/libgomp.c++/pr24455.C: Add copyin clause for
267         threadprivate variable 'i'.
268
269 2005-11-09  Jakub Jelinek  <jakub@redhat.com>
270
271         * config/linux/s390/futex.h: New file.
272         * configure.tgt: Use it.
273
274         * testsuite/libgomp.fortran/omp_parse4.f90: Move n initialization
275         before the parallel.
276
277 2005-11-08  Jakub Jelinek  <jakub@redhat.com>
278
279         PR c++/24734
280         * testsuite/libgomp.c++/master-1.C: New test.
281
282 2005-11-07  Jakub Jelinek  <jakub@redhat.com>
283
284         * testsuite/libgomp.dg/copyin-3.c: New test.
285
286 2005-11-07  Jakub Jelinek  <jakub@redhat.com>
287
288         * testsuite/libgomp.fortran/retval1.f90: New test.
289         * testsuite/libgomp.fortran/vla7.f90: New test.
290
291 2005-11-06  Jakub Jelinek  <jakub@redhat.com>
292
293         * testsuite/libgomp.fortran/vla2.f90: New test.
294         * testsuite/libgomp.fortran/vla3.f90: New test.
295         * testsuite/libgomp.fortran/vla4.f90: New test.
296         * testsuite/libgomp.fortran/vla5.f90: New test.
297         * testsuite/libgomp.fortran/vla6.f90: New test.
298
299 2005-11-01  Jakub Jelinek  <jakub@redhat.com>
300
301         * config/linux/sparc/futex.h: New file.
302         * configure.tgt: Use it.
303         * testsuite/lib/libgomp-dg.exp: Use -mcpu=v9 for sparc testing.
304
305         * critical.c: Include stdlib.h.
306         * acinclude.m4 (LIBGOMP_CHECK_SYNC_BUILTINS): Avoid warnings about
307         ignoring return value.
308         * configure.ac: Don't put -Wc,-pthread into XCFLAGS until after
309         LIBGOMP_CHECK_SYNC_BUILTINS check.
310         * configure: Rebuilt.
311
312 2005-10-31  Jakub Jelinek  <jakub@redhat.com>
313
314         * testsuite/libgomp.fortran/vla1.f90: New test.
315
316 2005-10-31  Richard Henderson  <rth@redhat.com>
317
318         * testsuite/libgomp.fortran/character2.f90: Fix race condition
319         setting 's' in different threads.
320
321 2005-10-31  Jakub Jelinek  <jakub@redhat.com>
322
323         * libgomp.h (attribute_hidden, ialias): Define.
324         * config/posix/proc.c (omp_get_num_procs): Add ialias.
325         * config/posix/time.c (omp_get_wtime, omp_get_wtick): Likewise.
326         * config/posix/lock.c (omp_init_lock, omp_init_nest_lock,
327         omp_destroy_lock, omp_destroy_nest_lock, omp_set_lock,
328         omp_set_nest_lock, omp_unset_lock, omp_unset_nest_lock,
329         omp_test_lock, omp_test_nest_lock): Likewise.
330         * config/linux/lock.c (omp_init_lock, omp_init_nest_lock,
331         omp_destroy_lock, omp_destroy_nest_lock, omp_set_lock,
332         omp_set_nest_lock, omp_unset_lock, omp_unset_nest_lock,
333         omp_test_lock, omp_test_nest_lock): Likewise.
334         * env.c (omp_set_dynamic, omp_set_nested, omp_set_num_threads,
335         omp_get_dynamic, omp_get_nested): Likewise.
336         * parallel.c (omp_get_num_threads, omp_get_max_threads,
337         omp_get_thread_num, omp_in_parallel): Likewise.
338         * fortran.c (ialias_redirect): Define.
339         (omp_init_lock, omp_init_nest_lock, omp_destroy_lock,
340         omp_destroy_nest_lock, omp_set_lock, omp_set_nest_lock,
341         omp_unset_lock, omp_unset_nest_lock, omp_test_lock,
342         omp_test_nest_lock, omp_set_dynamic, omp_set_nested,
343         omp_set_num_threads, omp_get_dynamic, omp_get_nested,
344         omp_in_parallel, omp_get_max_threads, omp_get_num_procs,
345         omp_get_num_threads, omp_get_thread_num, omp_get_wtick,
346         omp_get_wtime): Add ialias_redirect.
347
348 2005-10-30  Jakub Jelinek  <jakub@redhat.com>
349
350         * fortran.c: Include stdlib.h.
351
352 2005-10-29  Jakub Jelinek  <jakub@redhat.com>
353
354         * Makefile.am (env.o, env.lo): Depend on libgomp_f.h.
355         * Makefile.in: Regenerated.
356
357 2005-10-28  Jakub Jelinek  <jakub@redhat.com>
358
359         * mkomp_h.pl: Remove all -Wc, option prefixes in $COMPILE.
360         * libgomp_f.h.in (omp_check_defines): New function.
361         * env.c: Include libgomp_f.h.
362         (initialize_env): Call omp_check_defines.
363
364         * testsuite/libgomp.dg/copyin-2.c: New test.
365         * testsuite/libgomp.c++/copyin-2.C: New test.
366         * testsuite/libgomp.fortran/threadprivate3.f90: New test.
367
368         * testsuite/libgomp.fortran/threadprivate2.f90: New test.
369         * testsuite/libgomp.fortran/sharing2.f90: New test.
370
371         * testsuite/libgomp.dg/copyin-1.c: New test.
372         * testsuite/libgomp.c++/copyin-1.C: New test.
373
374 2005-10-26  Jakub Jelinek  <jakub@redhat.com>
375
376         * testsuite/libgomp.fortran/crayptr1.f90: New test.
377
378         * testsuite/libgomp.fortran/workshare1.f90: New test.
379
380         * libgomp.fortran/appendix-a/a.28.5.f90: Change into compile
381         only test.
382         * libgomp.fortran/sharing1.f90: New test.
383
384 2005-10-24  Jakub Jelinek  <jakub@redhat.com>
385
386         PR c++/24502
387         * testsuite/libgomp.c++/loop-7.C: New test.
388
389         * testsuite/libgomp.dg/nestedfn-2.c: New test.
390
391         * testsuite/libgomp.dg/nestedfn-1.c: New test.
392         * testsuite/libgomp.fortran/reduction6.f90: New test.
393         * testsuite/libgomp.fortran/nestedfn1.f90: New test.
394
395 2005-10-23  Richard Henderson  <rth@redhat.com>
396
397         * testsuite/libgomp.c++/ctor-1.C: New.
398         * testsuite/libgomp.c++/ctor-2.C: New.
399         * testsuite/libgomp.c++/ctor-3.C: New.
400         * testsuite/libgomp.c++/ctor-4.C: New.
401         * testsuite/libgomp.c++/ctor-5.C: New.
402         * testsuite/libgomp.c++/ctor-6.C: New.
403         * testsuite/libgomp.c++/ctor-7.C: New.
404         * testsuite/libgomp.c++/ctor-8.C: New.
405         * testsuite/libgomp.c++/ctor-9.C: New.
406
407 2005-10-21  Diego Novillo  <dnovillo@redhat.com>
408
409         PR 24455
410         * testsuite/libgomp.c++/pr24455-1.C: New test.
411         * testsuite/libgomp.c++/pr24455.C: New test.
412         * testsuite/libgomp.dg/pr24455-1.c: New test.
413         * testsuite/libgomp.dg/pr24455.c: New test.
414
415 2005-10-20  Richard Henderson  <rth@redhat.com>
416
417         * testsuite/libgomp.c++/loop-6.C: New.
418         * testsuite/libgomp.dg/loop-3.c: New.
419
420 2005-10-20  Jakub Jelinek  <jakub@redhat.com>
421
422         * testsuite/libgomp.fortran/jacobi.f: Don't make i and j
423         explicitly private.
424         * testsuite/libgomp.fortran/omp_parse1.f90 (test_do): Make i
425         explicitly shared.
426
427 2005-10-19  Diego Novillo  <dnovillo@redhat.com>
428
429         * testsuite/libgomp.fortran/jacobi.f: New test.
430
431 2005-10-19  Richard Henderson  <rth@redhat.com>
432
433         * configure.tgt (i?86-linux): Default to with_arch instead of
434         CFLAGS.  Add -mtune to match target_cpu.
435         (x86_64-linux): Tune to i686.
436
437         * fortran.c (omp_test_nest_lock_): Fix typo.
438
439 2005-10-19  Jakub Jelinek  <jakub@redhat.com>
440
441         * ordered.c (gomp_ordered_first, gomp_ordered_last, gomp_ordered_next,
442         gomp_ordered_sync): Do nothing if team->nthreads == 1.
443         * testsuite/libgomp.dg/ordered-3.c: New test.
444
445         * testsuite/libgomp.dg/appendix-a/a.18.1.c: Remove unconditional abort.
446         Remove volatile keyword.
447
448         * testsuite/libgomp.fortran/appendix-a/a.19.1.f90: Reorder variables
449         in COMMON block to avoid warnings on 64-bit targets.
450
451 2005-10-18  Diego Novillo  <dnovillo@redhat.com>
452
453         * testsuite/libgomp.dg/shared-3.c: New test.
454
455 2005-10-18  Jakub Jelinek  <jakub@redhat.com>
456
457         * testsuite/libgomp.fortran/appendix-a/a.31.3.f90: Removed.
458         * testsuite/libgomp.fortran/reduction5.f90: New test.
459
460 2005-10-18  Jakub Jelinek  <jakub@redhat.com>
461
462         * testsuite/libgomp.fortran/appendix-a/a.40.1.f90: Add -ffixed-form to
463         dg-options.
464         * testsuite/libgomp.fortran/appendix-a/a.18.1.f90: Likewise.  Enable
465         flush loop now that __sync_synchronize has proper memory barrier.
466         * testsuite/libgomp.fortran/appendix-a/a.3.1.f90: Fix a typo.
467         Add -ffixed-form to dg-options.
468
469 2005-10-17  Diego Novillo  <dnovillo@redhat.com>
470
471         * testsuite/libgomp.fortran/fortran.exp: Also gather tests
472         from subdirectories.
473         * testsuite/libgomp.fortran/appendix-a/a.15.1.f90: New test.
474         * testsuite/libgomp.fortran/appendix-a/a.16.1.f90: New test.
475         * testsuite/libgomp.fortran/appendix-a/a.18.1.f90: New test.
476         * testsuite/libgomp.fortran/appendix-a/a.19.1.f90: New test.
477         * testsuite/libgomp.fortran/appendix-a/a.2.1.f90: New test.
478         * testsuite/libgomp.fortran/appendix-a/a.21.1.f90: New test.
479         * testsuite/libgomp.fortran/appendix-a/a.22.7.f90: New test.
480         * testsuite/libgomp.fortran/appendix-a/a.22.8.f90: New test.
481         * testsuite/libgomp.fortran/appendix-a/a.26.1.f90: New test.
482         * testsuite/libgomp.fortran/appendix-a/a.28.1.f90: New test.
483         * testsuite/libgomp.fortran/appendix-a/a.28.2.f90: New test.
484         * testsuite/libgomp.fortran/appendix-a/a.28.3.f90: New test.
485         * testsuite/libgomp.fortran/appendix-a/a.28.4.f90: New test.
486         * testsuite/libgomp.fortran/appendix-a/a.28.5.f90: New test.
487         * testsuite/libgomp.fortran/appendix-a/a.3.1.f90: New test.
488         * testsuite/libgomp.fortran/appendix-a/a.31.3.f90: New test.
489         * testsuite/libgomp.fortran/appendix-a/a.31.4.f90: New test.
490         * testsuite/libgomp.fortran/appendix-a/a.31.5.f90: New test.
491         * testsuite/libgomp.fortran/appendix-a/a.33.3.f90: New test.
492         * testsuite/libgomp.fortran/appendix-a/a.38.1.f90: New test.
493         * testsuite/libgomp.fortran/appendix-a/a.39.1.f90: New test.
494         * testsuite/libgomp.fortran/appendix-a/a.4.1.f90: New test.
495         * testsuite/libgomp.fortran/appendix-a/a.40.1.f90: New test.
496         * testsuite/libgomp.fortran/appendix-a/a.5.1.f90: New test.
497         * testsuite/libgomp.fortran/appendix-a/a10.1.f90: New test.
498
499 2005-10-17  Jakub Jelinek  <jakub@redhat.com>
500
501         * testsuite/libgomp.dg/dg.exp: Only unset lang_* if
502         lang_library_path exists.  Use find instead of glob to gather tests.
503         * testsuite/libgomp.dg/appendix-a/appendix-a.exp: Removed.
504
505 2005-10-17  Diego Novillo  <dnovillo@redhat.com>
506
507         * testsuite/libgomp.dg/appendix-a/a.15.1.c: New test.
508         * testsuite/libgomp.dg/appendix-a/a.16.1.c: New test.
509         * testsuite/libgomp.dg/appendix-a/a.18.1.c: New test.
510         * testsuite/libgomp.dg/appendix-a/a.19.1.c: New test.
511         * testsuite/libgomp.dg/appendix-a/a.2.1.c: New test.
512         * testsuite/libgomp.dg/appendix-a/a.21.1.c: New test.
513         * testsuite/libgomp.dg/appendix-a/a.26.1.c: New test.
514         * testsuite/libgomp.dg/appendix-a/a.29.1.c: New test.
515         * testsuite/libgomp.dg/appendix-a/a.3.1.c: New test.
516         * testsuite/libgomp.dg/appendix-a/a.39.1.c: New test.
517         * testsuite/libgomp.dg/appendix-a/a.4.1.c: New test.
518         * testsuite/libgomp.dg/appendix-a/a.5.1.c: New test.
519         * testsuite/libgomp.dg/appendix-a/appendix-a.exp: New file.
520
521 2005-10-15  Jakub Jelinek  <jakub@redhat.com>
522
523         * testsuite/libgomp.dg/vla-1.c: New test.
524
525         * testsuite/libgomp.fortran/reference2.f90: New test.
526
527         * testsuite/libgomp.fortran/character2.f90: Remove explicit
528         declaration of omp_get_thread_num.
529         * testsuite/libgomp.fortran/threadprivate1.f90: Likewise.  Add
530         use omp_lib.
531
532         * testsuite/libgomp.fortran/reduction1.f90: New test.
533         * testsuite/libgomp.fortran/reduction2.f90: New test.
534         * testsuite/libgomp.fortran/reduction3.f90: New test.
535         * testsuite/libgomp.fortran/reduction4.f90: New test.
536
537 2005-10-13  Richard Henderson  <rth@redhat.com>
538
539         * Makefile.am (libgomp_la_SOURCES): Add bar.c.
540         * Makefile.in: Regenerate.
541         * barrier.c (GOMP_barrier): Use gomp_barrier_wait.
542         * libgomp.h: Include bar.h.
543         (struct gomp_barrier): Remove.
544         (struct gomp_team): Add barrier.  Replace master_barrier with
545         master_release.  Replace threads with ordered_release.
546         (struct gomp_thread): Replace barrier with release.
547         * ordered.c (gomp_ordered_first): Update for ordered_release change.
548         (gomp_ordered_last, gomp_ordered_next, gomp_ordered_static_init,
549         gomp_ordered_static_next, gomp_ordered_sync): Likewise.
550         * single.c (GOMP_single_copy_start): Use gomp_barrier_wait.
551         (GOMP_single_copy_end): Likewise.
552         * team.c (gomp_threads_dock): New.
553         (gomp_barrier_init, gomp_barrier_destroy): Remove.
554         (gomp_thread_start): Use gomp_barrier_wait.
555         (new_team, free_team): Update for gomp_team changes.
556         (gomp_team_start): Use gomp_barrier_wait and gomp_barrier_reinit.
557         (gomp_team_end): Use gomp_barrier_wait.
558         (initialize_team): Update for gomp_thread changes.
559         * work.c (gomp_work_share_end): Use gomp_barrier_wait_start.
560         (gomp_work_share_end_nowait): Use atomic ops when available.
561         * config/linux/bar.c, config/linux/bar.h: New files.
562         * config/posix/bar.c, config/posix/bar.h: New files.
563
564 2005-10-13  Jakub Jelinek  <jakub@redhat.com>
565
566         * single.c (GOMP_single_copy_end): Don't segfault if team is NULL.
567         * testsuite/libgomp.dg/single-2.c: New test.
568
569         * testsuite/libgomp.dg/dg.exp (lang_library_path, lang_test_file,
570         lang_link_flags): Unset, so that they aren't inherited from previously
571         sourced *.exp.
572
573         * testsuite/libgomp.fortran/threadprivate1.f90: New test.
574
575 2005-10-12  Richard Henderson  <rth@redhat.com>
576
577         * testsuite/lib/libgomp-dg.exp: Set blddir at toplevel.
578         (libgomp_init): Use lang_test_file, lang_library_path, and
579         lang_link_flags, set by the subdirectory files.  Add -fopenmp here.
580
581         * testsuite/libgomp.fortran/fortran.exp (lang_library_path): New.
582         (lang_test_file, lang_link_flags): New.
583         (DEFAULT_FFLAGS, ALWAYS_CFLAGS, multilibs, blddir): Remove.
584
585         * testsuite/libgomp.c++/c++.exp, testsuite/libgomp.c++/loop-1.C,
586         testsuite/libgomp.c++/loop-2.C, testsuite/libgomp.c++/loop-3.C,
587         testsuite/libgomp.c++/loop-4.C, testsuite/libgomp.c++/nested-1.C,
588         testsuite/libgomp.c++/parallel-1.C,
589         testsuite/libgomp.c++/reduction-1.C,
590         testsuite/libgomp.c++/reduction-2.C,
591         testsuite/libgomp.c++/reduction-3.C,
592         testsuite/libgomp.c++/sections-1.C, testsuite/libgomp.c++/shared-1.C,
593         testsuite/libgomp.c++/shared-2.C, testsuite/libgomp.c++/single-1.C,
594         testsuite/libgomp.c++/single-2.C, testsuite/libgomp.c++/single-3.C:
595         New files, largely cribbed from the C testsuite.
596
597 2005-10-12  Jakub Jelinek  <jakub@redhat.com>
598
599         * testsuite/libgomp.fortran/character1.f90: New test.
600         * testsuite/libgomp.fortran/character2.f90: New test.
601
602         * testsuite/libgomp.dg/nested-1.c: New test.
603         * testsuite/libgomp.dg/nested-2.c: New test.
604         * testsuite/libgomp.fortran/do1.f90: New test.
605         * testsuite/libgomp.fortran/do2.f90: New test.
606
607         * testsuite/libgomp.fortran/reference1.f90: New test.
608
609 2005-10-11  Jakub Jelinek  <jakub@redhat.com>
610
611         * testsuite/libgomp.dg/reduction-1.c: New test.
612         * testsuite/libgomp.dg/reduction-2.c: New test.
613         * testsuite/libgomp.dg/reduction-3.c: New test.
614
615 2005-10-10  Jakub Jelinek  <jakub@redhat.com>
616
617         * testsuite/libgomp.dg/atomic-1.c: New test.
618         * testsuite/libgomp.dg/atomic-2.c: New test.
619
620 2005-10-09  Richard Henderson  <rth@redhat.com>
621
622         * critical.c (atomic_lock): New.
623         (initialize_critical): Initialize it.
624         (GOMP_atomic_start, GOMP_atomic_end): New.
625         * libgomp.map: Export them.
626         * libgomp_g.h: Declare them.
627
628         * testsuite/libgomp.dg/atomic-10.c: Move from gcc testsuite.
629
630 2005-10-02  Richard Henderson  <rth@redhat.com>
631
632         * configure.ac: Move save_CFLAGS hack earlier.  Append -Wall/-Werror
633         to XCFLAGS instead of CFLAGS.
634
635 2005-09-30  Richard Henderson  <rth@redhat.com>
636
637         * configure.ac: Determine whether -pthread or -lpthread is needed.
638         * Makefile.am (libgomp_la_LDFLAGS): Remove explicit -lpthread.
639         * Makefine.in, configure: Rebuild.
640
641 2005-09-28  Richard Henderson  <rth@redhat.com>
642
643         * testsuite/libgomp.dg/omp-loop03.c: Fix return code.
644         * testsuite/libgomp.dg/omp-single-3.c: New test.
645
646 2005-09-28  Diego Novillo  <dnovillo@redhat.com>
647
648         * testsuite/libgomp.dg/omp-single-2.c: New test.
649         * testsuite/libgomp.dg/shared-2.c: Fix return code.
650
651 2005-09-27  Richard Henderson  <rth@redhat.com>
652
653         * testsuite/libgomp.dg/omp-loop03.c: Add initial barrier.
654         * testsuite/libgomp.dg/omp-parallel-for.c: Specify static schedule.
655
656 2005-09-27  Jakub Jelinek  <jakub@redhat.com>
657
658         * testsuite/libgomp.dg/omp-loop03.c: New test.
659
660 2005-09-27  Diego Novillo  <dnovillo@redhat.com>
661
662         * testsuite/libgomp.dg/omp-parallel-for.c: New test.
663
664 2005-09-27  Diego Novillo  <dnovillo@redhat.com>
665
666         * testsuite/libgomp.dg/omp-single-1.c: New test.
667         * testsuite/libgomp.dg/shared-1.c: Return 0.
668         Add prototype for abort.
669         * testsuite/libgomp.dg/shared-2.c: Likewise.
670
671 2005-09-26  Jakub Jelinek  <jakub@redhat.com>
672
673         * testsuite/libgomp.fortran/omp_parse3.f90: Fix non-conforming
674         constructs.
675
676 2005-09-26  Diego Novillo  <dnovillo@redhat.com>
677
678         * testsuite/libgomp.dg/shared-1.c: New test.
679         * testsuite/libgomp.dg/shared-2.c: New test.
680
681 2005-09-24  Richard Henderson  <rth@redhat.com>
682
683         * testsuite/libgomp.dg/omp_workshare3.c: Mark dg-error.
684
685 2005-09-24  Richard Henderson  <rth@redhat.com>
686
687         * iter.c (gomp_iter_static_next): Round up when computing number
688         of iterations.  Don't bother distributing a remainder equally.
689
690         * testsuite/libgomp.dg/omp-loop01.c (main1): Rename from main.
691         Don't call srand.  Zero b before testing.
692         (main): New.
693
694 2005-09-24  Jakub Jelinek  <jakub@redhat.com>
695
696         * testsuite/libgomp.fortran/omp_atomic1.f90: New test.
697         * testsuite/libgomp.fortran/omp_atomic2.f90: New test.
698
699 2005-09-23  Jakub Jelinek  <jakub@redhat.com>
700
701         * testsuite/libgomp.fortran/omp_parse1.f90: Add a test for !$omp do
702         without !$omp end do, followed immediately by subroutine end.
703
704 2005-09-23  Diego Novillo  <dnovillo@redhat.com>
705
706         * testsuite/libgomp.dg/omp-parallel-if.c: New test.
707
708 2005-09-22  Richard Henderson  <rth@redhat.com>
709
710         * critical.c (GOMP_critical_name_start): Change argument to void**.
711         Reuse the pointer space if the mutex fits.
712         (GOMP_critical_name_end): Likewise.
713         (initialize_critical): Don't define if GOMP_MUTEX_INIT_0.
714         * libgomp_g.h (GOMP_critical_name_start): Update decl.
715         (GOMP_critical_name_end): Likewise.
716         * config/linux/mutex.h (GOMP_MUTEX_INIT_0): New.
717         * config/posix/mutex.h (GOMP_MUTEX_INIT_0): New.
718
719 2005-09-20  Richard Henderson  <rth@redhat.com>
720
721         * critical.c (GOMP_critical_name_start, GOMP_critical_name_end): New.
722         (create_lock_lock): New.
723         (initialize_critical): Initialize it.
724         * libgomp.map (GOMP_critical_name_start, GOMP_critical_name_end): New.
725         * libgomp_g.h (GOMP_ordered_start, GOMP_ordered_end): Declare.
726
727 2005-09-20  Diego Novillo  <dnovillo@redhat.com>
728
729         * testsuite/libgom.dg/omp-loop01.c: Include stdio.h.
730
731 2005-09-20  Diego Novillo  <dnovillo@redhat.com>
732
733         * testsuite/libgomp.dg/omp-loop01.c: New test.
734         * testsuite/libgomp.dg/omp-loop02.c: New test.
735
736 2005-09-20  Jakub Jelinek  <jakub@redhat.com>
737
738         * configure.ac (AC_PROG_FC): Add.
739         (USE_FORTRAN): New automake conditional.
740         * configure: Rebuilt.
741         * Makefile.am (libgomp_la_SOURCES): Add fortran.c.
742         (nodist_include_HEADERS): Add omp_lib.h, omp_lib.f90 and libgomp_f.h.
743         If USE_FORTRAN, add also omp_lib.mod and omp_lib_kinds.mod.
744         Add rules to build them.
745         * Makefile.in: Rebuilt.
746         * mkomp_h.pl: Compute and replace also OMP_LOCK_KIND and
747         OMP_NEST_LOCK_KIND.
748         * libgomp.map: Add Fortran wrappers.
749         * libgomp_f.h.in: New file.
750         * omp_lib.h.in: New file.
751         * omp_lib.f90.in: New file.
752         * fortran.c: New file.
753         * testsuite/lib/libgomp-dg.exp: Load a few more .exp files.
754         Append libgfortran directory to LD_LIBRARY_PATH if it exists.
755         Add -Lpath_to_libgfortran and -lgfortran -lgfortranbegin if
756         libgfortran has been built.
757         * testsuite/libgomp.fortran/fortran.exp: New file.
758         * testsuite/libgomp.fortran/omp_cond1.f: New test.
759         * testsuite/libgomp.fortran/omp_cond2.f: New test.
760         * testsuite/libgomp.fortran/omp_cond3.F90: New test.
761         * testsuite/libgomp.fortran/omp_cond4.F90: New test.
762         * testsuite/libgomp.fortran/omp_hello.f: New test.
763         * testsuite/libgomp.fortran/omp_orphan.f: New test.
764         * testsuite/libgomp.fortran/omp_parse1.f90: New test.
765         * testsuite/libgomp.fortran/omp_parse2.f90: New test.
766         * testsuite/libgomp.fortran/omp_parse3.f90: New test.
767         * testsuite/libgomp.fortran/omp_parse4.f90: New test.
768         * testsuite/libgomp.fortran/omp_reduction.f: New test.
769         * testsuite/libgomp.fortran/omp_workshare1.f: New test.
770         * testsuite/libgomp.fortran/omp_workshare2.f: New test.
771
772 2005-08-30  Richard Henderson  <rth@redhat.com>
773
774         * loop.c (GOMP_loop_static_start): Provide fallback wrapper
775         function for when aliases are not usable.
776         (GOMP_loop_dynamic_start, GOMP_loop_guided_start,
777         GOMP_loop_ordered_static_start, GOMP_loop_ordered_dynamic_start,
778         GOMP_loop_ordered_guided_start, GOMP_loop_static_next,
779         GOMP_loop_dynamic_next, GOMP_loop_guided_next,
780         GOMP_loop_ordered_static_next, GOMP_loop_ordered_dynamic_next,
781         GOMP_loop_ordered_guided_next): Likewise.
782         * ordered.c (GOMP_ordered_start): Likewise.
783
784 2005-08-01  Diego Novillo  <dnovillo@redhat.com>
785
786         * testsuite/libgomp.dg/dg.exp: Use -O2 for now.
787         * testsuite/libgomp.dg/omp_hello.c: Fix return code
788         * testsuite/libgomp.dg/omp_matvec.c: Likewise.
789         * testsuite/libgomp.dg/omp_orphan.c: Likewise
790         * testsuite/libgomp.dg/omp_reduction.c: Likewise
791         * testsuite/libgomp.dg/omp_workshare1.c: Likewise
792         * testsuite/libgomp.dg/omp_workshare2.c: Likewise
793         * testsuite/libgomp.dg/omp_workshare3.c: Likewise
794         * testsuite/libgomp.dg/omp_workshare4.c: Likewise
795
796 2005-07-07  Eric Christopher  <echristo@redhat.com>
797             Diego Novillo  <dnovillo@redhat.com>
798
799         * testsuite/libgomp.dg/dg.exp: Add -fopenmp to DEFAULT_CFLAGS.
800         * testsuite/libgomp.dg/omp_hello.c: Add standard includes, fix
801         up code.
802         * testsuite/libgomp.dg/omp_matvec.c: Ditto.
803         * testsuite/libgomp.dg/omp_orphan.c: Ditto.
804         * testsuite/libgomp.dg/omp_reduction.c: Ditto.
805         * testsuite/libgomp.dg/omp_workshare1.c: Ditto.
806         * testsuite/libgomp.dg/omp_workshare2.c: Ditto.
807         * testsuite/libgomp.dg/omp_workshare3.c: Ditto.
808         * testsuite/libgomp.dg/omp_workshare4.c: Ditto.
809
810 2005-06-13  Diego Novillo  <dnovillo@redhat.com>
811
812         * TOPLEVEL.patch: Remove.
813
814 2005-05-16  Richard Henderson  <rth@redhat.com>
815
816         * configure.ac: Test for clock_gettime.
817         * config.h.in, configure: Rebuild.
818         * config/posix/time.c: Use recommended TIME_WITH_SYS_TIME pattern.
819         (omp_get_wtime): Use clock_gettime if available.
820         (omp_get_wtick): Use clock_getres if available.
821
822 2005-05-11  Richard Henderson  <rth@redhat.com>
823
824         * config/linux/ia64/futex.h: New file.
825         * configure.tgt: Use it.
826
827         * team.c (gomp_barrier_init, gomp_barrier_destroy): Mark inline.
828
829 2005-05-07  Richard Henderson  <rth@redhat.com>
830
831         * config/linux/powerpc/futex.h: New file.
832         * configure.tgt: Use it.
833
834         * config/linux/i486/futex.h: Merge ...
835         * config/linux/x86_64/futex.h: ... into ...
836         * config/linux/x86/futex.h: ... here.
837         * configure.tgt: Update to match.
838
839 2005-05-06  Richard Henderson  <rth@redhat.com>
840
841         * config/linux/alpha/futex.h: Conditionally define SYS_futex.
842         * config/linux/i486/futex.h: Likewise.
843         * config/linux/x86_64/futex.h: Likewise.
844
845         * config/linux/lock.c: New file.
846         * config/linux/omp-lock.h: New file.
847
848         * critical.c, env.h: Don't include omp.h
849         * config/posix/lock.c: Include libgomp.h instead of omp.h.
850         * config/posix/time.c: Likewise.
851         * config/posix/omp-lock.h: New file.
852         * libgomp.h: Include omp-lock.h and omp.h.
853         * Makefile.am (nodist_include_HEADERS): New.
854         (omp.h): New rule.
855         * configure.ac (PERL): New.
856         * mkomp_h.pl: New file.
857         * omp.h.in: Rename from omp.h; replace omp_lock_t and omp_nest_lock_t
858         with templates.
859         * Makefile.in, configure, testsuite/Makefile.in: Rebuild.
860
861         * testsuite/lib/libgomp-dg.exp (libgomp_init): Add include into
862         build directory.  Re-add -march=i486 hack.
863
864         * testsuite/lib/libgomp-dg.exp (libgomp_compile_flags): Remove.
865         (libgomp_link_flags): Remove.
866         (libgomp_initialized): Remove.
867         (libgomp_init): Don't protect from reinitialization.  Copy code
868         from libstdc++ for getting the multilib set correctly.
869
870 2005-05-05  Richard Henderson  <rth@redhat.com>
871
872         * config/linux/alpha/futex.h: New file.
873         * configure.tgt (alpha*-*-linux*): Use it.
874
875         * config/posix/mutex.c: New file.
876         * config/posix/sem.c: Use libgomp.h.
877
878         * configure.tgt (x86_64-linux): Also test CC for -m32.
879         * config/linux/x86_64/futex.h (futex_wait): Fix r10 usage.
880
881         * testsuite/lib/libgomp-dg.exp (libgomp_link_flags): Add / 
882         after $gccpath.
883
884         * Makefile.am (SUBDIRS): New.
885         (libgomp_la_LDFLAGS): Add -lpthread.
886         * configure.ac (AM_INIT_AUTOMAKE): Enable dependencies.
887         * Makefile.in, aclocal.m4, config.h.in, configure: Rebuild.
888
889         * libgomp_g.h: New file.
890         * libgomp.h: Split out all public declarations to libgomp_g.h.
891         Use pragma GCC visibility instead of ATTRIBUTE_HIDDEN.
892         * config/linux/mutex.h: Remove ATTRIBUTE_HIDDEN.
893         * config/linux/sem.h: Likewise.
894         * config/posix/sem.h: Likewise.
895
896         * Makefile.am (AM_LDFLAGS): New.
897         (libgomp_version_script): Split out from ...
898         (libgomp_la_LDFLAGS): ... here.
899         (libgomp_version_info): New.
900         * acinclude.m4 (LIBGOMP_CHECK_TLS): Use LIBGOMP_ENABLE.
901         (LIBGOMP_ENABLE): New.
902         (LIBGOMP_CHECK_LINKER_FEATURES): New.
903         (LIBGOMP_ENABLE_SYMVERS): New.
904         * configure.ac (AC_INIT): Version 1.0.
905         (enable-version-specific-runtime-libs): Use LIBGOMP_ENABLE.
906         (enable-linux-futex): Likewise.  Rename from enable-futex.
907         (libtool_VERSION): New.
908         (LIBGOMP_ENABLE_SYMVERS): Use it.
909         * configure.tgt: Check with_gnu_ld wrt have_tls optimizations.
910         * Makefile.in, aclocal.m4, configure: Rebuild.
911
912         * config/linux/mutex.c: Include libgomp.h instead of mutex.h.
913         (gomp_mutex_unlock_slow): Fix typo.
914         * config/linux/sem.c: Similarly.
915         (gomp_sem_post_slow): Fix typo.
916         * config/linux/sem.h (gomp_sem_post_slow): Fix typo.
917         * config/linux/i486/futex.h: Remove USE_LINUX_SYSENTER code.
918         [__PIC__] (sys_futex0): Don't use tmp output in asm.
919
920         * Makefile.am (AM_CFLAGS): Expand with XCFLAGS.
921         (libgomp_la_LDFLAGS): Add top_srcdir to path.
922         * acinclude.m4: Copy libtool.m4 stuff from libgfortran.
923         * configure.ac: Check for getloadavg.  Substitute XCFLAGS and
924         XLDFLAGS.  Add XCFLAGS to CFLAGS around LIBGOMP_CHECK_SYNC_BUILTINS.
925         * configure.tgt: Set XCFLAGS and XLDFLAGS instead of CFLAGS and
926         LDFLAGS.  Pull enable_futex check to top-level.
927         * libgomp.h: Fix sem.h and mutex.h includes.  Define ATTRIBUTE_HIDDEN.
928         * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate.
929
930         First attempt at real configury.
931         * Makefile, config.h: Remove file.
932         * Makefile.am, Makefile.in: New file.
933         * acinclude.m4 aclocal.m4: New file.
934         * configure.ac, configure.tgt, configure: New file.
935
936         * config/posix/lock.c: Rename from sys-lock.c.
937         * config/posix/mutex.h: Rename from sys-mutex.h.
938         * config/posix/sem.c: Rename from sys-sem.c.
939         * config/posix/sem.h: Rename from sys-sem.h.
940         * config/posix/proc.c: Rename from sys-proc.c.
941         * config/posix/time.c: Rename from sys-proc.c.
942
943         * config/linux/mutex.c: New file.
944         * config/linux/mutex.h: New file.
945         * config/linux/sem.c: New file.
946         * config/linux/sem.h: New file.
947         * config/linux/i486/futex.h: New file.
948         * config/linux/x86_64/futex.h: New file.
949
950 2005-05-04  Richard Henderson  <rth@redhat.com>
951
952         * iter.c (gomp_iter_dynamic_next, gomp_iter_guided_next): New.
953         * libgomp.h: Declare them.
954         * loop.c (gomp_loop_dynamic_start, gomp_loop_guided_start,
955         gomp_loop_dynamic_next, gomp_loop_guided_next): Use them.
956
957 2005-05-04  Richard Henderson  <rth@redhat.com>
958
959         * libgomp-1 code drop
960
961 2005-05-04  Richard Henderson  <rth@redhat.com>
962
963         * iter.c (gomp_iter_static_next): Return tri-state on 0.
964         * ordered.c (gomp_ordered_static_next): Remove not_last argument.
965         * libgomp.h (struct gomp_team_state): Make static_trip unsigned.
966         (gomp_iter_static_next): Update.
967         (gomp_ordered_static_next): Update.
968         * loop.c (gomp_loop_static_start): Update for gomp_iter_static_next.
969         (gomp_loop_ordered_static_start): Likewise.  Exit early for a
970         totally empty range.
971         (gomp_loop_ordered_static_next): Refine test for calling
972         gomp_ordered_static_next.
973         * testsuite/ordered-1.c: Add case for more threads than iterations.
974
975         * iter.c (gomp_iter_runtime_next_locked): Remove.
976         * loop.c (gomp_loop_static_start, gomp_loop_dynamic_start,
977         gomp_loop_guided_start, gomp_loop_ordered_static_start, 
978         gomp_loop_ordered_dynamic_start, gomp_loop_ordered_guided_start,
979         gomp_loop_static_next, gomp_loop_dynamic_next, gomp_loop_guided_next,
980         gomp_loop_ordered_static_next, gomp_loop_ordered_dynamic_next,
981         gomp_loop_ordered_guided_next): Downcase name, make static, add
982         an external alias with the old name.
983         (GOMP_loop_runtime_start, GOMP_loop_ordered_runtime_start,
984         GOMP_loop_runtime_next, GOMP_loop_ordered_runtime_next): Use a
985         switch and call one of the above static functions.
986         * libgomp.h: Update.
987
988         * work.c (gomp_work_share_start): Lock the mutex for !first too.
989         * loop.c (GOMP_loop_static_start, GOMP_loop_dynamic_start,
990         GOMP_loop_guided_start, GOMP_loop_runtime_start,
991         GOMP_loop_ordered_static_start, GOMP_loop_ordered_dynamic_start,
992         GOMP_loop_ordered_guided_start): Update to match.
993         * sections.c (GOMP_sections_start): Likewise.
994         * single.c (GOMP_single_start, GOMP_single_copy_start): Likewise.
995
996         * ordered.c (gomp_ordered_first, gomp_ordered_last, gomp_ordered_next,
997         gomp_ordered_static_init, gomp_ordered_static_next): Rename s/_loop//.
998         Use bounds check instead of modulus.
999         (gomp_ordered_sync): Split out of GOMP_ordered_start.
1000         (gomp_ordered_last): Don't sync with ordered_owner here.
1001         (gomp_ordered_next): Likewise.
1002         (gomp_ordered_static_loop_next): Likewise.
1003         * loop.c, libgomp.h: Update to match.
1004
1005         * libgomp.h (GOMP_barrier): Declare.
1006
1007         * testsuite/barrier-1.c: New file.
1008         * testsuite/critical-1.c: New file.
1009         * testsuite/ordered-2.c: New file.
1010         * testsuite/ordered-1.c: New file.
1011         * testsuite/sections-1.c: New file.
1012         * testsuite/single-1.c: New file.
1013         * testsuite/Makefile (TESTS): Add them.
1014
1015 2005-05-04  Richard Henderson  <rth@redhat.com>
1016
1017         * libgomp.h (struct gomp_work_share): Add ordered_owner.
1018         * loop.c (GOMP_loop_static_start): If not the startup thread,
1019         acquire the mutex to wait for initialization complete.
1020         (GOMP_loop_ordered_static_start): Likewise.
1021         (GOMP_loop_ordered_runtime_start): Likewise.
1022         (GOMP_loop_ordered_static_first): Remove.
1023         (GOMP_loop_ordered_dynamic_first): Remove.
1024         (GOMP_loop_ordered_guided_first): Remove.
1025         (GOMP_loop_ordered_runtime_first): Remove.
1026         * ordered.c (gomp_ordered_loop_first): Post to own release when
1027         we're the first thread.
1028         (gomp_ordered_loop_last): Wait on release if not owner.
1029         (gomp_ordered_loop_next): Likewise.
1030         (gomp_ordered_static_loop_init): New.
1031         (gomp_ordered_static_loop_next): Use ordered_owner.
1032         (GOMP_ordered_start): Likewise.
1033         * work.c (gomp_new_work_share): Initialize ordered_owner.
1034
1035 2005-05-03  Richard Henderson  <rth@redhat.com>
1036
1037         * Makefile (OPT): New.
1038         (CFLAGS): Use it.
1039
1040         * loop.c (GOMP_loop_end, GOMP_loop_end_nowait): New.
1041         * sections.c (GOMP_sections_end, GOMP_sections_end_nowait): New.
1042         * libgomp.h, libgomp.map, NOTES: Update to match.
1043
1044         * team.c (struct gomp_thread_start_data): Remove ts, fn, data.
1045         Add initialized and thr members.
1046         (gomp_thread_start): Pause when initially spawned to wait for
1047         the whole team to be created.
1048         (gomp_team_start): Release team members at the end.
1049
1050         * testsuite/loop-1.c (N): New.  Use it instead of hardcoded 100.
1051         (f_foo_1): Use GOMP_loop_end.
1052         (f_foo_2): Use GOMP_loop_end_nowait.
1053
1054         * testsuite/loop-2.c: New file.
1055         * testsuite/Makefile (TESTS): Add it.
1056
1057 2005-05-03  Richard Henderson  <rth@redhat.com>
1058
1059         * iter.c (gomp_iter_static_next): Fix overflow check typo.
1060         (gomp_iter_dynamic_next_locked): Fix overflow check thinko.
1061         * team.c (new_team): Initialize oldest_live_gen to 1 if no
1062         initial work_share.
1063
1064         * testsuite/Makefile: New file.
1065         * testsuite/loop-1.c: New file.
1066
1067 2005-05-03  Richard Henderson  <rth@redhat.com>
1068
1069         Initial implementation and checkin.