aboutsummaryrefslogtreecommitdiff
path: root/libgomp/ChangeLog.gomp
blob: 2913495e98f318180fda531f681daae780015119 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
2008-05-14  Jakub Jelinek  <jakub@redhat.com>

	* task.c: Include string.h.
	(GOMP_task): Add cpyfn, arg_size and arg_align arguments.
	Allocate argument buffer and either call cpyfn to populate it,
	or memcpy it from the argument struct.
	(GOMP_task_start): Removed.
	* libgomp.map: Remove GOMP_task_start@@GOMP_2.0.
	* libgomp_g.h (GOMP_task_flag_untied,
	GOMP_task_flag_explicit_start): Removed.
	(GOMP_task): Adjust prototype.
	(GOMP_task_start): Removed.
	* testsuite/libgomp.fortran/task2.f90: New test.
	* testsuite/libgomp.fortran/allocatable4.f90: New test.
	* testsuite/libgomp.c/task-4.c: New test.
	* testsuite/libgomp.c++/task-4.C: New test.
	* testsuite/libgomp.c++/task-3.C: New test.

2008-05-07  Jakub Jelinek  <jakub@redhat.com>

	* libgomp.h (gomp_new_icv): New prototype.
	(gomp_icv): Add write argument.  If task is NULL and write is true,
	return gomp_new_icv ().
	* team.c (gomp_thread_pool_destructor): Rename to...
	(gomp_thread_destructor): ... this.
	(gomp_free_thread_pool): Rename to...
	(gomp_free_thread): ... this.  Don't use argument.  Free both pool
	if allocated and task if allocated.
	(gomp_team_start, initialize_team, team_destructor): Adjust for
	variable and function renames.
	(gomp_new_icv): New function.
	* loop.c (GOMP_loop_runtime_start, GOMP_loop_ordered_runtime_start,
	GOMP_parallel_loop_runtime_start): Adjust gomp_icv callers.
	* parallel.c (gomp_resolve_num_threads): Likewise.
	* env.c (omp_set_num_threads, omp_set_dynamic, omp_get_dynamic,
	omp_set_nested, omp_get_nested, omp_set_schedule, omp_get_schedule,
	omp_get_max_threads): Likewise.
	* task.c (GOMP_task): Likewise.
	* config/linux/lock.c (gomp_set_nest_lock_30,
	gomp_test_nest_lock_30): Likewise.
	* config/linux/proc.c (get_num_procs, gomp_dynamic_max_threads):
	Likewise.
	* config/posix95/lock.c (gomp_set_nest_lock_30,
	gomp_test_nest_lock_30): Likewise.
	* config/mingw32/proc.c (gomp_dynamic_max_threads): Likewise.
	* config/posix/lock.c (gomp_set_nest_lock_30,
	gomp_test_nest_lock_30): Likewise.
	* config/posix/proc.c (gomp_dynamic_max_threads, omp_get_num_procs):
	Likewise.
	* testsuite/libgomp.c/icv-2.c: New test.
	* testsuite/libgomp.c/lock-3.c: New test.

2008-05-07  Jakob Blomer  <jakob.blomer@ira.uka.de>
	    Jakub Jelinek  <jakub@redhat.com>

	* libgomp.h (struct gomp_thread): Add thread_pool field.
	(struct gomp_thread_pool): New type.
	(gomp_icv): Fix formatting.
	* team.c (gomp_threads, gomp_threads_size, gomp_threads_used,
	gomp_threads_dock): Removed.
	(gomp_thread_pool_destructor): New variable.
	(struct gomp_thread_start_data): Add thread_pool field.
	(gomp_thread_start): Use pool fields instead of global
	gomp_* variables.
	(gomp_new_thread_pool, gomp_free_pool_helper,
	gomp_free_thread_pool): New functions.
	(gomp_team_start): Create new pool if current thread doesn't have
	one.  Use pool fields instead of global gomp_* variables. 
	Initialize thread_pool field for new threads.
	(initialize_team): Call pthread_key_create on
	gomp_thread_pool_destructor.
	(team_destructor): New function.

2008-04-01  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.c/collapse-3.c: New test.

2008-03-28  Jakub Jelinek  <jakub@redhat.com>

	* config/linux/sparc/futex.h (atomic_write_barrier): Fix membar
	argument.

2008-03-27  Jakub Jelinek  <jakub@redhat.com>

	* libgomp.h (struct gomp_team_state): Remove single_count field
	ifndef HAVE_SYNC_BUILTINS.
	(struct gomp_team): Likewise.  Add work_share_list_free_lock
	ifndef HAVE_SYNC_BUILTINS.
	* team.c (gomp_new_team): If HAVE_SYNC_BUILTINS is not defined,
	don't initialize single_count, but instead initialize
	work_share_list_free_lock.
	(free_team): Destroy work_share_list_free_lock ifndef
	HAVE_SYNC_BUILTINS.
	(gomp_team_start): Don't initialize ts.single_count ifndef
	HAVE_SYNC_BUILTINS.
	* work.c (alloc_work_share, free_work_share): Use
	work_share_list_free_lock instead of atomic chaining ifndef
	HAVE_SYNC_BUILTINS.

2008-03-26  Jakub Jelinek  <jakub@redhat.com>

	* loop.c (gomp_loop_init): Fix GFS_DYNAMIC ws->mode setting.
	* testsuite/libgomp.c/loop-4.c: New test.

	* libgomp.h (struct gomp_team_state): Add single_count field.
	(struct gomp_team): Likewise.
	* team.c (gomp_new_team): Clear single_count.
	(gomp_team_start): Likewise.
	* single.c (GOMP_single_start): Rewritten if HAVE_SYNC_BUILTINS.

2008-03-25  Jakub Jelinek  <jakub@redhat.com>

	* team.c (gomp_thread_start): Don't clear ts.static_trip here.
	* loop.c (gomp_loop_static_start, gomp_loop_dynamic_start): Clear
	ts.static_trip here.
	* work.c (gomp_work_share_start): Don't clear ts.static_trip here.

2008-03-21  Jakub Jelinek  <jakub@redhat.com>

	* libgomp.h: Include ptrlock.h.
	(struct gomp_work_share): Reshuffle fields.  Add next_alloc,
	next_ws, next_free and inline_ordered_team_ids fields, change
	ordered_team_ids into pointer from flexible array member.
	(struct gomp_team_state): Add last_work_share field, remove
	work_share_generation.
	(struct gomp_team): Remove work_share_lock, generation_mask,
	oldest_live_gen, num_live_gen and init_work_shares fields, add
	work work_share_list_alloc, work_share_list_free and work_share_chunk
	fields.  Change work_shares from pointer to pointers into an array.
	(gomp_new_team): New prototype.
	(gomp_team_start): Change type of last argument.
	(gomp_new_work_share): Removed.
	(gomp_init_work_share, gomp_fini_work_share): New prototypes.
	(gomp_work_share_init_done): New static inline.
	* team.c (gomp_thread_start): Clear ts.last_work_share, don't clear
	ts.work_share_generation.
	(new_team): Removed.
	(gomp_new_team): New function.
	(free_team): Free gomp_work_share blocks chained through next_alloc,
	instead of freeing work_shares and destroying work_share_lock.
	(gomp_team_start): Change last argument from ws to team, don't create
	new team, set ts.work_share to &team->work_shares[0] and clear
	ts.last_work_share.  Don't clear ts.work_share_generation.
	(gomp_team_end): Call gomp_fini_work_share.
	* work.c (gomp_new_work_share): Removed.
	(alloc_work_share, gomp_init_work_share, gomp_fini_work_share): New
	functions.
	(free_work_share): Add team argument.  Call gomp_fini_work_share
	and then either free ws if orphaned, or put it into
	work_share_list_free list of the current team.
	(gomp_work_share_start, gomp_work_share_end,
	gomp_work_share_end_nowait): Rewritten.
	* sections.c (GOMP_sections_start): Call gomp_work_share_init_done
	after gomp_sections_init.  If HAVE_SYNC_BUILTINS, call
	gomp_iter_dynamic_next instead of the _locked variant and don't take
	lock around it, otherwise acquire it before calling
	gomp_iter_dynamic_next_locked.
	(GOMP_sections_next): If HAVE_SYNC_BUILTINS, call
	gomp_iter_dynamic_next instead of the _locked variant and don't take
	lock around it.
	(GOMP_parallel_sections_start): Call gomp_new_team instead of
	gomp_new_work_share.  Call gomp_sections_init on &team->work_shares[0].
	Adjust gomp_team_start caller.
	* loop.c (gomp_loop_static_start, gomp_loop_ordered_static_start): Call
	gomp_work_share_init_done after gomp_loop_init.  Don't unlock ws->lock.
	(gomp_loop_dynamic_start, gomp_loop_guided_start): Call
	gomp_work_share_init_done after gomp_loop_init.  If HAVE_SYNC_BUILTINS,
	don't unlock ws->lock, otherwise lock it.
	(gomp_loop_ordered_dynamic_start, gomp_loop_ordered_guided_start): Call
	gomp_work_share_init_done after gomp_loop_init.  Lock ws->lock.
	(gomp_parallel_loop_start): Call gomp_new_team instead of
	gomp_new_work_share.  Call gomp_loop_init on &team->work_shares[0].
	Adjust gomp_team_start caller.
	* single.c (GOMP_single_start, GOMP_single_copy_start): Call
	gomp_work_share_init_done if gomp_work_share_start returned true.
	Don't unlock ws->lock.
	* parallel.c (gomp_resolve_num_threads): Fix non-HAVE_SYNC_BUILTINS
	case.
	(GOMP_parallel_start): Call gomp_new_team and pass that as last
	argument to gomp_team_start.
	* config/linux/ptrlock.c: New file.
	* config/linux/ptrlock.h: New file.
	* config/posix/ptrlock.c: New file.
	* config/posix/ptrlock.h: New file.
	* Makefile.am (libgomp_la_SOURCES): Add ptrlock.c.
	* Makefile.in: Regenerated.
	* testsuite/Makefile.in: Regenerated.

	* testsuite/libgomp.c++/collapse-1.C (main): Make k private in second
	omp for loop.

2008-03-19  Jakub Jelinek  <jakub@redhat.com>

	* libgomp.h (gomp_active_wait_policy): Remove decl.
	(gomp_throttled_spin_count_var, gomp_available_cpus,
	gomp_managed_threads): New extern decls.
	* team.c (gomp_team_start, gomp_team_end): If number of threads
	changed, adjust atomically gomp_managed_threads.
	* env.c (gomp_active_wait_policy, gomp_block_time_var): Remove.
	(gomp_throttled_spin_count_var, gomp_available_cpus,
	gomp_managed_threads): New variables.
	(parse_millis): Removed.
	(parse_spincount): New function.
	(parse_wait_policy): Return -1/0/1 instead of setting
	gomp_active_wait_policy.
	(initialize_env): Call gomp_init_num_threads unconditionally.
	Initialize gomp_available_cpus.  Call parse_spincount instead
	of parse_millis, initialize gomp_{,throttled_}spin_count_var
	depending on presence and value of OMP_WAIT_POLICY and
	GOMP_SPINCOUNT env vars.
	* config/linux/wait.h (do_wait): Use gomp_throttled_spin_count_var
	instead of gomp_spin_count_var if gomp_managed_threads >
	gomp_available_cpus.

	* config/linux/wait.h: Include errno.h.
	(FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Define.
	(gomp_futex_wake, gomp_futex_wait): New extern decls.
	* config/linux/mutex.c (gomp_futex_wake, gomp_futex_wait): New
	variables.
	* config/linux/powerpc/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
	(sys_futex0): Return error code.
	(futex_wake, futex_wait): If ENOSYS was returned, clear
	FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
	* config/linux/alpha/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
	(futex_wake, futex_wait): If ENOSYS was returned, clear
	FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
	* config/linux/x86/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
	(sys_futex0): Return error code.
	(futex_wake, futex_wait): If ENOSYS was returned, clear
	FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
	* config/linux/s390/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
	(sys_futex0): Return error code.
	(futex_wake, futex_wait): If ENOSYS was returned, clear
	FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
	* config/linux/ia64/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
	(sys_futex0): Return error code.
	(futex_wake, futex_wait): If ENOSYS was returned, clear
	FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.
	* config/linux/sparc/futex.h (FUTEX_WAIT, FUTEX_WAKE): Remove.
	(sys_futex0): Return error code.
	(futex_wake, futex_wait): If ENOSYS was returned, clear
	FUTEX_PRIVATE_FLAG in gomp_futex_wa{ke,it} and retry.

2008-03-18  Jakub Jelinek  <jakub@redhat.com>

	* libgomp.h (struct gomp_work_share): Add mode field.  Put lock and
	next into a different cache line from most of the write-once fields.
	* loop.c: Include limits.h.
	(gomp_loop_init): For GFS_DYNAMIC, multiply ws->chunk_size by incr.
	If adding ws->chunk_size nthreads + 1 times after end won't
	overflow, set ws->mode to 1.
	* iter.c (gomp_iter_dynamic_next_locked): Don't multiply
	ws->chunk_size by incr.
	(gomp_iter_dynamic_next): Likewise.  If ws->mode, use more efficient
	code.
	* work.c: Include stddef.h.
	(gomp_new_work_share): Use offsetof rather than sizeof.

2008-03-17  Jakub Jelinek  <jakub@redhat.com>

	* libgomp.h (struct gomp_team): Change ordered_release field
	into gomp_sem_t ** from flexible array member.  Add implicit_task
	and initial_work_shares fields.
	(gomp_new_task): Removed.
	(gomp_init_task): New prototype.
	* team.c (new_team): Allocate implicit_task for each thread
	and initial work_shares together with gomp_team allocation.
	(free_team): Only free work_shares if it is not init_work_shares.
	(gomp_team_start): Use gomp_init_task instead of gomp_new_task,
	set thr->task to the corresponding implicit_task array entry.
	* task.c (gomp_new_task): Removed.
	(gomp_init_task): New function.
	(gomp_end_task): Don't free the task.
	(GOMP_task): Allocate struct gomp_task on the stack, call
	gomp_init_task rather than gomp_new_task.
	* work.c (gomp_work_share_start): If work_shares ==
	init_work_shares, gomp_malloc + memcpy rather than gomp_realloc.

2008-03-15  Jakub Jelinek  <jakub@redhat.com>
	    Ulrich Drepper  <drepper@redhat.com>

	* config/linux/bar.h (gomp_barrier_state_t): Rewritten.
	(gomp_barrier_state_t): Change to unsigned int.
	(gomp_barrier_init, gomp_barrier_reinit, gomp_barrier_destroy,
	gomp_barrier_wait_start, gomp_barrier_last_thread): Rewritten.
	(gomp_barrier_wait_last): Prototype rather than inline.
	* config/linux/bar.c (gomp_barrier_wait_end): Rewritten.
	(gomp_barrier_wait_last): New function.

2008-03-15  Jakub Jelinek  <jakub@redhat.com>

	* team.c (gomp_thread_start): Use gomp_barrier_wait_last instead
	of gomp_barrier_wait.
	* env.c (gomp_block_time_var, gomp_spin_count_var): New variables.
	(parse_millis): New function.
	(initialize_env): Handle GOMP_BLOCKTIME env var.
	* libgomp.h (struct gomp_team): Move close to the end of the struct.
	(gomp_spin_count_var): New extern var decl.
	* work.c (gomp_work_share_end): Use gomp_barrier_state_t bstate
	var instead of bool last, call gomp_barrier_last_thread to check
	for last thread, pass bstate to gomp_barrier_wait_end.
	* parallel.c (gomp_resolve_num_threads, GOMP_parallel_end): Add
	__builtin_expect.
	* config/linux/wait.h: New file.
	* config/linux/mutex.c: Include wait.h instead of libgomp.h and
	futex.h.
	(gomp_mutex_lock_slow): Call do_wait instead of futex_wait.
	* config/linux/bar.c: Include wait.h instead of libgomp.h and
	futex.h.
	(gomp_barrier_wait_end): Change second argument to
	gomp_barrier_state_t.  Call do_wait instead of futex_wait.
	* config/linux/sem.c: Include wait.h instead of libgomp.h and
	futex.h.
	(gomp_sem_wait_slow): Call do_wait instead of futex_wait.
	* config/linux/lock.c: Include wait.h instead of libgomp.h and
	futex.h.
	(gomp_set_nest_lock_25): Call do_wait instead of futex_wait.
	* config/linux/affinity.c: Assume HAVE_SYNC_BUILTINS.
	* config/linux/bar.h (gomp_barrier_state_t): New typedef.
	(gomp_barrier_wait_end): Change second argument to
	gomp_barrier_state_t.
	(gomp_barrier_wait_start): Return gomp_barrier_state_t.
	(gomp_barrier_last_thread, gomp_barrier_wait_last): New static
	inlines.
	* config/linux/powerpc/futex.h (cpu_relax, atomic_write_barrier): New
	static inlines.
	* config/linux/alpha/futex.h (cpu_relax, atomic_write_barrier):
	Likewise.
	* config/linux/x86/futex.h (cpu_relax, atomic_write_barrier):
	Likewise.
	* config/linux/s390/futex.h (cpu_relax, atomic_write_barrier):
	Likewise.
	* config/linux/ia64/futex.h (cpu_relax, atomic_write_barrier):
	Likewise.
	* config/linux/sparc/futex.h (cpu_relax, atomic_write_barrier):
	Likewise.
	* config/posix/bar.c (gomp_barrier_wait_end): Change second argument
	to gomp_barrier_state_t.
	* config/posix/bar.h (gomp_barrier_state_t): New typedef.
	(gomp_barrier_wait_end): Change second argument to
	gomp_barrier_state_t.
	(gomp_barrier_wait_start): Return gomp_barrier_state_t.
	(gomp_barrier_last_thread, gomp_barrier_wait_last): New static
	inlines.

2008-03-12  Jakub Jelinek  <jakub@redhat.com>

	* libgomp_g.h (GOMP_task_flag_untied,
	GOMP_task_flag_explicit_start): Define.
	* libgomp.map (GOMP_task_start): Export @@GOMP_2.0.
	* task.c (GOMP_task): Change last argument.
	(GOMP_task_start): New function.
	* testsuite/libgomp.c/task-3.c: New test.
	* testsuite/libgomp.c++/task-2.C: New test.

2008-03-10  Jakub Jelinek  <jakub@redhat.com>

	* config/linux/lock.c: Rewrite to make locks task owned,
	for backwards compatibility provide the old entrypoints
	if symbol versioning.
	* config/linux/omp-lock.h (omp_lock_25_t, omp_nest_lock_25_t): New
	types.
	(omp_nest_lock_t): Change owner into void *, add lock field.
	* config/posix95/lock.c: Rewrite to make locks task owned,
	for backwards compatibility provide the old entrypoints
	if symbol versioning.
	* config/posix95/omp-lock.h: Include semaphore.h.
	(omp_lock_25_t, omp_nest_lock_25_t): New types.
	(omp_lock_t): Use sem_t instead of mutex if semaphores
	aren't broken.
	(omp_nest_lock_t): Likewise.  Change owner to void *.
	* config/posix/lock.c: Rewrite to make locks task owned,
	for backwards compatibility provide the old entrypoints
	if symbol versioning.
	* config/posix/omp-lock.h: Include semaphore.h.
	(omp_lock_25_t, omp_nest_lock_25_t): New types.
	(omp_lock_t): Use sem_t instead of mutex if semaphores
	aren't broken.
	(omp_nest_lock_t): Likewise.  Add owner field.
	* libgomp_f.h.in (omp_lock_25_arg_t, omp_nest_lock_25_arg_t): New
	types.
	(omp_lock_25_arg, omp_nest_lock_25_arg): New macros.
	(omp_check_defines): Check even the compat defines.
	* libgomp.h (LIBGOMP_GNU_SYMBOL_VERSIONING): Undef if no visibility
	or no alias support, or if not PIC.
	(gomp_init_lock_30, gomp_destroy_lock_30, gomp_set_lock_30,
	gomp_unset_lock_30, gomp_test_lock_30, gomp_init_nest_lock_30,
	gomp_destroy_nest_lock_30, gomp_set_nest_lock_30,
	gomp_unset_nest_lock_30, gomp_test_nest_lock_30, gomp_init_lock_25,
	gomp_destroy_lock_25, gomp_set_lock_25, gomp_unset_lock_25,
	gomp_test_lock_25, gomp_init_nest_lock_25, gomp_destroy_nest_lock_25,
	gomp_set_nest_lock_25, gomp_unset_nest_lock_25,
	gomp_test_nest_lock_25): New prototypes.
	(omp_lock_symver, strong_alias): Define.
	* fortran.c: Rewrite lock wrappers, if symbol versioning provide
	both wrappers for compatibility and new locks.
	* libgomp.map: Export lock routines also @@OMP_2.0.
	* configure.ac (LIBGOMP_GNU_SYMBOL_VERSIONING): New AC_DEFINE.
	Substitute also OMP_*LOCK_25*.
	* configure: Regenerated.
	* config.h.in: Regenerated.
	* testsuite/libgomp.fortran/lock-1.f90: New test.
	* testsuite/libgomp.fortran/lock-2.f90: New test.
	* testsuite/libgomp.c/lock-1.c: New test.
	* testsuite/libgomp.c/lock-2.c: New test.

2008-03-07  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.fortran/vla4.f90: Add dg-warning.
	* testsuite/libgomp.fortran/vla5.f90: Likewise.
	* testsuite/libgomp.c/pr26943-2.c: Likewise.
	* testsuite/libgomp.c/pr26943-3.c: Likewise.
	* testsuite/libgomp.c/pr26943-4.c: Likewise.

2008-02-29  Jakub Jelinek  <jakub@redhat.com>

	* team.c (gomp_thread_start): Initialize ts.active_level.
	* sections.c (GOMP_parallel_sections_start): Pass count
	as second argument to gomp_resolve_num_threads, don't adjust
	num_threads after the call.
	* env.c (gomp_thread_limit_var): Initialize to ULONG_MAX.
	(gomp_remaining_threads_count, gomp_remaining_threads_lock): New
	variables.
	(initialize_env): Initialize gomp_remaining_threads_count and
	gomp_remaining_threads_lock if needed.
	(omp_get_thread_limit): Return INT_MAX if gomp_thread_limit_var
	is larger than INT_MAX.
	* libgomp.h (struct gomp_team_state): Add active_level field.
	(gomp_remaining_threads_count, gomp_remaining_threads_lock): New
	decls.
	* loop.c (gomp_parallel_loop_start): Pass 0 as second argument
	to gomp_resolve_num_threads.
	* parallel.c: Include limits.h.
	(gomp_resolve_num_threads): Add count argument.  Use current thread's
	active_level rather than level when checking nest-var or
	max-active-levels-var.  Implement OMP_THREAD_LIMIT limitation of
	total number of OpenMP threads.  If second argument is non-zero,
	don't return more than that number if dyn-var is true.
	(GOMP_parallel_start): Pass 0 as second argument to
	gomp_resolve_num_threads.
	(GOMP_parallel_end): Decrease gomp_remaining_threads_count
	if gomp_thread_limit_var != ULONG_MAX.
	(omp_in_parallel, omp_get_active_level): Implement using
	ts.active_level.

2008-02-28  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.fortran/allocatable1.f90: New test.
	* testsuite/libgomp.fortran/allocatable2.f90: New test.
	* testsuite/libgomp.fortran/allocatable3.f90: New test.

2008-02-26  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.c++/ctor-10.C: New test.

	* testsuite/libgomp.c++/for-5.C (I<T>::~I ()): Clear p.
	* testsuite/libgomp.c++/collapse-2.C: New test.
	* testsuite/libgomp.fortran/collapse4.f90: New test.

2008-02-22  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.c/collapse-2.c: New test.

2008-02-15  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.c/nestedfn-6.c: New test.
	* testsuite/libgomp.c++/for-5.C: New test.
	* testsuite/libgomp.fortran/nestedfn4.f90: New test.
	* testsuite/libgomp.fortran/collapse3.f90: Uncomment tests for
	lastprivate values, make sure all iterators are in lastprivate
	clauses.
	* testsuite/libgomp.fortran/lastprivate1.f90: New test.
	* testsuite/libgomp.fortran/lastprivate2.f90: New test.

2008-02-12  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.c/task-2.c: New test.

	* testsuite/libgomp.c++/c++.exp: Add libstdc++-v3 build includes
	to C++ testsuite default compiler options.
	* testsuite/libgomp.c++/for-1.C: New test.
	* testsuite/libgomp.c++/for-2.C: New test.
	* testsuite/libgomp.c++/for-3.C: New test.
	* testsuite/libgomp.c++/for-4.C: New test.

2008-02-04  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.fortran/collapse2.f90: New test.
	* testsuite/libgomp.fortran/collapse3.f90: New test.

2007-12-19  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.c/task-1.c (f3): New function.
	(main): Call it, also test from within parallel region.
	* testsuite/libgomp.c/collapse-1.c: New test.
	* testsuite/libgomp.c++/task-1.C: New test.
	* testsuite/libgomp.c++/collapse-1.C: New test.
	* testsuite/libgomp.fortran/collapse1.f90: New test.

2007-12-12  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.fortran/task1.f90: New test.

2007-11-30  Richard Henderson  <rth@redhat.com>

	* team.c (gomp_team_end): Use gomp_end_task.
	* testsuite/libgomp.c/icv-1.c: Enable failing test.

2007-11-30  Jakub Jelinek  <jakub@redhat.com>

	* testsuite/libgomp.c/task-1.c: New test.

	* testsuite/libgomp.c/icv-1.c: New test.

2007-11-28  Richard Henderson  <rth@redhat.com>

	* task.c: New file.
	* Makefile.am (libgomp_la_SOURCES): Add task.c.
	* Makefile.in: Regenerate.
	* libgomp_g.h (GOMP_task, GOMP_taskwait): Add.
	* libgomp.map (GOMP_task, GOMP_taskwait): Add.
	* team.c (struct gomp_thread_start_data): Add task.
	(gomp_thread_start): Initialize and finalize the thread task.
	(gomp_team_start): Create tasks for each member thread.
	* libgomp.h (gomp_new_task, gomp_end_task): New.

2007-11-28  Richard Henderson  <rth@redhat.com>

	* parallel.c (gomp_resolve_num_threads): Update to the OMP3 algorithm.

2007-11-28  Richard Henderson  <rth@redhat.com>

	* libgomp.h (struct gomp_task_icv, gomp_global_icv): New.
	(gomp_thread_limit_var, gomp_max_active_levels_var): New.
	(struct gomp_task): New.
	(struct gomp_thread): Add task member.
	(gomp_nthreads_var, gomp_dyn_var, gomp_nest_var,
	gomp_run_sched_var, gomp_run_sched_chunk): Remove.
	(gomp_icv): New.
	* env.c (gomp_nthreads_var, gomp_dyn_var, gomp_nest_var,
	gomp_run_sched_var, gomp_run_sched_chunk): Remove.
	(gomp_global_icv): New.
	(parse_schedule, initialize_env): Use it.
	(omp_set_num_threads): Use gomp_icv.
	(omp_set_dynamic, omp_get_dynamic, omp_set_nested, omp_get_nested,
	omp_set_schedule, omp_get_schedule): Likewise.
	(omp_get_max_threads): Move from parallel.c; only use nthreads_var.
	* sections.c (GOMP_parallel_sections_start): Use gomp_icv.
	* loop.c (GOMP_loop_runtime_start): Likewise.
	(GOMP_loop_ordered_runtime_start): Likewise.
	* parallel.c (gomp_resolve_num_threads): Likewise.
	(omp_get_max_threads): Move to env.c.
	* config/linux/proc.c (gomp_init_num_threads): Use gomp_global_icv.
	(get_num_procs, gomp_dynamic_max_threads): Use gomp_icv.
	* config/posix/proc.c, config/mingw32/proc.c: Similarly.
	* omp_lib.f90.in: Change some tabs to spaces to prevent warnings.

2007-10-23  Jakub Jelinek  <jakub@redhat.com>

	* libgomp.h (gomp_schedule_type): Reorder enum to match
	omp_sched_t.
	(struct gomp_team_state): Add level field.
	* team.c (gomp_thread_start): Clear ts.level.
	(gomp_team_start): Initialize ts.level.
	* parallel.c (omp_in_parallel): Update comment.
	(omp_get_level, omp_get_ancestor_thread_num,
	omp_get_team_size, omp_get_active_level): New functions,
	add ialias.
	* env.c (omp_set_schedule, omp_get_schedule, omp_get_thread_limit,
	omp_set_max_active_levels, omp_get_max_active_levels): New functions,
	add ialias.
	* omp_lib.f90.in (omp_get_ancestor_thread_num): Handle
	integer (8) argument.
	* fortran.c (omp_set_schedule, omp_get_schedule,
	omp_get_thread_limit, omp_set_max_active_levels,
	omp_get_max_active_levels, omp_get_level,
	omp_get_ancestor_thread_num, omp_get_team_size,
	omp_get_active_level): New ialias_redirect.
	(omp_set_schedule_, omp_set_schedule_8_,
	omp_get_schedule_, omp_get_schedule_8_, omp_get_thread_limit_,
	omp_set_max_active_levels_, omp_set_max_active_levels_8_,
	omp_get_max_active_levels_, omp_get_level_,
	omp_get_ancestor_thread_num_, omp_get_ancestor_thread_num_8_,
	omp_get_team_size_, omp_get_team_size_8_, omp_get_active_level_):
	New functions.
	* libgomp.map (omp_set_schedule, omp_get_schedule,
	omp_get_thread_limit, omp_set_max_active_levels,
	omp_get_max_active_levels, omp_get_level,
	omp_get_ancestor_thread_num, omp_get_team_size, omp_get_active_level,
	omp_set_schedule_, omp_set_schedule_8_,
	omp_get_schedule_, omp_get_schedule_8_, omp_get_thread_limit_,
	omp_set_max_active_levels_, omp_set_max_active_levels_8_,
	omp_get_max_active_levels_, omp_get_level_,
	omp_get_ancestor_thread_num_, omp_get_ancestor_thread_num_8_,
	omp_get_team_size_, omp_get_team_size_8_, omp_get_active_level_):
	New exports @@OMP_3.0.
	* testsuite/libgomp.fortran/nested1.f90: New test.
	* testsuite/libgomp.fortran/lib4.f90: New test.
	* testsuite/libgomp.c/lib-2.c: New test.
	* testsuite/libgomp.c/nested-3.c: New test.

	* omp.h.in (omp_sched_t): New type.
	(omp_set_schedule, omp_get_schedule, omp_get_thread_limit,
	omp_set_max_active_levels, omp_get_max_active_levels,
	omp_get_level, omp_get_ancestor_thread_num, omp_get_team_size,
	omp_get_active_level): New prototypes.
	* omp_lib.f90.in (omp_sched_kind, omp_sched_static, omp_sched_dynamic,
	omp_sched_guided, omp_sched_auto): New parameters.
	(omp_set_schedule, omp_get_schedule, omp_get_thread_limit,
	omp_set_max_active_levels, omp_get_max_active_levels,
	omp_get_level, omp_get_ancestor_thread_num, omp_get_team_size,
	omp_get_active_level): New interfaces.
	* omp_lib.h.in (omp_sched_kind, omp_sched_static, omp_sched_dynamic,
	omp_sched_guided, omp_sched_auto): New parameters.
	(omp_set_schedule, omp_get_schedule, omp_get_thread_limit,
	omp_set_max_active_levels, omp_get_max_active_levels,
	omp_get_level, omp_get_ancestor_thread_num, omp_get_team_size,
	omp_get_active_level): New externals.

2007-10-22  Jakub Jelinek  <jakub@redhat.com>

	* env.c (gomp_active_wait_policy, gomp_max_active_levels_var,
	gomp_thread_limit_var): New variables.
	(parse_schedule): Parse "auto".
	(parse_stacksize, parse_wait_policy): New functions.
	(initialize_env): Handle OMP_WAIT_POLICY, OMP_MAX_ACTIVE_LEVELS,
	OMP_THREAD_LIMIT, OMP_STACKSIZE env vars.  Handle unit specification
	for GOMP_STACKSIZE.