OSDN Git Service

* configure.tgt: Enable futex for MIPS.
[pf3gnuchains/gcc-fork.git] / libgomp / ChangeLog
1 2008-07-28  Ilie Garbacea  <ilie@mips.com>
2             Chao-ying Fu  <fu@mips.com>
3
4         * configure.tgt: Enable futex for MIPS.
5         * config/linux/mips/futex.h: New file.
6
7 2008-07-16  Jakub Jelinek  <jakub@redhat.com>
8
9         * team.c (gomp_team_end): Free team immediately if it has
10         just one thread.
11
12 2008-07-08  David Edelsohn  <edelsohn@gnu.org>
13
14         * testsuite/libgomp.c++/c++.exp: Append multilib library path.
15         * testsuite/libgomp.fortran/fortran.exp: Same.
16         * testsuite/libgomp.c/c.exp: Same.
17         * testsuite/lib/libgomp.exp: Append AIX libgcc pthread multilib
18         directory to library path first.
19
20 2008-06-29  Krister Walfridsson  <krister.walfridsson@gmail.com>
21
22         * env.c (parse_stacksize): Add cast to avoid warning.
23         (parse_spincount): Likewise.
24
25 2008-06-27  Jakub Jelinek  <jakub@redhat.com>
26
27         * testsuite/libgomp.c/loop-10.c: New test.
28         * libgomp.c/loop-3.c (main): Add lastprivate clause.
29         * libgomp.c++/loop-6.C (main): Likewise.
30
31         PR debug/36617
32         * testsuite/libgomp.c/debug-1.c: New test.
33
34 2008-06-19  Jakub Jelinek  <jakub@redhat.com>
35
36         * testsuite/libgomp.c/nqueens-1.c: New test.
37
38         PR c++/36523
39         * testsuite/libgomp.c++/task-7.C: New function.
40
41 2008-06-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42
43         * configure: Regenerate.
44
45 2008-06-15  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
46
47         * env.c (initialize_env): Always initialize gomp_remaining_threads_lock
48         mutex when HAVE_SYNC_BUILTINS isn't defined.
49
50 2008-06-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
51
52         * libgomp.texi (omp_test_lock): Fix typo.
53
54 2008-06-12  Tobias Burnus  <burnus@net-b.de>
55
56         * omp_lib.f90.in: Add "implicit none".
57
58 2008-06-12  Jakub Jelinek  <jakub@redhat.com>
59
60         PR middle-end/36506
61         * testsuite/libgomp.c/reduction-5.c: New test.
62
63 2008-06-11  Jakub Jelinek  <jakub@redhat.com>
64
65         * libgomp.h (struct gomp_task): Add in_tied_task field.
66         * task.c (gomp_init_task): Initialize it.
67         (GOMP_task): Likewise.  Call gomp_team_barrier_set_task_pending
68         unconditionally.  Don't call gomp_team_barrier_wake if
69         current task is implicit or if(0) from implicit and number of
70         running tasks is equal to nthreads - 1.
71
72         PR libgomp/36471
73         * omp_lib.f90.in (omp_get_ancestor_thread_num_8,
74         omp_get_team_size_8): Fix pastos.
75
76         PR libgomp/36469
77         * configure.ac: Add AC_CHECK_FUNCS (strtoull).
78         * configure: Regenerated.
79         * config.h.in: Regenerated.
80         * env.c (strtoull): Define to strtoul if HAVE_STRTOULL is not
81         defined.
82
83 2008-06-06  Andreas Tobler  <a.tobler@schweiz.org>
84
85         PR bootstrap/36452
86         * loop_ull.c (GOMP_loop_ull_static_start): Adjust API.
87         (GOMP_loop_ull_dynamic_start): Likewise.
88         (GOMP_loop_ull_guided_start): Likewise.
89         (GOMP_loop_ull_ordered_static_start): Likewise.
90         (GOMP_loop_ull_ordered_dynamic_start): Likewise.
91         (GOMP_loop_ull_ordered_guided_start): Likewise.
92
93 2008-06-06  Jakub Jelinek  <jakub@redhat.com>
94             Richard Henderson  <rth@redhat.com>
95             Ulrich Drepper  <drepper@redhat.com>
96             Jakob Blomer  <jakob.blomer@ira.uka.de>
97
98         * configure.ac (LIBGOMP_GNU_SYMBOL_VERSIONING): New AC_DEFINE.
99         Substitute also OMP_*LOCK_25*.
100         * configure: Regenerated.
101         * config.h.in: Regenerated.
102         * Makefile.am (libgomp_la_SOURCES): Add loop_ull.c, iter_ull.c,
103         ptrlock.c and task.c.
104         * Makefile.in: Regenerated.
105         * testsuite/Makefile.in: Regenerated.
106         * task.c: New file.
107         * loop_ull.c: New file.
108         * iter_ull.c: New file.
109         * libgomp.h: Include ptrlock.h.
110         (enum gomp_task_kind): New type.
111         (struct gomp_team): Add task_lock, task_queue, task_count,
112         task_running_count, single_count fields.  Add
113         work_share_list_free_lock ifndef HAVE_SYNC_BUILTINS.
114         Remove work_share_lock, generation_mask,
115         oldest_live_gen, num_live_gen and init_work_shares fields, add
116         work work_share_list_alloc, work_share_list_free and work_share_chunk
117         fields.  Change work_shares from pointer to pointers into an array.
118         Change ordered_release field into gomp_sem_t ** from flexible array
119         member.  Add implicit_task and initial_work_shares fields.
120         Move close to the end of the struct.
121         (struct gomp_team_state): Add single_count, last_work_share,
122         active_level and level fields, remove work_share_generation.
123         (gomp_barrier_handle_tasks): New prototype.
124         (gomp_finish_task): New inline function.
125         (struct gomp_work_share): Move chunk_size, end, incr into
126         transparent union/struct, add chunk_size_ull, end_ll, incr_ll and
127         next_ll fields.  Reshuffle fields.  Add next_alloc,
128         next_ws, next_free and inline_ordered_team_ids fields, change
129         ordered_team_ids into pointer from flexible array member.
130         Add mode field.  Put lock and next into a different cache line
131         from most of the write-once fields.
132         (gomp_iter_ull_static_next, gomp_iter_ull_dynamic_next_locked,
133         gomp_iter_ull_guided_next_locked, gomp_iter_ull_dynamic_next,
134         gomp_iter_ull_guided_next): New prototypes.
135         (gomp_new_icv): New prototype.
136         (struct gomp_thread): Add thread_pool and task fields.
137         (struct gomp_thread_pool): New type.
138         (gomp_new_team): New prototype.
139         (gomp_team_start): Change type of last argument.
140         (gomp_new_work_share): Removed.
141         (gomp_init_work_share, gomp_fini_work_share): New prototypes.
142         (gomp_work_share_init_done): New static inline.
143         (gomp_throttled_spin_count_var, gomp_available_cpus,
144         gomp_managed_threads): New extern decls.
145         (gomp_init_task): New prototype.
146         (gomp_spin_count_var): New extern var decl.
147         (LIBGOMP_GNU_SYMBOL_VERSIONING): Undef if no visibility
148         or no alias support, or if not PIC.
149         (gomp_init_lock_30, gomp_destroy_lock_30, gomp_set_lock_30,
150         gomp_unset_lock_30, gomp_test_lock_30, gomp_init_nest_lock_30,
151         gomp_destroy_nest_lock_30, gomp_set_nest_lock_30,
152         gomp_unset_nest_lock_30, gomp_test_nest_lock_30, gomp_init_lock_25,
153         gomp_destroy_lock_25, gomp_set_lock_25, gomp_unset_lock_25,
154         gomp_test_lock_25, gomp_init_nest_lock_25, gomp_destroy_nest_lock_25,
155         gomp_set_nest_lock_25, gomp_unset_nest_lock_25,
156         gomp_test_nest_lock_25): New prototypes.
157         (omp_lock_symver, strong_alias): Define.
158         (gomp_remaining_threads_count, gomp_remaining_threads_lock): New
159         decls.
160         (gomp_end_task): New.
161         (struct gomp_task_icv, gomp_global_icv): New.
162         (gomp_thread_limit_var, gomp_max_active_levels_var): New.
163         (struct gomp_task): New.
164         (gomp_nthreads_var, gomp_dyn_var, gomp_nest_var,
165         gomp_run_sched_var, gomp_run_sched_chunk): Remove.
166         (gomp_icv): New.
167         (gomp_schedule_type): Reorder enum to match
168         omp_sched_t.
169         * team.c (struct gomp_thread_start_data): Add thread_pool and task
170         fields.
171         (gomp_thread_start): Add gomp_team_barrier_wait call.
172         For non-nested case remove clearing of docked thread thr fields.
173         Use pool fields instead of global gomp_* variables.  Use
174         gomp_barrier_wait_last when needed.  Initialize ts.active_level.
175         Create tasks for each member thread.
176         (free_team): Only destroy team barrier, task_lock here and free it.
177         (gomp_free_thread): Free last_team if non-NULL.
178         (gomp_team_end): Call gomp_team_barrier_wait instead of
179         gomp_barrier_wait.  For nested case call one extra
180         gomp_barrier_wait.  Move here some destruction from free_team.
181         Call free_team on pool->last_team if any, rather than freeing
182         current team.  Destroy work_share_list_free_lock ifndef
183         HAVE_SYNC_BUILTINS.
184         (gomp_new_icv): New function.
185         (gomp_threads, gomp_threads_size, gomp_threads_used,
186         gomp_threads_dock): Removed.
187         (gomp_thread_destructor): New variable.
188         (gomp_new_thread_pool, gomp_free_pool_helper, gomp_free_thread): New
189         functions.
190         (gomp_team_start): Create new pool if current thread doesn't have
191         one.  Use pool fields instead of global gomp_* variables. 
192         Initialize thread_pool field for new threads.  Clear single_count.
193         Change last argument from ws to team, don't create
194         new team, set ts.work_share to &team->work_shares[0] and clear
195         ts.last_work_share.  Don't clear ts.work_share_generation.
196         If number of threads changed, adjust atomically gomp_managed_threads.
197         Use gomp_init_task instead of gomp_new_task,
198         set thr->task to the corresponding implicit_task array entry.
199         Create tasks for each member thread.  Initialize ts.level.
200         (initialize_team): Call pthread_key_create on
201         gomp_thread_destructor.
202         (team_destructor): New function.
203         (new_team): Removed.
204         (gomp_new_team): New function.
205         (free_team): Free gomp_work_share blocks chained through next_alloc,
206         instead of freeing work_shares and destroying work_share_lock.
207         (gomp_team_end): Call gomp_fini_work_share.  If number of threads
208         changed, adjust atomically gomp_managed_threads.  Use gomp_end_task.
209         * barrier.c (GOMP_barrier): Call gomp_team_barrier_wait instead
210         of gomp_barrier_wait.
211         * single.c (GOMP_single_copy_start): Call gomp_team_barrier_wait
212         instead of gomp_barrier_wait.  Call gomp_work_share_init_done
213         if gomp_work_share_start returned true.  Don't unlock ws->lock.
214         (GOMP_single_copy_end): Call gomp_team_barrier_wait instead
215         of gomp_barrier_wait.
216         (GOMP_single_start): Rewritten if HAVE_SYNC_BUILTINS.  Call
217         gomp_work_share_init_done if gomp_work_share_start returned true.
218         Don't unlock ws->lock.
219         * work.c: Include stddef.h.
220         (free_work_share): Use work_share_list_free_lock instead
221         of atomic chaining ifndef HAVE_SYNC_BUILTINS.  Add team argument.
222         Call gomp_fini_work_share and then either free ws if orphaned, or
223         put it into work_share_list_free list of the current team.
224         (alloc_work_share, gomp_init_work_share, gomp_fini_work_share): New
225         functions.
226         (gomp_work_share_start, gomp_work_share_end,
227         gomp_work_share_end_nowait): Rewritten.
228         * omp_lib.f90.in Change some tabs to spaces to prevent warnings.
229         (openmp_version): Set to 200805.
230         (omp_sched_kind, omp_sched_static, omp_sched_dynamic,
231         omp_sched_guided, omp_sched_auto): New parameters.
232         (omp_set_schedule, omp_get_schedule, omp_get_thread_limit,
233         omp_set_max_active_levels, omp_get_max_active_levels,
234         omp_get_level, omp_get_ancestor_thread_num, omp_get_team_size,
235         omp_get_active_level): New interfaces.
236         * omp_lib.h.in (openmp_version): Set to 200805.
237         (omp_sched_kind, omp_sched_static, omp_sched_dynamic,
238         omp_sched_guided, omp_sched_auto): New parameters.
239         (omp_set_schedule, omp_get_schedule, omp_get_thread_limit,
240         omp_set_max_active_levels, omp_get_max_active_levels,
241         omp_get_level, omp_get_ancestor_thread_num, omp_get_team_size,
242         omp_get_active_level): New externals.
243         * loop.c: Include limits.h.
244         (GOMP_loop_runtime_next, GOMP_loop_ordered_runtime_next): Handle
245         GFS_AUTO.
246         (GOMP_loop_runtime_start, GOMP_loop_ordered_runtime_start):
247         Likewise.  Use gomp_icv.
248         (gomp_loop_static_start, gomp_loop_dynamic_start): Clear
249         ts.static_trip here.
250         (gomp_loop_static_start, gomp_loop_ordered_static_start): Call
251         gomp_work_share_init_done after gomp_loop_init.  Don't unlock ws->lock.
252         (gomp_loop_dynamic_start, gomp_loop_guided_start): Call
253         gomp_work_share_init_done after gomp_loop_init.  If HAVE_SYNC_BUILTINS,
254         don't unlock ws->lock, otherwise lock it.
255         (gomp_loop_ordered_dynamic_start, gomp_loop_ordered_guided_start): Call
256         gomp_work_share_init_done after gomp_loop_init.  Lock ws->lock.
257         (gomp_parallel_loop_start): Call gomp_new_team instead of
258         gomp_new_work_share.  Call gomp_loop_init on &team->work_shares[0].
259         Adjust gomp_team_start caller.  Pass 0 as second argument to
260         gomp_resolve_num_threads.
261         (gomp_loop_init): For GFS_DYNAMIC, multiply ws->chunk_size by incr.
262         If adding ws->chunk_size nthreads + 1 times after end won't
263         overflow, set ws->mode to 1.
264         * libgomp_g.h (GOMP_loop_ull_static_start, GOMP_loop_ull_dynamic_start,
265         GOMP_loop_ull_guided_start, GOMP_loop_ull_runtime_start,
266         GOMP_loop_ull_ordered_static_start,
267         GOMP_loop_ull_ordered_dynamic_start,
268         GOMP_loop_ull_ordered_guided_start,
269         GOMP_loop_ull_ordered_runtime_start, GOMP_loop_ull_static_next,
270         GOMP_loop_ull_dynamic_next, GOMP_loop_ull_guided_next,
271         GOMP_loop_ull_runtime_next, GOMP_loop_ull_ordered_static_next,
272         GOMP_loop_ull_ordered_dynamic_next, GOMP_loop_ull_ordered_guided_next,
273         GOMP_loop_ull_ordered_runtime_next, GOMP_task, GOMP_taskwait): New
274         prototypes.
275         * libgomp.map: Export lock routines also @@OMP_2.0.
276         (GOMP_loop_ordered_dynamic_first,
277         GOMP_loop_ordered_guided_first, GOMP_loop_ordered_runtime_first,
278         GOMP_loop_ordered_static_first): Remove.
279         (GOMP_loop_ull_dynamic_next, GOMP_loop_ull_dynamic_start,
280         GOMP_loop_ull_guided_next, GOMP_loop_ull_guided_start,
281         GOMP_loop_ull_ordered_dynamic_next,
282         GOMP_loop_ull_ordered_dynamic_start,
283         GOMP_loop_ull_ordered_guided_next,
284         GOMP_loop_ull_ordered_guided_start,
285         GOMP_loop_ull_ordered_runtime_next,
286         GOMP_loop_ull_ordered_runtime_start,
287         GOMP_loop_ull_ordered_static_next,
288         GOMP_loop_ull_ordered_static_start,
289         GOMP_loop_ull_runtime_next, GOMP_loop_ull_runtime_start,
290         GOMP_loop_ull_static_next, GOMP_loop_ull_static_start,
291         GOMP_task, GOMP_taskwait): Export @@GOMP_2.0.
292         (omp_set_schedule, omp_get_schedule,
293         omp_get_thread_limit, omp_set_max_active_levels,
294         omp_get_max_active_levels, omp_get_level,
295         omp_get_ancestor_thread_num, omp_get_team_size, omp_get_active_level,
296         omp_set_schedule_, omp_set_schedule_8_,
297         omp_get_schedule_, omp_get_schedule_8_, omp_get_thread_limit_,
298         omp_set_max_active_levels_, omp_set_max_active_levels_8_,
299         omp_get_max_active_levels_, omp_get_level_,
300         omp_get_ancestor_thread_num_, omp_get_ancestor_thread_num_8_,
301         omp_get_team_size_, omp_get_team_size_8_, omp_get_active_level_):
302         New exports @@OMP_3.0.
303         * omp.h.in (omp_sched_t): New type.
304         (omp_set_schedule, omp_get_schedule, omp_get_thread_limit,
305         omp_set_max_active_levels, omp_get_max_active_levels,
306         omp_get_level, omp_get_ancestor_thread_num, omp_get_team_size,
307         omp_get_active_level): New prototypes.
308         * env.c (gomp_spin_count_var, gomp_throttled_spin_count_var,
309         gomp_available_cpus, gomp_managed_threads, gomp_max_active_levels_var,
310         gomp_thread_limit_var, gomp_remaining_threads_count,
311         gomp_remaining_threads_lock): New variables.
312         (parse_spincount): New function.
313         (initialize_env): Call gomp_init_num_threads unconditionally.
314         Initialize gomp_available_cpus.  Call parse_spincount,
315         initialize gomp_{,throttled_}spin_count_var
316         depending on presence and value of OMP_WAIT_POLICY and
317         GOMP_SPINCOUNT env vars.  Handle GOMP_BLOCKTIME env var.
318         Handle OMP_WAIT_POLICY, OMP_MAX_ACTIVE_LEVELS,
319         OMP_THREAD_LIMIT, OMP_STACKSIZE env vars.  Handle unit specification
320         for GOMP_STACKSIZE.  Initialize gomp_remaining_threads_count and
321         gomp_remaining_threads_lock if needed.  Use gomp_global_icv.
322         (gomp_nthreads_var, gomp_dyn_var, gomp_nest_var,
323         gomp_run_sched_var, gomp_run_sched_chunk): Remove.
324         (gomp_global_icv): New.
325         (parse_schedule): Use it.  Parse "auto".
326         (omp_set_num_threads): Use gomp_icv.
327         (omp_set_dynamic, omp_get_dynamic, omp_set_nested, omp_get_nested):
328         Likewise.
329         (omp_get_max_threads): Move from parallel.c.
330         (omp_set_schedule, omp_get_schedule, omp_get_thread_limit,
331         omp_set_max_active_levels, omp_get_max_active_levels): New functions,
332         add ialias.
333         (parse_stacksize, parse_wait_policy): New functions.
334         * fortran.c: Rewrite lock wrappers, if symbol versioning provide
335         both wrappers for compatibility and new locks.
336         (omp_set_schedule, omp_get_schedule,
337         omp_get_thread_limit, omp_set_max_active_levels,
338         omp_get_max_active_levels, omp_get_level,
339         omp_get_ancestor_thread_num, omp_get_team_size,
340         omp_get_active_level): New ialias_redirect.
341         (omp_set_schedule_, omp_set_schedule_8_,
342         omp_get_schedule_, omp_get_schedule_8_, omp_get_thread_limit_,
343         omp_set_max_active_levels_, omp_set_max_active_levels_8_,
344         omp_get_max_active_levels_, omp_get_level_,
345         omp_get_ancestor_thread_num_, omp_get_ancestor_thread_num_8_,
346         omp_get_team_size_, omp_get_team_size_8_, omp_get_active_level_):
347         New functions.
348         * parallel.c: Include limits.h.
349         (gomp_resolve_num_threads): Add count argument.  Rewritten.
350         (GOMP_parallel_start): Call gomp_new_team and pass that as last
351         argument to gomp_team_start.  Pass 0 as second argument to
352         gomp_resolve_num_threads.
353         (GOMP_parallel_end): Decrease gomp_remaining_threads_count
354         if gomp_thread_limit_var != ULONG_MAX.
355         (omp_in_parallel): Implement using ts.active_level.
356         (omp_get_max_threads): Move to env.c.
357         (omp_get_level, omp_get_ancestor_thread_num,
358         omp_get_team_size, omp_get_active_level): New functions,
359         add ialias.
360         * sections.c (GOMP_sections_start): Call gomp_work_share_init_done
361         after gomp_sections_init.  If HAVE_SYNC_BUILTINS, call
362         gomp_iter_dynamic_next instead of the _locked variant and don't take
363         lock around it, otherwise acquire it before calling
364         gomp_iter_dynamic_next_locked.
365         (GOMP_sections_next): If HAVE_SYNC_BUILTINS, call
366         gomp_iter_dynamic_next instead of the _locked variant and don't take
367         lock around it.
368         (GOMP_parallel_sections_start): Call gomp_new_team instead of
369         gomp_new_work_share.  Call gomp_sections_init on &team->work_shares[0].
370         Adjust gomp_team_start caller.  Pass count as second argument to
371         gomp_resolve_num_threads, don't adjust num_threads after the call.
372         Use gomp_icv.
373         * iter.c (gomp_iter_dynamic_next_locked): Don't multiply
374         ws->chunk_size by incr.
375         (gomp_iter_dynamic_next): Likewise.  If ws->mode, use more efficient
376         code.
377         * libgomp_f.h.in (omp_lock_25_arg_t, omp_nest_lock_25_arg_t): New
378         types.
379         (omp_lock_25_arg, omp_nest_lock_25_arg): New macros.
380         (omp_check_defines): Check even the compat defines.
381         * config/linux/ptrlock.c: New file.
382         * config/linux/ptrlock.h: New file.
383         * config/linux/wait.h: New file.
384         * config/posix/ptrlock.c: New file.
385         * config/posix/ptrlock.h: New file.
386         * config/linux/bar.h (gomp_team_barrier_wait,
387         gomp_team_barrier_wait_end, gomp_team_barrier_wake): New prototypes.
388         (gomp_team_barrier_set_task_pending,
389         gomp_team_barrier_clear_task_pending,
390         gomp_team_barrier_set_waiting_for_tasks,
391         gomp_team_barrier_waiting_for_tasks,
392         gomp_team_barrier_done): New inlines.
393         (gomp_barrier_t): Rewritten.
394         (gomp_barrier_state_t): New typedef.
395         (gomp_barrier_init, gomp_barrier_reinit, gomp_barrier_destroy,
396         gomp_barrier_wait_start): Rewritten.
397         (gomp_barrier_wait_end): Change second argument to
398         gomp_barrier_state_t.
399         (gomp_barrier_last_thread, gomp_barrier_wait_last): New static
400         inlines.
401         * config/linux/bar.c: Include wait.h instead of libgomp.h and
402         futex.h.
403         (gomp_barrier_wait_end): Rewritten.
404         (gomp_team_barrier_wait, gomp_team_barrier_wait_end,
405         gomp_team_barrier_wake, gomp_barrier_wait_last): New functions.
406         * config/posix/bar.h (gomp_barrier_t): Add generation field.
407         (gomp_barrier_state_t): New typedef.
408         (gomp_team_barrier_wait,
409         gomp_team_barrier_wait_end, gomp_team_barrier_wake): New prototypes.
410         (gomp_barrier_wait_start): Or all but low 2 bits from generation
411         into the return value.  Return gomp_barrier_state_t.
412         (gomp_team_barrier_set_task_pending,
413         gomp_team_barrier_clear_task_pending,
414         gomp_team_barrier_set_waiting_for_tasks,
415         gomp_team_barrier_waiting_for_tasks,
416         gomp_team_barrier_done): New inlines.
417         (gomp_barrier_wait_end): Change second argument to
418         gomp_barrier_state_t.
419         (gomp_barrier_last_thread, gomp_barrier_wait_last): New static
420         inlines.
421         * config/posix/bar.c (gomp_barrier_init): Clear generation field.
422         (gomp_barrier_wait_end): Change second argument to
423         gomp_barrier_state_t. 
424         (gomp_team_barrier_wait, gomp_team_barrier_wait_end,
425         gomp_team_barrier_wake): New functions.
426         * config/linux/mutex.c: Include wait.h instead of libgomp.h and
427         futex.h.
428         (gomp_futex_wake, gomp_futex_wait): New variables.
429         (gomp_mutex_lock_slow): Call do_wait instead of futex_wait.
430         * config/linux/lock.c: Rewrite to make locks task owned,
431         for backwards compatibility provide the old entrypoints
432         if symbol versioning.  Include wait.h instead of libgomp.h and
433         futex.h.
434         (gomp_set_nest_lock_25): Call do_wait instead of futex_wait.
435         * config/posix95/lock.c: Rewrite to make locks task owned,
436         for backwards compatibility provide the old entrypoints
437         if symbol versioning.
438         * config/posix/lock.c: Rewrite to make locks task owned,
439         for backwards compatibility provide the old entrypoints
440         if symbol versioning.
441         * config/linux/proc.c (gomp_init_num_threads): Use gomp_global_icv.
442         (get_num_procs, gomp_dynamic_max_threads): Use gomp_icv.
443         * config/posix/proc.c, config/mingw32/proc.c: Similarly.
444         * config/linux/powerpc/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
445         (sys_futex0): Return error code.
446         (futex_wake, futex_wait): If ENOSYS was returned, clear
447         FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
448         (cpu_relax, atomic_write_barrier): New static inlines.
449         * config/linux/alpha/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
450         (futex_wake, futex_wait): If ENOSYS was returned, clear
451         FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
452         (cpu_relax, atomic_write_barrier): New static inlines.
453         * config/linux/x86/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
454         (sys_futex0): Return error code.
455         (futex_wake, futex_wait): If ENOSYS was returned, clear
456         FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
457         (cpu_relax, atomic_write_barrier): New static inlines.
458         * config/linux/s390/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
459         (sys_futex0): Return error code.
460         (futex_wake, futex_wait): If ENOSYS was returned, clear
461         FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
462         (cpu_relax, atomic_write_barrier): New static inlines.
463         * config/linux/ia64/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
464         (sys_futex0): Return error code.
465         (futex_wake, futex_wait): If ENOSYS was returned, clear
466         FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
467         (cpu_relax, atomic_write_barrier): New static inlines.
468         * config/linux/sparc/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
469         (sys_futex0): Return error code.
470         (futex_wake, futex_wait): If ENOSYS was returned, clear
471         FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
472         (cpu_relax, atomic_write_barrier): New static inlines.
473         * config/linux/sem.c: Include wait.h instead of libgomp.h and
474         futex.h.
475         (gomp_sem_wait_slow): Call do_wait instead of futex_wait.
476         * config/linux/affinity.c: Assume HAVE_SYNC_BUILTINS.
477         * config/linux/omp-lock.h (omp_lock_25_t, omp_nest_lock_25_t): New
478         types.
479         (omp_nest_lock_t): Change owner into void *, add lock field.
480         * config/posix95/omp-lock.h: Include semaphore.h.
481         (omp_lock_25_t, omp_nest_lock_25_t): New types.
482         (omp_lock_t): Use sem_t instead of mutex if semaphores
483         aren't broken.
484         (omp_nest_lock_t): Likewise.  Change owner to void *.
485         * config/posix/omp-lock.h: Include semaphore.h.
486         (omp_lock_25_t, omp_nest_lock_25_t): New types.
487         (omp_lock_t): Use sem_t instead of mutex if semaphores
488         aren't broken.
489         (omp_nest_lock_t): Likewise.  Add owner field.
490
491 2008-06-06  Jakub Jelinek  <jakub@redhat.com>
492
493         * testsuite/libgomp.c/collapse-1.c: New test.
494         * testsuite/libgomp.c/collapse-2.c: New test.
495         * testsuite/libgomp.c/collapse-3.c: New test.
496         * testsuite/libgomp.c/icv-1.c: New test.
497         * testsuite/libgomp.c/icv-2.c: New test.
498         * testsuite/libgomp.c/lib-2.c: New test.
499         * testsuite/libgomp.c/lock-1.c: New test.
500         * testsuite/libgomp.c/lock-2.c: New test.
501         * testsuite/libgomp.c/lock-3.c: New test.
502         * testsuite/libgomp.c/loop-4.c: New test.
503         * testsuite/libgomp.c/loop-5.c: New test.
504         * testsuite/libgomp.c/loop-6.c: New test.
505         * testsuite/libgomp.c/loop-7.c: New test.
506         * testsuite/libgomp.c/loop-8.c: New test.
507         * testsuite/libgomp.c/loop-9.c: New test.
508         * testsuite/libgomp.c/nested-3.c: New test.
509         * testsuite/libgomp.c/nestedfn-6.c: New test.
510         * testsuite/libgomp.c/sort-1.c: New test.
511         * testsuite/libgomp.c/task-1.c: New test.
512         * testsuite/libgomp.c/task-2.c: New test.
513         * testsuite/libgomp.c/task-3.c: New test.
514         * testsuite/libgomp.c/task-4.c: New test.
515         * testsuite/libgomp.c++/c++.exp: Add libstdc++-v3 build includes
516         to C++ testsuite default compiler options.
517         * testsuite/libgomp.c++/collapse-1.C: New test.
518         * testsuite/libgomp.c++/collapse-2.C: New test.
519         * testsuite/libgomp.c++/ctor-10.C: New test.
520         * testsuite/libgomp.c++/for-1.C: New test.
521         * testsuite/libgomp.c++/for-2.C: New test.
522         * testsuite/libgomp.c++/for-3.C: New test.
523         * testsuite/libgomp.c++/for-4.C: New test.
524         * testsuite/libgomp.c++/for-5.C: New test.
525         * testsuite/libgomp.c++/loop-8.C: New test.
526         * testsuite/libgomp.c++/loop-9.C: New test.
527         * testsuite/libgomp.c++/loop-10.C: New test.
528         * testsuite/libgomp.c++/task-1.C: New test.
529         * testsuite/libgomp.c++/task-2.C: New test.
530         * testsuite/libgomp.c++/task-3.C: New test.
531         * testsuite/libgomp.c++/task-4.C: New test.
532         * testsuite/libgomp.c++/task-5.C: New test.
533         * testsuite/libgomp.c++/task-6.C: New test.
534         * testsuite/libgomp.fortran/allocatable1.f90: New test.
535         * testsuite/libgomp.fortran/allocatable2.f90: New test.
536         * testsuite/libgomp.fortran/allocatable3.f90: New test.
537         * testsuite/libgomp.fortran/allocatable4.f90: New test.
538         * testsuite/libgomp.fortran/collapse1.f90: New test.
539         * testsuite/libgomp.fortran/collapse2.f90: New test.
540         * testsuite/libgomp.fortran/collapse3.f90: New test.
541         * testsuite/libgomp.fortran/collapse4.f90: New test.
542         * testsuite/libgomp.fortran/lastprivate1.f90: New test.
543         * testsuite/libgomp.fortran/lastprivate2.f90: New test.
544         * testsuite/libgomp.fortran/lib4.f90: New test.
545         * testsuite/libgomp.fortran/lock-1.f90: New test.
546         * testsuite/libgomp.fortran/lock-2.f90: New test.
547         * testsuite/libgomp.fortran/nested1.f90: New test.
548         * testsuite/libgomp.fortran/nestedfn4.f90: New test.
549         * testsuite/libgomp.fortran/strassen.f90: New test.
550         * testsuite/libgomp.fortran/tabs1.f90: New test.
551         * testsuite/libgomp.fortran/tabs2.f: New test.
552         * testsuite/libgomp.fortran/task1.f90: New test.
553         * testsuite/libgomp.fortran/task2.f90: New test.
554         * testsuite/libgomp.fortran/vla4.f90: Add dg-warning.
555         * testsuite/libgomp.fortran/vla5.f90: Likewise.
556         * testsuite/libgomp.c/pr26943-2.c: Likewise.
557         * testsuite/libgomp.c/pr26943-3.c: Likewise.
558         * testsuite/libgomp.c/pr26943-4.c: Likewise.
559
560 2008-05-23  Jakub Jelinek  <jakub@redhat.com>
561
562         PR c++/36308
563         * testsuite/libgomp.c++/ctor-11.C: New test.
564         * testsuite/libgomp.c++/ctor-12.C: New test.
565
566 2008-05-15  Janis Johnson  <janis187@us.ibm.com>
567
568         * testsuite/lib/libgomp.exp: Load torture-options.exp from gcc lib.
569
570 2008-05-07  Jakub Jelinek  <jakub@redhat.com>
571
572         PR middle-end/36106
573         * testsuite/libgomp.c/atomic-5.c: New test.
574         * testsuite/libgomp.c/atomic-6.c: New test.
575         * testsuite/libgomp.c/autopar-1.c: New test.
576
577 2008-04-21  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
578
579         * acinclude.m4 (LIBGOMP_CHECK_SYNC_BUILTINS)
580         (LIBGOMP_CHECK_ATTRIBUTE_VISIBILITY)
581         (LIBGOMP_CHECK_ATTRIBUTE_DLLEXPORT)
582         (LIBGOMP_CHECK_ATTRIBUTE_ALIAS): Fix cache variable names.
583         * configure: Regenerate.
584         * Makefile.in, testsuite/Makefile.in: Likewise.
585
586 2008-04-18  Paolo Bonzini  <bonzini@gnu.org>
587
588         PR bootstrap/35457
589         * aclocal.m4: Regenerate.
590         * configure: Regenerate.
591
592 2008-03-18  Jakub Jelinek  <jakub@redhat.com>
593
594         PR middle-end/35611
595         * testsuite/libgomp.c/atomic-4.c: New test.
596
597         PR libgomp/35625
598         * iter.c (gomp_iter_guided_next_locked): If q > n, set end to ws->end.
599         (gomp_iter_guided_next): Likewise.
600         * testsuite/libgomp.c/pr35625.c: New test.
601
602 2008-03-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
603
604         * aclocal.m4: Regenerate.
605         * configure: Likewise.
606         * Makefile.in: Likewise.
607         * testsuite/Makefile.in: Likewise.
608
609 2008-03-13  Jakub Jelinek  <jakub@redhat.com>
610
611         PR middle-end/35185
612         * testsuite/libgomp.c++/pr35185.C: New test.
613
614 2008-03-12  Jakub Jelinek  <jakub@redhat.com>
615
616         PR middle-end/35549
617         * testsuite/libgomp.c/pr35549.c: New test.
618
619 2008-03-06  Jakub Jelinek  <jakub@redhat.com>
620
621         * testsuite/libgomp.c/atomic-3.c: New test.
622
623 2008-03-03  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
624
625         PR fortran/33197
626         * testsuite/libgomp.fortran/fortran.exp: Add .f08 and
627         .F08 file suffixes.
628
629 2008-03-03  Peter O'Gorman  <pogma@thewrittenword.com>
630
631         PR libgomp/33131
632         * configure.ac: Add ACX_HEADER_STRING.
633         * env.c: Include strings.h.
634         * aclocal.m4: Regenerate.
635         * config.h.in: Regenerate.
636         * configure: Regenerate.
637         * Makefile.in: Regenerate.
638         * testsuite/Makefile.in: Regenerate.
639
640 2008-02-15  Jakub Jelinek  <jakub@redhat.com>
641
642         PR middle-end/35196
643         * testsuite/libgomp.c/pr35196.c: New test.
644
645         PR middle-end/35130
646         * testsuite/libgomp.fortran/pr35130.f90: New test.
647         * testsuite/libgomp.c/pr35130.c: New test.
648
649 2008-01-25  Jakub Jelinek  <jakub@redhat.com>
650
651         PR middle-end/33880
652         * testsuite/libgomp.c/pr33880.c: New test.
653         * testsuite/libgomp.fortran/pr33880.f90: New test.
654
655 2008-01-24  David Edelsohn  <edelsohn@gnu.org>
656
657         * configure: Regenerate.
658
659 2008-01-08  Jakub Jelinek  <jakub@redhat.com>
660
661         * configure.ac: Move futex checking into ../config/futex.m4.
662         * configure: Rebuilt.
663         * aclocal.m4: Rebuilt.
664         * Makefile.in: Rebuilt.
665
666         * configure.tgt: Rename have_tls to gcc_cv_have_tls to match
667         2007-10-15 ../config/tls.m4 change.
668
669 2007-12-19  Jakub Jelinek  <jakub@redhat.com>
670
671         PR c++/34513
672         * testsuite/libgomp.c/pr34513.c: New test.
673         * testsuite/libgomp.c++/pr34513.C: New test.
674
675 2007-12-17  Jack Howarth  <howarth@bromo.med.uc.edu>
676
677         PR target/32765
678         * testsuite/libgomp.fortran/crayptr2.f90: Move dg-options for darwin.
679
680 2007-12-04  Jakub Jelinek  <jakub@redhat.com>
681
682         * omp.h.in (__GOMP_NOTHROW): Define.  Use it on omp_* prototypes.
683
684 2007-12-03  Jakub Jelinek  <jakub@redhat.com>
685
686         * testsuite/libgomp.c/private-1.c: New test.
687
688 2007-11-29  Andris Pavenis <andris.pavenis@iki.fi>
689             Paolo Bonzini  <bonzini@gnu.org>
690
691         * Makefile.am: Use space as vpath separator.  Use 'vpath %'
692         instead of 'VPATH ='.
693         * Makefile.in: Regenerate.
694
695 2007-11-23  Matthias Klose  <doko@ubuntu.com>
696
697         * configure.ac: Adjust makeinfo version check.
698         * configure: Regenerate.
699
700 2007-11-10  Jakub Jelinek  <jakub@redhat.com>
701
702         PR fortran/34020
703         * testsuite/libgomp.fortran/pr34020.f90: New test.
704
705 2007-11-06  Jakub Jelinek  <jakub@redhat.com>
706
707         PR c++/33894
708         * testsuite/libgomp.c++/atomic-1.C: New test.
709
710 2007-10-25  Jakub Jelinek  <jakub@redhat.com>
711
712         PR libgomp/33275
713         * testsuite/libgomp.fortran/omp_parse3.f90 (test_threadprivate):
714         Make x and y integers rather than (implicit) reals.  Add private (j)
715         clause to the last omp parallel.
716
717 2007-10-15  Maciej W. Rozycki  <macro@linux-mips.org>
718
719         * configure: Regenerate following changes to ../config/tls.m4.
720
721 2007-09-28  Jakub Jelinek  <jakub@redhat.com>
722
723         * testsuite/libgomp.fortran/stack.f90: New test.
724
725 2007-09-10  Danny Smith  <dannysmith@users.sourceforge.net>
726
727         * config/mingw32/proc.c: New file.
728
729 2007-09-05  Uros Bizjak  <ubizjak@gmail.com>
730
731         * testsuite/libgomp.c/atomic-1.c: Include cpuid.h for i386 targets.
732         (main): Use __get_cpuid to get i386 target fetaures.
733         * testsuite/libgomp.c/atomic-2.c: Include cpuid.h for x86_64 targets.
734         (main): Use __get_cpuid to get x86_64 target fetaures.
735
736 2007-08-15  Jack Howarth  <howarth@bromo.med.uc.edu>
737
738         PR target/32765
739         * testsuite/libgomp.fortran/pr32550.f90: Use -static-libgcc on Darwin.
740         * testsuite/libgomp.fortran/crayptr2.f90: Likwise.
741
742 2007-07-12  Jakub Jelinek  <jakub@redhat.com>
743
744         PR fortran/32550
745         * testsuite/libgomp.fortran/pr32550.f90: New test.
746         * testsuite/libgomp.fortran/crayptr2.f90: New test.
747
748 2007-07-05  H.J. Lu  <hongjiu.lu@intel.com>
749
750         * aclocal.m4: Regenerated.
751
752 2007-07-05  Tobias Burnus  <burnus@net-b.de>
753
754         PR fortran/32359
755         * testsuite/libgomp.fortran/pr32359.f90: New.
756
757 2007-07-02  Jakub Jelinek  <jakub@redhat.com>
758
759         PR libgomp/32468
760         * sections.c (GOMP_parallel_sections_start): Only decrease
761         number of threads to COUNT if dyn_var is true.
762         * testsuite/libgomp.c/pr32468.c: New test.
763
764 2007-07-02  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
765
766         PR libgomp/26308
767         * config/posix/lock.c (_XOPEN_SOURCE): Don't define on Tru64 UNIX.
768
769 2007-06-21  Jakub Jelinek  <jakub@redhat.com>
770
771         PR middle-end/32362
772         * testsuite/libgomp.c/pr32362-1.c: New test.
773         * testsuite/libgomp.c/pr32362-2.c: New test.
774         * testsuite/libgomp.c/pr32362-3.c: New test.
775
776 2007-06-07  Jakub Jelinek  <jakub@redhat.com>
777
778         * team.c (gomp_team_start): Fix setting up thread_attr
779         stack size.
780
781 2007-06-02  Paolo Bonzini  <bonzini@gnu.org>
782
783         * configure: Regenerate.
784
785 2007-05-23  Steve Ellcey  <sje@cup.hp.com>
786
787         * Makefile.in: Regenerate.
788         * configure: Regenerate.
789         * aclocal.m4: Regenerate.
790         * testsuite/Makefile.in: Regenerate.
791
792 2007-05-04  Jakub Jelinek  <jakub@redhat.com>
793
794         * config/linux/proc.c: New file.
795
796         PR libgomp/28482
797         * configure.tgt: Don't link with -Wl,-z,nodlopen even on Linux.
798
799 2007-04-19  Daniel Franke  <franke.daniel@gmail.com>
800
801         * libgomp.texi (GOMP_CPU_AFFINITY): Updated.
802
803 2007-04-16  Matthias Klose  <doko@debian.org>
804
805         * configure.tgt (i[456]86-*-linux*): Only add ia32 specific
806         flags if not building with -m64.
807         * testsuite/lib/libgomp-dg.exp (libgomp_init): Don't add -march
808         flag for i?86-*-* targets, if current target matches -m64.
809
810 2007-04-14  Steve Ellcey  <sje@cup.hp.com>
811
812         * Makefile.am: Add -I .. to ACLOCAL_AMFLAGS.
813         * Makefile.in: Regenerate.
814
815 2007-04-07  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
816
817         PR testsuite/31369
818         * testsuite/libgomp.c++/c++.exp: Don't use concat when setting
819         ld_library_path.
820         * testsuite/libgomp.fortran/fortran.exp: Likewise.
821
822 2007-04-04  Jakub Jelinek  <jakub@redhat.com>
823
824         * libgomp.h (gomp_cpu_affinity, gomp_cpu_affinity_len): New extern
825         decls.
826         (gomp_init_affinity, gomp_init_thread_affinity): New prototypes.
827         * env.c (gomp_cpu_affinity, gomp_cpu_affinity_len): New variables.
828         (parse_affinity): New function.
829         (initialize_env): Call it and gomp_init_affinity.
830         * team.c (gomp_team_start): If gomp_cpu_affinity != NULL,
831         create new pthread_attr_t and call gomp_init_thread_affinity
832         on it for each thread before passing the attribute to pthread_create.
833         * config/linux/affinity.c: New file.
834         * config/posix/affinity.c: New file.
835         * configure.ac (HAVE_PTHREAD_AFFINITY_NP): New test.
836         * configure: Rebuilt.
837         * config.h.in: Rebuilt.
838         * Makefile.am (libgomp_la_SOURCES): Add affinity.c.
839         * Makefile.in: Rebuilt.
840
841 2007-03-23  Andreas Tobler  <a.tobler@schweiz.org>
842
843         * testsuite/lib/libgomp.exp (libgomp_init): Add -shared-libgcc for
844         *-*-darwin*.
845         * testsuite/libgomp.c++/c++.exp: Look for shared libstdc++ library
846         and use it if found.
847
848 2007-03-18  Uros Bizjak  <ubizjak@gmail.com>
849
850         * testsuite/config/default.exp: New file.
851         * testsuite/lib/libgomp.exp: New file.
852         * testsuite/lib/libgomp.dg (load_gcc_lib, libgomp_init,
853         libgomp_target_compile, libgomp_option_help, libgomp_option_proc,
854         load_lib *, load_gcc_lib *): Move to libgomp.exp.
855         (libgomp_load): Remove.
856         * testsuite/lib/libgomp.exp (libgomp_init): Compute
857         always_ld_library_path, not ld_library_path.  Set additional_flags
858         to -march=i486 for ilp32 x86_64-*-* and i386-*-* targets.
859         (target_compile): Do not call libgomp_init.  Append lang_library_path
860         and lang_link_flags to options.
861         * testsuite/libgomp.c/c.exp: Set DEFAULT_FLAGS to -O2.  Set
862         ld_library_path from always_ld_library_path.  Set LD_LIBRARY_PATH
863         here.
864         * testsuite/libgomp.c++/c++.exp: Set ld_library_path from
865         always_ld_library_path.  Set LD_LIBRARY_PATH here.
866         * testsuite/libgomp.fortran/fortran.exp: Ditto.
867         * testsuite/libgomp.c/atomic-1.c: Set dg-options to
868         "-O2 -march=pentium" for ilp32 x86 targets. Simplify check for
869         CX8 flag.
870         * testsuite/libgomp.c/atomic-2.c: Set dg-options to "-O2 -mcx16" for
871         lp64 x86 targets. Do not check for SSE3 bit. Do not define bit_SSE3.
872         * testsuite/libgomp.c/pr29947-1.c: Remove default dg-options.
873         * testsuite/libgomp.c/pr29947-1.c: Ditto.
874         * testsuite/libgomp.c/atomic-10.c: Ditto.
875
876 2007-03-21  Jakub Jelinek  <jakub@redhat.com>
877
878         * testsuite/libgomp.fortran/appendix-a/a.22.8.f90: Add
879         dg-final cleanup-modules line.
880         * testsuite/libgomp.fortran/appendix-a/a.40.1.f90: Likewise.
881         * testsuite/libgomp.fortran/appendix-a/a.31.5.f90: Likewise.
882         * testsuite/libgomp.fortran/appendix-a/a.31.4.f90: Likewise.
883         * testsuite/libgomp.fortran/threadprivate2.f90: Likewise.
884         * testsuite/libgomp.fortran/reduction5.f90: Likewise.
885         * testsuite/libgomp.fortran/threadprivate3.f90: Likewise.
886         * testsuite/libgomp.fortran/threadprivate1.f90: Likewise.
887
888 2007-03-18  Andreas Schwab  <schwab@suse.de>
889
890         * acinclude.m4: Adjust regular expression for ld version
891         extraction.
892         * configure: Regenerate.
893
894 2007-03-01  Brooks Moses  <brooks.moses@codesourcery.com>
895
896         * Makefile.am: Add install-pdf target as copied from
897         automake v1.10 rules.
898         * Makefile.in: Regenerate
899
900 2007-02-07  Jakub Jelinek  <jakub@redhat.com>
901
902         PR libgomp/28486
903         * configure: Regenerate.
904
905         PR c++/30703
906         * testsuite/libgomp.c++/pr30703.C: New test.
907
908 2007-02-02  Jakub Jelinek  <jakub@redhat.com>
909
910         Revert:
911         2006-07-05  Eric Christopher  <echristo@apple.com>
912         * configure.ac: Depend addition of -pthread on host OS.
913         * configure: Regenerate.
914
915 2007-01-31  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
916
917         * libgomp.texi: Fix spacing after abbreviations.
918
919 2007-01-31  Daniel Franke <franke.daniel@gmail.com>
920
921         PR libgomp/30546
922         * configure.ac: Add check for makeinfo
923         * Makefile.am: Redefined target libgomp.info, build libgomp.info only
924         if an appropiate version of makeinfo is found.
925         * aclocal.m4: Regenerated.
926         * configure: Regenerated.
927         * Makefile.in: Regenerated.
928         * testsuite/Makefile.in: Regenerated.
929
930 2007-01-29  Daniel Franke <franke.daniel@gmail.com>
931
932         PR libgomp/30540
933         * libgomp.texi: More about implementation-dependent settings.
934
935 2007-01-26  Tobias Burnus  <burnus@net-b.de>
936
937         * testsuite/libgomp.fortran/fortran.exp: Support .f03 extension.
938
939 2007-01-24  Jakub Jelinek  <jakub@redhat.com>
940
941         PR middle-end/30494
942         * testsuite/libgomp.c/pr30494.c: New test.
943
944 2007-01-15  Tom Tromey  <tromey@redhat.com>
945
946         * configure: Rebuilt.
947         * configure.ac: Fixed comment.
948
949 2007-01-14  Daniel Franke  <franke.daniel@gmail.com>
950
951         * libgomp.texi: Document implementation specific default values of
952         environment variables.
953
954 2006-12-21  Daniel Franke  <franke.daniel@gmail.com>
955
956         PR libgomp/28209
957         * libgomp.texi: New file.
958         * configure.ac: Add --enable-generated-files-in-srcdir option.
959         * Makefile.am: Add info, dvi, pdf, html targets. On request, copy
960         files to srcdir.
961         * Makefile.in: Regenerated.
962         * config.h.in: Regenerated.
963         * testsuite/Makefile.in: Regenerated.
964         * NOTES: Removed.
965
966 2006-12-04  Daniel Franke  <franke.daniel@gmail.com>
967
968         PR libgomp/29949
969         * env.c (omp_set_num_threads): Set illegal thread count to 1.
970
971 2006-12-04  Eric Botcazou  <ebotcazou@libertysurf.fr>
972
973         * configure: Regenerate.
974
975 2006-12-04  Jakub Jelinek  <jakub@redhat.com>
976
977         PR libgomp/29947
978         * loop.c (gomp_loop_init): Make parameters signed.  Set ws->end to
979         start if there shouldn't be any loop iterations.
980         (gomp_loop_ordered_static_start): Remove start == end test.
981         * testsuite/libgomp.c/pr29947-1.c: New test.
982         * testsuite/libgomp.c/pr29947-2.c: New test.
983
984 2006-12-02  Eric Botcazou  <ebotcazou@libertysurf.fr>
985
986         * configure.tgt: Force initial-exec TLS model on Linux only.
987
988 2006-11-13  Daniel Jacobowitz  <dan@codesourcery.com>
989
990         * configure: Regenerated.
991
992 2006-11-09  Uros Bizjak  <ubizjak@gmail.com>
993
994         * env.c (parse_schedule): Reject out of range values.
995         (parse_unsigned_long): Reject out of range, negative or zero values.
996
997 2006-10-29  Jakub Jelinek  <jakub@redhat.com>
998
999         PR fortran/29629
1000         * testsuite/libgomp.fortran/pr29629.f90: New test.
1001
1002 2006-10-24  Eric Botcazou  <ebotcazou@libertysurf.fr>
1003
1004         PR libgomp/29494
1005         * configure.tgt: Use posix95 configuration for Solaris 2.5.1 and 2.6.
1006         * config/posix95: New directory.
1007         * config/posix95/omp-lock.h: New file.
1008         * config/posix95/lock.c: Likewise.
1009
1010 2006-10-14  Geoffrey Keating  <geoffk@apple.com>
1011
1012         * aclocal.m4: Regenerate.
1013         * configure: Regenerate.
1014
1015 2006-10-05  Danny Smith  <dannysmith@users.sourceforge.net>
1016
1017         * testsuite/libgomp.c/barrier-1.c: Change timestamp tests from
1018         '<' to '<='.
1019
1020 2006-10-05  Danny Smith  <dannysmith@users.sourceforge.net>
1021
1022         * acinclude.m4 (HAVE_ATTRIBUTE_ALIAS): Remove __USER_LABEL_PREFIX__ from
1023         test.
1024         * configure: Regenerate.
1025         * fortran.c  (ialias_redirect): Add __USER_LABEL_PREFIX__ to alias.
1026
1027 2006-09-26  Jakub Jelinek  <jakub@redhat.com>
1028
1029         PR middle-end/25261
1030         PR middle-end/28790
1031         * testsuite/libgomp.c/nestedfn-4.c: New test.
1032         * testsuite/libgomp.c/nestedfn-5.c: New test.
1033         * testsuite/libgomp.fortran/nestedfn3.f90: New test.
1034
1035         PR fortran/29097
1036         * testsuite/libgomp.fortran/condinc1.f: New test.
1037         * testsuite/libgomp.fortran/condinc2.f: New test.
1038         * testsuite/libgomp.fortran/condinc3.f90: New test.
1039         * testsuite/libgomp.fortran/condinc4.f90: New test.
1040         * testsuite/libgomp.fortran/condinc1.inc: New file.
1041
1042 2006-09-18  Tom Tromey  <tromey@redhat.com>
1043
1044         * configure: Rebuilt.
1045
1046 2006-09-13  Joseph S. Myers  <joseph@codesourcery.com>
1047
1048         PR c/28768
1049         PR preprocessor/14634
1050         * configure.ac (HAVE_CLOCK_GETTIME): Add missing second argument
1051         to AC_DEFINE.
1052         * configure: Regenerate.
1053
1054 2006-09-08  Steven G. Kargl  <kargl@gcc.gnu.org>
1055
1056         * testsuite/libgomp.fortran/reduction3.f90: Change
1057         -2147483648 to -huge(i)-1 to avoid overflow.
1058         * testsuite/libgomp.fortran/reduction4.f90: Change
1059         Z'ffffffff' to not(0) to avoid overflow.
1060
1061 2006-08-26  Joseph S. Myers  <joseph@codesourcery.com>
1062
1063         PR libgomp/25938
1064         * Makefile.am (libsubincludedir): New.
1065         (nodist_include_HEADERS): Rename to nodist_libsubinclude_HEADERS.
1066         * Makefile.in: Regenerate.
1067
1068 2006-08-17  Jakub Jelinek  <jakub@redhat.com>
1069
1070         PR libgomp/28725
1071         * env.c: Include ctype.h.
1072         (parse_schedule, parse_unsigned_long, parse_boolean): Allow
1073         leading and/or trailing whitespace and compare strings case
1074         insensitively.
1075
1076 2006-07-16  Jakub Jelinek  <jakub@redhat.com>
1077
1078         PR fortran/28390
1079         * testsuite/libgomp.fortran/pr28390.f: New test.
1080
1081 2006-07-05  Eric Christopher  <echristo@apple.com>
1082
1083         * configure.ac: Depend addition of -pthread on host OS.
1084         * configure: Regenerate.
1085
1086 2006-06-21  Jakub Jelinek  <jakub@redhat.com>
1087
1088         * critical.c (GOMP_critical_name_start): Fix *pptr initialization
1089         when gomp_mutex_t is larger than pointer and HAVE_SYNC_BUILTINS is
1090         defined.
1091
1092 2006-06-20  Jakub Jelinek  <jakub@redhat.com>
1093
1094         PR libgomp/26175
1095         PR libgomp/26477
1096         * configure.ac: If neither --enable-linux-futex nor
1097         --disable-linux-futex is passed, determine the default by checking
1098         for compiling and/or running against NPTL.  With --enable-linux-futex,
1099         check if SYS_gettid and SYS_futex are defined.
1100         * configure: Rebuilt.
1101
1102 2006-06-14  Richard Henderson  <rth@redhat.com>
1103
1104         PR libgomp/28008
1105         * env.c (initialize_env): Avoid using PTHREAD_STACK_MIN when
1106         undefined.  Use GOMP_STACKSIZE not OMP_STACKSIZE for environment.
1107
1108 2006-06-09  Richard Henderson  <rth@redhat.com>
1109
1110         * env.c (gomp_nthreads_var): Change to unsigned long.
1111         (gomp_run_sched_chunk): Likewise.
1112         (parse_unsigned_long): Rename from parse_num_threads and generalize.
1113         (initialize_env): Initialize gomp_thread_attr.
1114         * libgomp.h (gomp_nthreads_var): Update decl.
1115         (gomp_run_sched_chunk): Likewise.
1116         (gomp_thread_attr): Declare.
1117         * team.c (gomp_thread_attr): Export.
1118         (initialize_team): Don't initialize it.
1119
1120 2006-06-09  Jakub Jelinek  <jakub@redhat.com>
1121
1122         PR fortran/27916
1123         * testsuite/libgomp.fortran/pr27916-1.f90: New test.
1124         * testsuite/libgomp.fortran/pr27916-2.f90: New test.
1125
1126 2006-06-06  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1127
1128         * config/mingw32/time.c: New file.
1129         * configure.tgt: Use it.
1130
1131 2006-05-23  Carlos O'Donell  <carlos@codesourcery.com>
1132
1133         * Makefile.am: Add install-html target. Add install-html to .PHONY
1134         * Makefile.in: Regenerate.
1135
1136 2006-05-22  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1137
1138         PR libgomp/27612
1139         * testsuite/libgomp.c/sections-1.c: Require sync_int_long.
1140         * testsuite/libgomp.c/critical-1.c: Likewise.
1141         * testsuite/libgomp.c/loop-1.c: Likewise.
1142         * testsuite/libgomp.c/loop-2.c: Likewise.
1143         * testsuite/libgomp.c/single-1.c: Likewise.
1144         * testsuite/libgomp.c/ordered-1.c: Likewise.
1145         * testsuite/libgomp.c/ordered-2.c: Likewise.
1146
1147 2006-05-15  Jakub Jelinek  <jakub@redhat.com>
1148
1149         PR middle-end/27416
1150         * libgomp.fortran/pr27416-1.f90: New test.
1151
1152 2006-05-03  Jakub Jelinek  <jakub@redhat.com>
1153
1154         PR fortran/27395
1155         * testsuite/libgomp.fortran/pr27395-1.f90: New test.
1156         * testsuite/libgomp.fortran/pr27395-2.f90: New test.
1157
1158 2006-05-02  Jakub Jelinek  <jakub@redhat.com>
1159
1160         PR c++/26943
1161         * testsuite/libgomp.c/pr26943-1.c: New test.
1162         * testsuite/libgomp.c/pr26943-2.c: New test.
1163         * testsuite/libgomp.c/pr26943-3.c: New test.
1164         * testsuite/libgomp.c/pr26943-4.c: New test.
1165         * testsuite/libgomp.c++/pr27337.C: Remove barrier.
1166         * testsuite/libgomp.c++/pr26943.C: New test.
1167
1168 2006-05-02  Jakub Jelinek  <jakub@redhat.com>
1169
1170         PR middle-end/27337
1171         * testsuite/libgomp.c++/pr27337.C: New test.
1172
1173 2006-04-26  Jakub Jelinek  <jakub@redhat.com>
1174
1175         PR c/26171
1176         * testsuite/libgomp.c/pr26171.c: New test.
1177
1178 2006-04-25  Richard Henderson  <rth@redhat.com>
1179
1180         PR libgomp/25865
1181         * configure.ac: Use GCC_CHECK_TLS.
1182         * acinclude.m4 (LIBGOMP_CHECK_TLS): Remove.
1183         * Makefile.in, aclocal.m4, configure: Regenerate.
1184
1185 2006-04-10  Matthias Klose  <doko@debian.org>
1186
1187         * testsuite/lib/libgomp.exp (libgomp_init): Recognize multilib
1188         directory names containing underscores.
1189
1190 2006-03-21  Jakub Jelinek  <jakub@redhat.com>
1191
1192         PR c++/26691
1193         * testsuite/libgomp.c++/pr26691.C: New test.
1194
1195 2006-03-13  Jakub Jelinek  <jakub@redhat.com>
1196
1197         * testsuite/libgomp.fortran/retval2.f90: New test.
1198
1199 2006-03-09  Diego Novillo  <dnovillo@redhat.com>
1200
1201         * testsuite/libgomp.c++: New directory.
1202
1203 2006-02-25  Shantonu Sen  <ssen@opendarwin.org>
1204
1205         * config/posix/sem.h: Define BROKEN_POSIX_SEMAPHORES functions.
1206         * config/posix/sem.c: Implement the above.
1207
1208 2006-02-25  Andreas Tobler  <a.tobler@schweiz.ch>
1209
1210         * configure.ac (HAVE_BROKEN_POSIX_SEMAPHORES): Check for darwin and
1211         define HAVE_BROKEN_POSIX_SEMAPHORES.
1212         * configure: Rebuilt.
1213         * config.h.in: Rebuilt.
1214
1215 2006-02-17  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1216
1217         PR bootstrap/26161
1218         * configure.ac: Remove AC_CHECK_HEADER for pthread.h. Add comment
1219         for the other pthread check.
1220         * configure: Regenerate.
1221         * config.h.in: Regenerate.
1222
1223 2006-02-15  Jakub Jelinek  <jakub@redhat.com>
1224
1225         PR libgomp/25938
1226         PR libgomp/25984
1227         * Makefile.am (fincludedir): New variable.
1228         (nodist_include_HEADERS): Remove Fortran files.
1229         (nodist_finclude_HEADERS): New variable.
1230         * Makefile.in: Regenerated.
1231
1232 2006-02-13  Jakub Jelinek  <jakub@redhat.com>
1233
1234         * testsuite/libgomp.fortran/vla7.f90: Add -w to options.
1235         Remove tests for returning assumed character length arrays.
1236
1237 2006-02-12  Roger Sayle  <roger@eyesopen.com>
1238             John David Anglin  <dave@hiauly1.hia.nrc.ca>
1239
1240         PR libgomp/25936
1241         * configure.tgt: Link against -lrt for sem_init on HPUX v11 systems.
1242
1243 2006-02-08  Ulrich Weigand  <uweigand@de.ibm.com>
1244
1245         * testsuite/lib/libgomp-dg.exp: Load scanrtl.exp library.
1246
1247 2006-02-07  Eric Botcazou  <ebotcazou@libertysurf.fr>
1248
1249         * testsuite/lib/libgomp-dg.exp (libgomp_init): Compute multilib related
1250         part of LD_LIBRARY_PATH manually.
1251
1252 2006-02-03  H.J. Lu  <hongjiu.lu@intel.com>
1253
1254         PR libgomp/25852
1255         * testsuite/lib/libgomp-dg.exp (blddir): Set it in
1256         libgomp_init.
1257
1258 2005-01-25  Paolo Bonzini  <bonzini@gnu.org>
1259
1260         PR libgomp/25884
1261         * Makefile.am (omp.h, omp_lib.h, omp_lib.f90, libgomp_f.h): Remove.
1262         * configure.ac (PERL): Don't set.
1263         (gstdint.h, omp.h, omp_lib.h, omp_lib.f90, libgomp_f.h): Create here.
1264         (OMP_LOCK_SIZE, OMP_LOCK_ALIGN, OMP_LOCK_KIND, OMP_NEST_LOCK_SIZE,
1265         OMP_NEST_LOCK_ALIGN, OMP_NEST_LOCK_KIND): New substitutions.
1266         * omp.h.in: Wrap the new configure substitutions with @ characters.
1267         * omp_lib.h.in, omp_lib.f90.in, libgomp_f.h.in: Likewise.
1268         * aclocal.m4, configure, Makefile.in: Regenerate.
1269         * mkomp_h.pl: Delete.
1270
1271 2005-01-24  Paolo Bonzini  <bonzini@gnu.org>
1272
1273         PR libgomp/25259
1274         * configure.ac: Use GCC_HEADER_STDINT.
1275         * libgomp.h: Include gstdint.h.
1276         * libgomp_f.h.in: Don't include stdint.h or inttypes.h.
1277         * configure, Makefile.in, testsuite/Makefile.in, aclocal.m4: Rebuild.
1278
1279 2006-01-24  Richard Henderson  <rth@redhat.com>
1280
1281         PR libgomp/25942
1282         * configure.ac: Add AM_MAINTAINER_MODE.
1283         * Makefile.in, aclocal.m4, configure, testsuite/Makefile.in: Rebuild.
1284
1285 2006-01-24  Diego Novillo  <dnovillo@redhat.com>
1286
1287         * Makefile.in: Regenerate.
1288         * testsuite/Makefile.in: Regenerate.
1289         * aclocal.m4: Regenerate.
1290
1291 2006-01-23  Andreas Tobler  <a.tobler@schweiz.ch>
1292
1293         * config/posix/proc.c: Conditional include of sys/loadavg.h for
1294         Solaris.
1295         * configure.ac: Add check for loadavg.h.
1296         (link_gomp): Adjust comment.
1297         * configure: Regenerate.
1298         * config.h.in: Regenerate.
1299
1300 2006-01-21  Steve Ellcey  <sje@cup.hp.com>
1301
1302         PR libgomp/25877
1303         * configure.ac: Remove check for alloca.h.
1304         * configure: Regenerate.
1305         * config.h.in: Regenerate.
1306         * libgomp.h: define gomp_alloca to be __builtin_alloca.
1307         * team.c: Remove use of alloca.h.
1308         Call gomp_alloca instead of alloca.
1309
1310 2006-01-20  Steve Ellcey  <sje@cup.hp.com>
1311
1312         PR libgomp/25877
1313         * team.c: Add include of alloca.h.
1314         * configure.ac: Add check for alloca.h.
1315         * configure: Regenerate.
1316         * config.h.in: Regenerate.
1317
1318 2006-01-17  Jakub Jelinek  <jakub@redhat.com>
1319
1320         PR fortran/25219
1321         * testsuite/libgomp.fortran/pr25219.f90: New test.
1322
1323 2005-12-05  Uros Bizjak  <uros@kss-loka.si>
1324
1325         * testsuite/libgomp.c/pr24455.c, testsuite/libgomp.c/copyin-1.c,
1326         testsuite/libgomp.c/copyin-2.c, testsuite/libgomp.c/copyin-3.c,
1327         testsuite/libgomp.c++/copyin-1.C, testsuite/libgomp.c++/copyin-2.C,
1328         testsuite/libgomp.c++/ctor-5.C, testsuite/libgomp.c++/ctor-8.C,
1329         testsuite/libgomp.c++/ctor-9.C, testsuite/libgomp.c++/pr24455.C,
1330         testsuite/libgomp.fortran/threadprivate1.f90,
1331         testsuite/libgomp.fortran/threadprivate2.f90,
1332         testsuite/libgomp.fortran/threadprivate3.f90,
1333         testsuite/libgomp.fortran/appendix-a/a.22.7.f9,
1334         testsuite/libgomp.fortran/appendix-a/a.22.8.f9,
1335         testsuite/libgomp.fortran/omp_parse3.f90: Change required
1336         effective-target to TLS runtime.
1337
1338         * testsuite/libgomp.fortran/pr25162.f: Require
1339         effective-target TLS runtime.
1340
1341 2005-12-01  Jakub Jelinek  <jakub@redhat.com>
1342
1343         * testsuite/libgomp.fortran/nestedfn2.f90: New test.
1344         * testsuite/libgomp.c/nestedfn-3.c: New test.
1345
1346 2005-11-30  Jakub Jelinek  <jakub@redhat.com>
1347
1348         PR fortran/25162
1349         * testsuite/libgomp.fortran/pr25162.f: New test.
1350
1351 2005-11-28  Jakub Jelinek  <jakub@redhat.com>
1352
1353         * config/posix/time.c (omp_get_wtime, omp_get_wtick): Fall back to
1354         CLOCK_REALTIME if clock_* (CLOCK_MONOTONIC, &ts) call failed.
1355
1356 2005-11-25  Jakub Jelinek  <jakub@redhat.com>
1357
1358         * alloc.c, barrier.c, critical.c, env.c, error.c, fortran.c, iter.c,
1359         libgomp.h, libgomp_f.h.in, libgomp_g.h, loop.c, mkomp_h.pl, omp.h.in,
1360         omp_lib.f90.in, omp_lib.h.in, ordered.c, parallel.c, sections.c,
1361         single.c, team.c, work.c, config/linux/alpha/futex.h,
1362         config/linux/bar.c, config/linux/bar.h, config/linux/ia64/futex.h,
1363         config/linux/lock.c, config/linux/mutex.c, config/linux/mutex.h,
1364         config/linux/powerpc/futex.h, config/linux/s390/futex.h,
1365         config/linux/sem.c, config/linux/sem.h, config/linux/sparc/futex.h,
1366         config/linux/x86/futex.h, config/posix/bar.c, config/posix/bar.h,
1367         config/posix/lock.c, config/posix/mutex.h, config/posix/proc.c,
1368         config/posix/sem.c, config/posix/sem.h, config/posix/time.c: Update
1369         FSF address.
1370
1371 2005-11-18  Jakub Jelinek  <jakub@redhat.com>
1372
1373         * Makefile.am: Move libgomp_f.h from nodist_include_HEADERS
1374         to nodist_noinst_HEADERS.
1375         * Makefile.in: Rebuilt.
1376
1377         * config/posix/omp-lock.h (omp_nest_lock_t): Change into struct,
1378         add integer count field.
1379         * config/posix/lock.c (omp_destroy_nest_lock): Adjust for
1380         omp_nest_lock_t type change.
1381         (omp_init_nest_lock): Likewise.  Initialize count to 0.
1382         (omp_set_nest_lock): Adjust for omp_nest_lock_t type change.
1383         Increment count.
1384         (omp_unset_nest_lock): Adjust for omp_nest_lock_t type change.
1385         Decrement count.
1386         (omp_test_nest_lock): Adjust for omp_nest_lock_t type change.
1387         Increment count if successful and return the new nesting level.
1388         * config/linux/lock.c (omp_test_nest_lock): Return new nesting level.
1389         * omp_lib.f90.in (omp_test_lock): Fix LOCK argument type.
1390         * testsuite/libgomp.c/lib-1.c: New test.
1391         * testsuite/libgomp.fortran/lib1.f90: New test.
1392         * testsuite/libgomp.fortran/lib2.f: New test.
1393         * testsuite/libgomp.fortran/lib3.f: New test.
1394
1395 2005-11-17  Richard Henderson  <rth@redhat.com>
1396
1397         PR 24845
1398         * Makefile.am (nodist_toolexeclib_HEADERS): New.
1399         * configure.ac (link_gomp): New.  Substitute it.
1400         (AC_CONFIG_FILES): Add libgomp.spec.
1401         * libgomp.spec.in: New file.
1402         * Makefile.in, testsuite/Makefile.in, configure: Rebuild.
1403         * testsuite/lib/libgomp-dg.exp: Add -B${blddir}/ to flags.
1404
1405 2005-11-18  Jakub Jelinek  <jakub@redhat.com>
1406
1407         * testsuite/libgomp.fortran/reduction1.f90: Adjust for
1408         reduction(-:var) behaving the same as reduction(+:var).
1409         * testsuite/libgomp.c/reduction-4.c: New test.
1410
1411 2005-11-15  Uros Bizjak  <uros@kss-loka.si>
1412
1413         * testsuite/libgomp.c/pr24455-1.c, testsuite/libgomp.c/pr24455.c,
1414         testsuite/libgomp.c/copyin-1.c, testsuite/libgomp.c/copyin-2.c,
1415         testsuite/libgomp.c/copyin-3.c,
1416         testsuite/libgomp.c++/copyin-1.C, testsuite/libgomp.c++/copyin-2.C,
1417         testsuite/libgomp.c++/ctor-5.C, testsuite/libgomp.c++/ctor-8.C,
1418         testsuite/libgomp.c++/ctor-9.C, testsuite/libgomp.c++/pr24455-1.C,
1419         testsuite/libgomp.c++/pr24455.C,
1420         testsuite/libgomp.fortran/threadprivate1.f90,
1421         testsuite/libgomp.fortran/threadprivate2.f90,
1422         testsuite/libgomp.fortran/threadprivate3.f90,
1423         testsuite/libgomp.fortran/appendix-a/a.22.7.f9,
1424         testsuite/libgomp.fortran/appendix-a/a.22.8.f9,
1425         testsuite/libgomp.fortran/omp_parse3.f90: Require
1426         effective-target TLS.
1427
1428 2005-11-14  Diego Novillo  <dnovillo@redhat.com>
1429
1430         * HEADER: Remove.
1431
1432 2005-11-13  Jakub Jelinek  <jakub@redhat.com>
1433
1434         PR libgomp/24797
1435         * team.c (initialize_team): Pass NULL rather than free as
1436         pthread_key_create destructor.  Initialize thread specific data
1437         pointer in initial thread to a static local variable rather than
1438         malloced memory.
1439
1440 2005-11-11  Uros Bizjak  <uros@kss-loka.si>
1441
1442         * testsuite/lib/libgomp-dg.exp: Locate libgcc.a and append
1443         its location to ld_library_path.
1444
1445 2005-11-10  Diego Novillo  <dnovillo@redhat.com>
1446
1447         * testsuite/libgomp.c/c.exp: Rename from dg.exp.
1448
1449 2005-11-10  Diego Novillo  <dnovillo@redhat.com>
1450
1451         * testsuite/libgomp.c: Rename from libgomp.dg.
1452
1453 2005-11-09  Diego Novillo  <dnovillo@redhat.com>
1454
1455         * testsuite/libgomp.c++/pr24455.C: Add copyin clause for
1456         threadprivate variable 'i'.
1457
1458 2005-11-09  Jakub Jelinek  <jakub@redhat.com>
1459
1460         * config/linux/s390/futex.h: New file.
1461         * configure.tgt: Use it.
1462
1463         * testsuite/libgomp.fortran/omp_parse4.f90: Move n initialization
1464         before the parallel.
1465
1466 2005-11-08  Jakub Jelinek  <jakub@redhat.com>
1467
1468         PR c++/24734
1469         * testsuite/libgomp.c++/master-1.C: New test.
1470
1471 2005-11-07  Jakub Jelinek  <jakub@redhat.com>
1472
1473         * testsuite/libgomp.dg/copyin-3.c: New test.
1474
1475 2005-11-07  Jakub Jelinek  <jakub@redhat.com>
1476
1477         * testsuite/libgomp.fortran/retval1.f90: New test.
1478         * testsuite/libgomp.fortran/vla7.f90: New test.
1479
1480 2005-11-06  Jakub Jelinek  <jakub@redhat.com>
1481
1482         * testsuite/libgomp.fortran/vla2.f90: New test.
1483         * testsuite/libgomp.fortran/vla3.f90: New test.
1484         * testsuite/libgomp.fortran/vla4.f90: New test.
1485         * testsuite/libgomp.fortran/vla5.f90: New test.
1486         * testsuite/libgomp.fortran/vla6.f90: New test.
1487
1488 2005-11-01  Jakub Jelinek  <jakub@redhat.com>
1489
1490         * config/linux/sparc/futex.h: New file.
1491         * configure.tgt: Use it.
1492         * testsuite/lib/libgomp-dg.exp: Use -mcpu=v9 for sparc testing.
1493
1494         * critical.c: Include stdlib.h.
1495         * acinclude.m4 (LIBGOMP_CHECK_SYNC_BUILTINS): Avoid warnings about
1496         ignoring return value.
1497         * configure.ac: Don't put -Wc,-pthread into XCFLAGS until after
1498         LIBGOMP_CHECK_SYNC_BUILTINS check.
1499         * configure: Rebuilt.
1500
1501 2005-10-31  Jakub Jelinek  <jakub@redhat.com>
1502
1503         * testsuite/libgomp.fortran/vla1.f90: New test.
1504
1505 2005-10-31  Richard Henderson  <rth@redhat.com>
1506
1507         * testsuite/libgomp.fortran/character2.f90: Fix race condition
1508         setting 's' in different threads.
1509
1510 2005-10-31  Jakub Jelinek  <jakub@redhat.com>
1511
1512         * libgomp.h (attribute_hidden, ialias): Define.
1513         * config/posix/proc.c (omp_get_num_procs): Add ialias.
1514         * config/posix/time.c (omp_get_wtime, omp_get_wtick): Likewise.
1515         * config/posix/lock.c (omp_init_lock, omp_init_nest_lock,
1516         omp_destroy_lock, omp_destroy_nest_lock, omp_set_lock,
1517         omp_set_nest_lock, omp_unset_lock, omp_unset_nest_lock,
1518         omp_test_lock, omp_test_nest_lock): Likewise.
1519         * config/linux/lock.c (omp_init_lock, omp_init_nest_lock,
1520         omp_destroy_lock, omp_destroy_nest_lock, omp_set_lock,
1521         omp_set_nest_lock, omp_unset_lock, omp_unset_nest_lock,
1522         omp_test_lock, omp_test_nest_lock): Likewise.
1523         * env.c (omp_set_dynamic, omp_set_nested, omp_set_num_threads,
1524         omp_get_dynamic, omp_get_nested): Likewise.
1525         * parallel.c (omp_get_num_threads, omp_get_max_threads,
1526         omp_get_thread_num, omp_in_parallel): Likewise.
1527         * fortran.c (ialias_redirect): Define.
1528         (omp_init_lock, omp_init_nest_lock, omp_destroy_lock,
1529         omp_destroy_nest_lock, omp_set_lock, omp_set_nest_lock,
1530         omp_unset_lock, omp_unset_nest_lock, omp_test_lock,
1531         omp_test_nest_lock, omp_set_dynamic, omp_set_nested,
1532         omp_set_num_threads, omp_get_dynamic, omp_get_nested,
1533         omp_in_parallel, omp_get_max_threads, omp_get_num_procs,
1534         omp_get_num_threads, omp_get_thread_num, omp_get_wtick,
1535         omp_get_wtime): Add ialias_redirect.
1536
1537 2005-10-30  Jakub Jelinek  <jakub@redhat.com>
1538
1539         * fortran.c: Include stdlib.h.
1540
1541 2005-10-29  Jakub Jelinek  <jakub@redhat.com>
1542
1543         * Makefile.am (env.o, env.lo): Depend on libgomp_f.h.
1544         * Makefile.in: Regenerated.
1545
1546 2005-10-28  Jakub Jelinek  <jakub@redhat.com>
1547
1548         * mkomp_h.pl: Remove all -Wc, option prefixes in $COMPILE.
1549         * libgomp_f.h.in (omp_check_defines): New function.
1550         * env.c: Include libgomp_f.h.
1551         (initialize_env): Call omp_check_defines.
1552
1553         * testsuite/libgomp.dg/copyin-2.c: New test.
1554         * testsuite/libgomp.c++/copyin-2.C: New test.
1555         * testsuite/libgomp.fortran/threadprivate3.f90: New test.
1556
1557         * testsuite/libgomp.fortran/threadprivate2.f90: New test.
1558         * testsuite/libgomp.fortran/sharing2.f90: New test.
1559
1560         * testsuite/libgomp.dg/copyin-1.c: New test.
1561         * testsuite/libgomp.c++/copyin-1.C: New test.
1562
1563 2005-10-26  Jakub Jelinek  <jakub@redhat.com>
1564
1565         * testsuite/libgomp.fortran/crayptr1.f90: New test.
1566
1567         * testsuite/libgomp.fortran/workshare1.f90: New test.
1568
1569         * libgomp.fortran/appendix-a/a.28.5.f90: Change into compile
1570         only test.
1571         * libgomp.fortran/sharing1.f90: New test.
1572
1573 2005-10-24  Jakub Jelinek  <jakub@redhat.com>
1574
1575         PR c++/24502
1576         * testsuite/libgomp.c++/loop-7.C: New test.
1577
1578         * testsuite/libgomp.dg/nestedfn-2.c: New test.
1579
1580         * testsuite/libgomp.dg/nestedfn-1.c: New test.
1581         * testsuite/libgomp.fortran/reduction6.f90: New test.
1582         * testsuite/libgomp.fortran/nestedfn1.f90: New test.
1583
1584 2005-10-23  Richard Henderson  <rth@redhat.com>
1585
1586         * testsuite/libgomp.c++/ctor-1.C: New.
1587         * testsuite/libgomp.c++/ctor-2.C: New.
1588         * testsuite/libgomp.c++/ctor-3.C: New.
1589         * testsuite/libgomp.c++/ctor-4.C: New.
1590         * testsuite/libgomp.c++/ctor-5.C: New.
1591         * testsuite/libgomp.c++/ctor-6.C: New.
1592         * testsuite/libgomp.c++/ctor-7.C: New.
1593         * testsuite/libgomp.c++/ctor-8.C: New.
1594         * testsuite/libgomp.c++/ctor-9.C: New.
1595
1596 2005-10-21  Diego Novillo  <dnovillo@redhat.com>
1597
1598         PR 24455
1599         * testsuite/libgomp.c++/pr24455-1.C: New test.
1600         * testsuite/libgomp.c++/pr24455.C: New test.
1601         * testsuite/libgomp.dg/pr24455-1.c: New test.
1602         * testsuite/libgomp.dg/pr24455.c: New test.
1603
1604 2005-10-20  Richard Henderson  <rth@redhat.com>
1605
1606         * testsuite/libgomp.c++/loop-6.C: New.
1607         * testsuite/libgomp.dg/loop-3.c: New.
1608
1609 2005-10-20  Jakub Jelinek  <jakub@redhat.com>
1610
1611         * testsuite/libgomp.fortran/jacobi.f: Don't make i and j
1612         explicitly private.
1613         * testsuite/libgomp.fortran/omp_parse1.f90 (test_do): Make i
1614         explicitly shared.
1615
1616 2005-10-19  Diego Novillo  <dnovillo@redhat.com>
1617
1618         * testsuite/libgomp.fortran/jacobi.f: New test.
1619
1620 2005-10-19  Richard Henderson  <rth@redhat.com>
1621
1622         * configure.tgt (i?86-linux): Default to with_arch instead of
1623         CFLAGS.  Add -mtune to match target_cpu.
1624         (x86_64-linux): Tune to i686.
1625
1626         * fortran.c (omp_test_nest_lock_): Fix typo.
1627
1628 2005-10-19  Jakub Jelinek  <jakub@redhat.com>
1629
1630         * ordered.c (gomp_ordered_first, gomp_ordered_last, gomp_ordered_next,
1631         gomp_ordered_sync): Do nothing if team->nthreads == 1.
1632         * testsuite/libgomp.dg/ordered-3.c: New test.
1633
1634         * testsuite/libgomp.dg/appendix-a/a.18.1.c: Remove unconditional abort.
1635         Remove volatile keyword.
1636
1637         * testsuite/libgomp.fortran/appendix-a/a.19.1.f90: Reorder variables
1638         in COMMON block to avoid warnings on 64-bit targets.
1639
1640 2005-10-18  Diego Novillo  <dnovillo@redhat.com>
1641
1642         * testsuite/libgomp.dg/shared-3.c: New test.
1643
1644 2005-10-18  Jakub Jelinek  <jakub@redhat.com>
1645
1646         * testsuite/libgomp.fortran/appendix-a/a.31.3.f90: Removed.
1647         * testsuite/libgomp.fortran/reduction5.f90: New test.
1648
1649 2005-10-18  Jakub Jelinek  <jakub@redhat.com>
1650
1651         * testsuite/libgomp.fortran/appendix-a/a.40.1.f90: Add -ffixed-form to
1652         dg-options.
1653         * testsuite/libgomp.fortran/appendix-a/a.18.1.f90: Likewise.  Enable
1654         flush loop now that __sync_synchronize has proper memory barrier.
1655         * testsuite/libgomp.fortran/appendix-a/a.3.1.f90: Fix a typo.
1656         Add -ffixed-form to dg-options.
1657
1658 2005-10-17  Diego Novillo  <dnovillo@redhat.com>
1659
1660         * testsuite/libgomp.fortran/fortran.exp: Also gather tests
1661         from subdirectories.
1662         * testsuite/libgomp.fortran/appendix-a/a.15.1.f90: New test.
1663         * testsuite/libgomp.fortran/appendix-a/a.16.1.f90: New test.
1664         * testsuite/libgomp.fortran/appendix-a/a.18.1.f90: New test.
1665         * testsuite/libgomp.fortran/appendix-a/a.19.1.f90: New test.
1666         * testsuite/libgomp.fortran/appendix-a/a.2.1.f90: New test.
1667         * testsuite/libgomp.fortran/appendix-a/a.21.1.f90: New test.
1668         * testsuite/libgomp.fortran/appendix-a/a.22.7.f90: New test.
1669         * testsuite/libgomp.fortran/appendix-a/a.22.8.f90: New test.
1670         * testsuite/libgomp.fortran/appendix-a/a.26.1.f90: New test.
1671         * testsuite/libgomp.fortran/appendix-a/a.28.1.f90: New test.
1672         * testsuite/libgomp.fortran/appendix-a/a.28.2.f90: New test.
1673         * testsuite/libgomp.fortran/appendix-a/a.28.3.f90: New test.
1674         * testsuite/libgomp.fortran/appendix-a/a.28.4.f90: New test.
1675         * testsuite/libgomp.fortran/appendix-a/a.28.5.f90: New test.
1676         * testsuite/libgomp.fortran/appendix-a/a.3.1.f90: New test.
1677         * testsuite/libgomp.fortran/appendix-a/a.31.3.f90: New test.
1678         * testsuite/libgomp.fortran/appendix-a/a.31.4.f90: New test.
1679         * testsuite/libgomp.fortran/appendix-a/a.31.5.f90: New test.
1680         * testsuite/libgomp.fortran/appendix-a/a.33.3.f90: New test.
1681         * testsuite/libgomp.fortran/appendix-a/a.38.1.f90: New test.
1682         * testsuite/libgomp.fortran/appendix-a/a.39.1.f90: New test.
1683         * testsuite/libgomp.fortran/appendix-a/a.4.1.f90: New test.
1684         * testsuite/libgomp.fortran/appendix-a/a.40.1.f90: New test.
1685         * testsuite/libgomp.fortran/appendix-a/a.5.1.f90: New test.
1686         * testsuite/libgomp.fortran/appendix-a/a10.1.f90: New test.
1687
1688 2005-10-17  Jakub Jelinek  <jakub@redhat.com>
1689
1690         * testsuite/libgomp.dg/dg.exp: Only unset lang_* if
1691         lang_library_path exists.  Use find instead of glob to gather tests.
1692         * testsuite/libgomp.dg/appendix-a/appendix-a.exp: Removed.
1693
1694 2005-10-17  Diego Novillo  <dnovillo@redhat.com>
1695
1696         * testsuite/libgomp.dg/appendix-a/a.15.1.c: New test.
1697         * testsuite/libgomp.dg/appendix-a/a.16.1.c: New test.
1698         * testsuite/libgomp.dg/appendix-a/a.18.1.c: New test.
1699         * testsuite/libgomp.dg/appendix-a/a.19.1.c: New test.
1700         * testsuite/libgomp.dg/appendix-a/a.2.1.c: New test.
1701         * testsuite/libgomp.dg/appendix-a/a.21.1.c: New test.
1702         * testsuite/libgomp.dg/appendix-a/a.26.1.c: New test.
1703         * testsuite/libgomp.dg/appendix-a/a.29.1.c: New test.
1704         * testsuite/libgomp.dg/appendix-a/a.3.1.c: New test.
1705         * testsuite/libgomp.dg/appendix-a/a.39.1.c: New test.
1706         * testsuite/libgomp.dg/appendix-a/a.4.1.c: New test.
1707         * testsuite/libgomp.dg/appendix-a/a.5.1.c: New test.
1708         * testsuite/libgomp.dg/appendix-a/appendix-a.exp: New file.
1709
1710 2005-10-15  Jakub Jelinek  <jakub@redhat.com>
1711
1712         * testsuite/libgomp.dg/vla-1.c: New test.
1713
1714         * testsuite/libgomp.fortran/reference2.f90: New test.
1715
1716         * testsuite/libgomp.fortran/character2.f90: Remove explicit
1717         declaration of omp_get_thread_num.
1718         * testsuite/libgomp.fortran/threadprivate1.f90: Likewise.  Add
1719         use omp_lib.
1720
1721         * testsuite/libgomp.fortran/reduction1.f90: New test.
1722         * testsuite/libgomp.fortran/reduction2.f90: New test.
1723         * testsuite/libgomp.fortran/reduction3.f90: New test.
1724         * testsuite/libgomp.fortran/reduction4.f90: New test.
1725
1726 2005-10-13  Richard Henderson  <rth@redhat.com>
1727
1728         * Makefile.am (libgomp_la_SOURCES): Add bar.c.
1729         * Makefile.in: Regenerate.
1730         * barrier.c (GOMP_barrier): Use gomp_barrier_wait.
1731         * libgomp.h: Include bar.h.
1732         (struct gomp_barrier): Remove.
1733         (struct gomp_team): Add barrier.  Replace master_barrier with
1734         master_release.  Replace threads with ordered_release.
1735         (struct gomp_thread): Replace barrier with release.
1736         * ordered.c (gomp_ordered_first): Update for ordered_release change.
1737         (gomp_ordered_last, gomp_ordered_next, gomp_ordered_static_init,
1738         gomp_ordered_static_next, gomp_ordered_sync): Likewise.
1739         * single.c (GOMP_single_copy_start): Use gomp_barrier_wait.
1740         (GOMP_single_copy_end): Likewise.
1741         * team.c (gomp_threads_dock): New.
1742         (gomp_barrier_init, gomp_barrier_destroy): Remove.
1743         (gomp_thread_start): Use gomp_barrier_wait.
1744         (new_team, free_team): Update for gomp_team changes.
1745         (gomp_team_start): Use gomp_barrier_wait and gomp_barrier_reinit.
1746         (gomp_team_end): Use gomp_barrier_wait.
1747         (initialize_team): Update for gomp_thread changes.
1748         * work.c (gomp_work_share_end): Use gomp_barrier_wait_start.
1749         (gomp_work_share_end_nowait): Use atomic ops when available.
1750         * config/linux/bar.c, config/linux/bar.h: New files.
1751         * config/posix/bar.c, config/posix/bar.h: New files.
1752
1753 2005-10-13  Jakub Jelinek  <jakub@redhat.com>
1754
1755         * single.c (GOMP_single_copy_end): Don't segfault if team is NULL.
1756         * testsuite/libgomp.dg/single-2.c: New test.
1757
1758         * testsuite/libgomp.dg/dg.exp (lang_library_path, lang_test_file,
1759         lang_link_flags): Unset, so that they aren't inherited from previously
1760         sourced *.exp.
1761
1762         * testsuite/libgomp.fortran/threadprivate1.f90: New test.
1763
1764 2005-10-12  Richard Henderson  <rth@redhat.com>
1765
1766         * testsuite/lib/libgomp-dg.exp: Set blddir at toplevel.
1767         (libgomp_init): Use lang_test_file, lang_library_path, and
1768         lang_link_flags, set by the subdirectory files.  Add -fopenmp here.
1769
1770         * testsuite/libgomp.fortran/fortran.exp (lang_library_path): New.
1771         (lang_test_file, lang_link_flags): New.
1772         (DEFAULT_FFLAGS, ALWAYS_CFLAGS, multilibs, blddir): Remove.
1773
1774         * testsuite/libgomp.c++/c++.exp, testsuite/libgomp.c++/loop-1.C,
1775         testsuite/libgomp.c++/loop-2.C, testsuite/libgomp.c++/loop-3.C,
1776         testsuite/libgomp.c++/loop-4.C, testsuite/libgomp.c++/nested-1.C,
1777         testsuite/libgomp.c++/parallel-1.C,
1778         testsuite/libgomp.c++/reduction-1.C,
1779         testsuite/libgomp.c++/reduction-2.C,
1780         testsuite/libgomp.c++/reduction-3.C,
1781         testsuite/libgomp.c++/sections-1.C, testsuite/libgomp.c++/shared-1.C,
1782         testsuite/libgomp.c++/shared-2.C, testsuite/libgomp.c++/single-1.C,
1783         testsuite/libgomp.c++/single-2.C, testsuite/libgomp.c++/single-3.C:
1784         New files, largely cribbed from the C testsuite.
1785
1786 2005-10-12  Jakub Jelinek  <jakub@redhat.com>
1787
1788         * testsuite/libgomp.fortran/character1.f90: New test.
1789         * testsuite/libgomp.fortran/character2.f90: New test.
1790
1791         * testsuite/libgomp.dg/nested-1.c: New test.
1792         * testsuite/libgomp.dg/nested-2.c: New test.
1793         * testsuite/libgomp.fortran/do1.f90: New test.
1794         * testsuite/libgomp.fortran/do2.f90: New test.
1795
1796         * testsuite/libgomp.fortran/reference1.f90: New test.
1797
1798 2005-10-11  Jakub Jelinek  <jakub@redhat.com>
1799
1800         * testsuite/libgomp.dg/reduction-1.c: New test.
1801         * testsuite/libgomp.dg/reduction-2.c: New test.
1802         * testsuite/libgomp.dg/reduction-3.c: New test.
1803
1804 2005-10-10  Jakub Jelinek  <jakub@redhat.com>
1805
1806         * testsuite/libgomp.dg/atomic-1.c: New test.
1807         * testsuite/libgomp.dg/atomic-2.c: New test.
1808
1809 2005-10-09  Richard Henderson  <rth@redhat.com>
1810
1811         * critical.c (atomic_lock): New.
1812         (initialize_critical): Initialize it.
1813         (GOMP_atomic_start, GOMP_atomic_end): New.
1814         * libgomp.map: Export them.
1815         * libgomp_g.h: Declare them.
1816
1817         * testsuite/libgomp.dg/atomic-10.c: Move from gcc testsuite.
1818
1819 2005-10-02  Richard Henderson  <rth@redhat.com>
1820
1821         * configure.ac: Move save_CFLAGS hack earlier.  Append -Wall/-Werror
1822         to XCFLAGS instead of CFLAGS.
1823
1824 2005-09-30  Richard Henderson  <rth@redhat.com>
1825
1826         * configure.ac: Determine whether -pthread or -lpthread is needed.
1827         * Makefile.am (libgomp_la_LDFLAGS): Remove explicit -lpthread.
1828         * Makefine.in, configure: Rebuild.
1829
1830 2005-09-28  Richard Henderson  <rth@redhat.com>
1831
1832         * testsuite/libgomp.dg/omp-loop03.c: Fix return code.
1833         * testsuite/libgomp.dg/omp-single-3.c: New test.
1834
1835 2005-09-28  Diego Novillo  <dnovillo@redhat.com>
1836
1837         * testsuite/libgomp.dg/omp-single-2.c: New test.
1838         * testsuite/libgomp.dg/shared-2.c: Fix return code.
1839
1840 2005-09-27  Richard Henderson  <rth@redhat.com>
1841
1842         * testsuite/libgomp.dg/omp-loop03.c: Add initial barrier.
1843         * testsuite/libgomp.dg/omp-parallel-for.c: Specify static schedule.
1844
1845 2005-09-27  Jakub Jelinek  <jakub@redhat.com>
1846
1847         * testsuite/libgomp.dg/omp-loop03.c: New test.
1848
1849 2005-09-27  Diego Novillo  <dnovillo@redhat.com>
1850
1851         * testsuite/libgomp.dg/omp-parallel-for.c: New test.
1852
1853 2005-09-27  Diego Novillo  <dnovillo@redhat.com>
1854
1855         * testsuite/libgomp.dg/omp-single-1.c: New test.
1856         * testsuite/libgomp.dg/shared-1.c: Return 0.
1857         Add prototype for abort.
1858         * testsuite/libgomp.dg/shared-2.c: Likewise.
1859
1860 2005-09-26  Jakub Jelinek  <jakub@redhat.com>
1861
1862         * testsuite/libgomp.fortran/omp_parse3.f90: Fix non-conforming
1863         constructs.
1864
1865 2005-09-26  Diego Novillo  <dnovillo@redhat.com>
1866
1867         * testsuite/libgomp.dg/shared-1.c: New test.
1868         * testsuite/libgomp.dg/shared-2.c: New test.
1869
1870 2005-09-24  Richard Henderson  <rth@redhat.com>
1871
1872         * testsuite/libgomp.dg/omp_workshare3.c: Mark dg-error.
1873
1874 2005-09-24  Richard Henderson  <rth@redhat.com>
1875
1876         * iter.c (gomp_iter_static_next): Round up when computing number
1877         of iterations.  Don't bother distributing a remainder equally.
1878
1879         * testsuite/libgomp.dg/omp-loop01.c (main1): Rename from main.
1880         Don't call srand.  Zero b before testing.
1881         (main): New.
1882
1883 2005-09-24  Jakub Jelinek  <jakub@redhat.com>
1884
1885         * testsuite/libgomp.fortran/omp_atomic1.f90: New test.
1886         * testsuite/libgomp.fortran/omp_atomic2.f90: New test.
1887
1888 2005-09-23  Jakub Jelinek  <jakub@redhat.com>
1889
1890         * testsuite/libgomp.fortran/omp_parse1.f90: Add a test for !$omp do
1891         without !$omp end do, followed immediately by subroutine end.
1892
1893 2005-09-23  Diego Novillo  <dnovillo@redhat.com>
1894
1895         * testsuite/libgomp.dg/omp-parallel-if.c: New test.
1896
1897 2005-09-22  Richard Henderson  <rth@redhat.com>
1898
1899         * critical.c (GOMP_critical_name_start): Change argument to void**.
1900         Reuse the pointer space if the mutex fits.
1901         (GOMP_critical_name_end): Likewise.
1902         (initialize_critical): Don't define if GOMP_MUTEX_INIT_0.
1903         * libgomp_g.h (GOMP_critical_name_start): Update decl.
1904         (GOMP_critical_name_end): Likewise.
1905         * config/linux/mutex.h (GOMP_MUTEX_INIT_0): New.
1906         * config/posix/mutex.h (GOMP_MUTEX_INIT_0): New.
1907
1908 2005-09-20  Richard Henderson  <rth@redhat.com>
1909
1910         * critical.c (GOMP_critical_name_start, GOMP_critical_name_end): New.
1911         (create_lock_lock): New.
1912         (initialize_critical): Initialize it.
1913         * libgomp.map (GOMP_critical_name_start, GOMP_critical_name_end): New.
1914         * libgomp_g.h (GOMP_ordered_start, GOMP_ordered_end): Declare.
1915
1916 2005-09-20  Diego Novillo  <dnovillo@redhat.com>
1917
1918         * testsuite/libgom.dg/omp-loop01.c: Include stdio.h.
1919
1920 2005-09-20  Diego Novillo  <dnovillo@redhat.com>
1921
1922         * testsuite/libgomp.dg/omp-loop01.c: New test.
1923         * testsuite/libgomp.dg/omp-loop02.c: New test.
1924
1925 2005-09-20  Jakub Jelinek  <jakub@redhat.com>
1926
1927         * configure.ac (AC_PROG_FC): Add.
1928         (USE_FORTRAN): New automake conditional.
1929         * configure: Rebuilt.
1930         * Makefile.am (libgomp_la_SOURCES): Add fortran.c.
1931         (nodist_include_HEADERS): Add omp_lib.h, omp_lib.f90 and libgomp_f.h.
1932         If USE_FORTRAN, add also omp_lib.mod and omp_lib_kinds.mod.
1933         Add rules to build them.
1934         * Makefile.in: Rebuilt.
1935         * mkomp_h.pl: Compute and replace also OMP_LOCK_KIND and
1936         OMP_NEST_LOCK_KIND.
1937         * libgomp.map: Add Fortran wrappers.
1938         * libgomp_f.h.in: New file.
1939         * omp_lib.h.in: New file.
1940         * omp_lib.f90.in: New file.
1941         * fortran.c: New file.
1942         * testsuite/lib/libgomp-dg.exp: Load a few more .exp files.
1943         Append libgfortran directory to LD_LIBRARY_PATH if it exists.
1944         Add -Lpath_to_libgfortran and -lgfortran -lgfortranbegin if
1945         libgfortran has been built.
1946         * testsuite/libgomp.fortran/fortran.exp: New file.
1947         * testsuite/libgomp.fortran/omp_cond1.f: New test.
1948         * testsuite/libgomp.fortran/omp_cond2.f: New test.
1949         * testsuite/libgomp.fortran/omp_cond3.F90: New test.
1950         * testsuite/libgomp.fortran/omp_cond4.F90: New test.
1951         * testsuite/libgomp.fortran/omp_hello.f: New test.
1952         * testsuite/libgomp.fortran/omp_orphan.f: New test.
1953         * testsuite/libgomp.fortran/omp_parse1.f90: New test.
1954         * testsuite/libgomp.fortran/omp_parse2.f90: New test.
1955         * testsuite/libgomp.fortran/omp_parse3.f90: New test.
1956         * testsuite/libgomp.fortran/omp_parse4.f90: New test.
1957         * testsuite/libgomp.fortran/omp_reduction.f: New test.
1958         * testsuite/libgomp.fortran/omp_workshare1.f: New test.
1959         * testsuite/libgomp.fortran/omp_workshare2.f: New test.
1960
1961 2005-08-30  Richard Henderson  <rth@redhat.com>
1962
1963         * loop.c (GOMP_loop_static_start): Provide fallback wrapper
1964         function for when aliases are not usable.
1965         (GOMP_loop_dynamic_start, GOMP_loop_guided_start,
1966         GOMP_loop_ordered_static_start, GOMP_loop_ordered_dynamic_start,
1967         GOMP_loop_ordered_guided_start, GOMP_loop_static_next,
1968         GOMP_loop_dynamic_next, GOMP_loop_guided_next,
1969         GOMP_loop_ordered_static_next, GOMP_loop_ordered_dynamic_next,
1970         GOMP_loop_ordered_guided_next): Likewise.
1971         * ordered.c (GOMP_ordered_start): Likewise.
1972
1973 2005-08-01  Diego Novillo  <dnovillo@redhat.com>
1974
1975         * testsuite/libgomp.dg/dg.exp: Use -O2 for now.
1976         * testsuite/libgomp.dg/omp_hello.c: Fix return code
1977         * testsuite/libgomp.dg/omp_matvec.c: Likewise.
1978         * testsuite/libgomp.dg/omp_orphan.c: Likewise
1979         * testsuite/libgomp.dg/omp_reduction.c: Likewise
1980         * testsuite/libgomp.dg/omp_workshare1.c: Likewise
1981         * testsuite/libgomp.dg/omp_workshare2.c: Likewise
1982         * testsuite/libgomp.dg/omp_workshare3.c: Likewise
1983         * testsuite/libgomp.dg/omp_workshare4.c: Likewise
1984
1985 2005-07-07  Eric Christopher  <echristo@redhat.com>
1986             Diego Novillo  <dnovillo@redhat.com>
1987
1988         * testsuite/libgomp.dg/dg.exp: Add -fopenmp to DEFAULT_CFLAGS.
1989         * testsuite/libgomp.dg/omp_hello.c: Add standard includes, fix
1990         up code.
1991         * testsuite/libgomp.dg/omp_matvec.c: Ditto.
1992         * testsuite/libgomp.dg/omp_orphan.c: Ditto.
1993         * testsuite/libgomp.dg/omp_reduction.c: Ditto.
1994         * testsuite/libgomp.dg/omp_workshare1.c: Ditto.
1995         * testsuite/libgomp.dg/omp_workshare2.c: Ditto.
1996         * testsuite/libgomp.dg/omp_workshare3.c: Ditto.
1997         * testsuite/libgomp.dg/omp_workshare4.c: Ditto.
1998
1999 2005-06-13  Diego Novillo  <dnovillo@redhat.com>
2000
2001         * TOPLEVEL.patch: Remove.
2002
2003 2005-05-16  Richard Henderson  <rth@redhat.com>
2004
2005         * configure.ac: Test for clock_gettime.
2006         * config.h.in, configure: Rebuild.
2007         * config/posix/time.c: Use recommended TIME_WITH_SYS_TIME pattern.
2008         (omp_get_wtime): Use clock_gettime if available.
2009         (omp_get_wtick): Use clock_getres if available.
2010
2011 2005-05-11  Richard Henderson  <rth@redhat.com>
2012
2013         * config/linux/ia64/futex.h: New file.
2014         * configure.tgt: Use it.
2015
2016         * team.c (gomp_barrier_init, gomp_barrier_destroy): Mark inline.
2017
2018 2005-05-07  Richard Henderson  <rth@redhat.com>
2019
2020         * config/linux/powerpc/futex.h: New file.
2021         * configure.tgt: Use it.
2022
2023         * config/linux/i486/futex.h: Merge ...
2024         * config/linux/x86_64/futex.h: ... into ...
2025         * config/linux/x86/futex.h: ... here.
2026         * configure.tgt: Update to match.
2027
2028 2005-05-06  Richard Henderson  <rth@redhat.com>
2029
2030         * config/linux/alpha/futex.h: Conditionally define SYS_futex.
2031         * config/linux/i486/futex.h: Likewise.
2032         * config/linux/x86_64/futex.h: Likewise.
2033
2034         * config/linux/lock.c: New file.
2035         * config/linux/omp-lock.h: New file.
2036
2037         * critical.c, env.h: Don't include omp.h
2038         * config/posix/lock.c: Include libgomp.h instead of omp.h.
2039         * config/posix/time.c: Likewise.
2040         * config/posix/omp-lock.h: New file.
2041         * libgomp.h: Include omp-lock.h and omp.h.
2042         * Makefile.am (nodist_include_HEADERS): New.
2043         (omp.h): New rule.
2044         * configure.ac (PERL): New.
2045         * mkomp_h.pl: New file.
2046         * omp.h.in: Rename from omp.h; replace omp_lock_t and omp_nest_lock_t
2047         with templates.
2048         * Makefile.in, configure, testsuite/Makefile.in: Rebuild.
2049
2050         * testsuite/lib/libgomp-dg.exp (libgomp_init): Add include into
2051         build directory.  Re-add -march=i486 hack.
2052
2053         * testsuite/lib/libgomp-dg.exp (libgomp_compile_flags): Remove.
2054         (libgomp_link_flags): Remove.
2055         (libgomp_initialized): Remove.
2056         (libgomp_init): Don't protect from reinitialization.  Copy code
2057         from libstdc++ for getting the multilib set correctly.
2058
2059 2005-05-05  Richard Henderson  <rth@redhat.com>
2060
2061         * config/linux/alpha/futex.h: New file.
2062         * configure.tgt (alpha*-*-linux*): Use it.
2063
2064         * config/posix/mutex.c: New file.
2065         * config/posix/sem.c: Use libgomp.h.
2066
2067         * configure.tgt (x86_64-linux): Also test CC for -m32.
2068         * config/linux/x86_64/futex.h (futex_wait): Fix r10 usage.
2069
2070         * testsuite/lib/libgomp-dg.exp (libgomp_link_flags): Add /
2071         after $gccpath.
2072
2073         * Makefile.am (SUBDIRS): New.
2074         (libgomp_la_LDFLAGS): Add -lpthread.
2075         * configure.ac (AM_INIT_AUTOMAKE): Enable dependencies.
2076         * Makefile.in, aclocal.m4, config.h.in, configure: Rebuild.
2077
2078         * libgomp_g.h: New file.
2079         * libgomp.h: Split out all public declarations to libgomp_g.h.
2080         Use pragma GCC visibility instead of ATTRIBUTE_HIDDEN.
2081         * config/linux/mutex.h: Remove ATTRIBUTE_HIDDEN.
2082         * config/linux/sem.h: Likewise.
2083         * config/posix/sem.h: Likewise.
2084
2085         * Makefile.am (AM_LDFLAGS): New.
2086         (libgomp_version_script): Split out from ...
2087         (libgomp_la_LDFLAGS): ... here.
2088         (libgomp_version_info): New.
2089         * acinclude.m4 (LIBGOMP_CHECK_TLS): Use LIBGOMP_ENABLE.
2090         (LIBGOMP_ENABLE): New.
2091         (LIBGOMP_CHECK_LINKER_FEATURES): New.
2092         (LIBGOMP_ENABLE_SYMVERS): New.
2093         * configure.ac (AC_INIT): Version 1.0.
2094         (enable-version-specific-runtime-libs): Use LIBGOMP_ENABLE.
2095         (enable-linux-futex): Likewise.  Rename from enable-futex.
2096         (libtool_VERSION): New.
2097         (LIBGOMP_ENABLE_SYMVERS): Use it.
2098         * configure.tgt: Check with_gnu_ld wrt have_tls optimizations.
2099         * Makefile.in, aclocal.m4, configure: Rebuild.
2100
2101         * config/linux/mutex.c: Include libgomp.h instead of mutex.h.
2102         (gomp_mutex_unlock_slow): Fix typo.
2103         * config/linux/sem.c: Similarly.
2104         (gomp_sem_post_slow): Fix typo.
2105         * config/linux/sem.h (gomp_sem_post_slow): Fix typo.
2106         * config/linux/i486/futex.h: Remove USE_LINUX_SYSENTER code.
2107         [__PIC__] (sys_futex0): Don't use tmp output in asm.
2108
2109         * Makefile.am (AM_CFLAGS): Expand with XCFLAGS.
2110         (libgomp_la_LDFLAGS): Add top_srcdir to path.
2111         * acinclude.m4: Copy libtool.m4 stuff from libgfortran.
2112         * configure.ac: Check for getloadavg.  Substitute XCFLAGS and
2113         XLDFLAGS.  Add XCFLAGS to CFLAGS around LIBGOMP_CHECK_SYNC_BUILTINS.
2114         * configure.tgt: Set XCFLAGS and XLDFLAGS instead of CFLAGS and
2115         LDFLAGS.  Pull enable_futex check to top-level.
2116         * libgomp.h: Fix sem.h and mutex.h includes.  Define ATTRIBUTE_HIDDEN.
2117         * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate.
2118
2119         First attempt at real configury.
2120         * Makefile, config.h: Remove file.
2121         * Makefile.am, Makefile.in: New file.
2122         * acinclude.m4 aclocal.m4: New file.
2123         * configure.ac, configure.tgt, configure: New file.
2124
2125         * config/posix/lock.c: Rename from sys-lock.c.
2126         * config/posix/mutex.h: Rename from sys-mutex.h.
2127         * config/posix/sem.c: Rename from sys-sem.c.
2128         * config/posix/sem.h: Rename from sys-sem.h.
2129         * config/posix/proc.c: Rename from sys-proc.c.
2130         * config/posix/time.c: Rename from sys-proc.c.
2131
2132         * config/linux/mutex.c: New file.
2133         * config/linux/mutex.h: New file.
2134         * config/linux/sem.c: New file.
2135         * config/linux/sem.h: New file.
2136         * config/linux/i486/futex.h: New file.
2137         * config/linux/x86_64/futex.h: New file.
2138
2139 2005-05-04  Richard Henderson  <rth@redhat.com>
2140
2141         * iter.c (gomp_iter_dynamic_next, gomp_iter_guided_next): New.
2142         * libgomp.h: Declare them.
2143         * loop.c (gomp_loop_dynamic_start, gomp_loop_guided_start,
2144         gomp_loop_dynamic_next, gomp_loop_guided_next): Use them.
2145
2146 2005-05-04  Richard Henderson  <rth@redhat.com>
2147
2148         * libgomp-1 code drop
2149
2150 2005-05-04  Richard Henderson  <rth@redhat.com>
2151
2152         * iter.c (gomp_iter_static_next): Return tri-state on 0.
2153         * ordered.c (gomp_ordered_static_next): Remove not_last argument.
2154         * libgomp.h (struct gomp_team_state): Make static_trip unsigned.
2155         (gomp_iter_static_next): Update.
2156         (gomp_ordered_static_next): Update.
2157         * loop.c (gomp_loop_static_start): Update for gomp_iter_static_next.
2158         (gomp_loop_ordered_static_start): Likewise.  Exit early for a
2159         totally empty range.
2160         (gomp_loop_ordered_static_next): Refine test for calling
2161         gomp_ordered_static_next.
2162         * testsuite/ordered-1.c: Add case for more threads than iterations.
2163
2164         * iter.c (gomp_iter_runtime_next_locked): Remove.
2165         * loop.c (gomp_loop_static_start, gomp_loop_dynamic_start,
2166         gomp_loop_guided_start, gomp_loop_ordered_static_start,
2167         gomp_loop_ordered_dynamic_start, gomp_loop_ordered_guided_start,
2168         gomp_loop_static_next, gomp_loop_dynamic_next, gomp_loop_guided_next,
2169         gomp_loop_ordered_static_next, gomp_loop_ordered_dynamic_next,
2170         gomp_loop_ordered_guided_next): Downcase name, make static, add
2171         an external alias with the old name.
2172         (GOMP_loop_runtime_start, GOMP_loop_ordered_runtime_start,
2173         GOMP_loop_runtime_next, GOMP_loop_ordered_runtime_next): Use a
2174         switch and call one of the above static functions.
2175         * libgomp.h: Update.
2176
2177         * work.c (gomp_work_share_start): Lock the mutex for !first too.
2178         * loop.c (GOMP_loop_static_start, GOMP_loop_dynamic_start,
2179         GOMP_loop_guided_start, GOMP_loop_runtime_start,
2180         GOMP_loop_ordered_static_start, GOMP_loop_ordered_dynamic_start,
2181         GOMP_loop_ordered_guided_start): Update to match.
2182         * sections.c (GOMP_sections_start): Likewise.
2183         * single.c (GOMP_single_start, GOMP_single_copy_start): Likewise.
2184
2185         * ordered.c (gomp_ordered_first, gomp_ordered_last, gomp_ordered_next,
2186         gomp_ordered_static_init, gomp_ordered_static_next): Rename s/_loop//.
2187         Use bounds check instead of modulus.
2188         (gomp_ordered_sync): Split out of GOMP_ordered_start.
2189         (gomp_ordered_last): Don't sync with ordered_owner here.
2190         (gomp_ordered_next): Likewise.
2191         (gomp_ordered_static_loop_next): Likewise.
2192         * loop.c, libgomp.h: Update to match.
2193
2194         * libgomp.h (GOMP_barrier): Declare.
2195
2196         * testsuite/barrier-1.c: New file.
2197         * testsuite/critical-1.c: New file.
2198         * testsuite/ordered-2.c: New file.
2199         * testsuite/ordered-1.c: New file.
2200         * testsuite/sections-1.c: New file.
2201         * testsuite/single-1.c: New file.
2202         * testsuite/Makefile (TESTS): Add them.
2203
2204 2005-05-04  Richard Henderson  <rth@redhat.com>
2205
2206         * libgomp.h (struct gomp_work_share): Add ordered_owner.
2207         * loop.c (GOMP_loop_static_start): If not the startup thread,
2208         acquire the mutex to wait for initialization complete.
2209         (GOMP_loop_ordered_static_start): Likewise.
2210         (GOMP_loop_ordered_runtime_start): Likewise.
2211         (GOMP_loop_ordered_static_first): Remove.
2212         (GOMP_loop_ordered_dynamic_first): Remove.
2213         (GOMP_loop_ordered_guided_first): Remove.
2214         (GOMP_loop_ordered_runtime_first): Remove.
2215         * ordered.c (gomp_ordered_loop_first): Post to own release when
2216         we're the first thread.
2217         (gomp_ordered_loop_last): Wait on release if not owner.
2218         (gomp_ordered_loop_next): Likewise.
2219         (gomp_ordered_static_loop_init): New.
2220         (gomp_ordered_static_loop_next): Use ordered_owner.
2221         (GOMP_ordered_start): Likewise.
2222         * work.c (gomp_new_work_share): Initialize ordered_owner.
2223
2224 2005-05-03  Richard Henderson  <rth@redhat.com>
2225
2226         * Makefile (OPT): New.
2227         (CFLAGS): Use it.
2228
2229         * loop.c (GOMP_loop_end, GOMP_loop_end_nowait): New.
2230         * sections.c (GOMP_sections_end, GOMP_sections_end_nowait): New.
2231         * libgomp.h, libgomp.map, NOTES: Update to match.
2232
2233         * team.c (struct gomp_thread_start_data): Remove ts, fn, data.
2234         Add initialized and thr members.
2235         (gomp_thread_start): Pause when initially spawned to wait for
2236         the whole team to be created.
2237         (gomp_team_start): Release team members at the end.
2238
2239         * testsuite/loop-1.c (N): New.  Use it instead of hardcoded 100.
2240         (f_foo_1): Use GOMP_loop_end.
2241         (f_foo_2): Use GOMP_loop_end_nowait.
2242
2243         * testsuite/loop-2.c: New file.
2244         * testsuite/Makefile (TESTS): Add it.
2245
2246 2005-05-03  Richard Henderson  <rth@redhat.com>
2247
2248         * iter.c (gomp_iter_static_next): Fix overflow check typo.
2249         (gomp_iter_dynamic_next_locked): Fix overflow check thinko.
2250         * team.c (new_team): Initialize oldest_live_gen to 1 if no
2251         initial work_share.
2252
2253         * testsuite/Makefile: New file.
2254         * testsuite/loop-1.c: New file.
2255
2256 2005-05-03  Richard Henderson  <rth@redhat.com>
2257
2258         Initial implementation and checkin.