]> git.ipfire.org Git - thirdparty/gcc.git/blob - libitm/ChangeLog
libitm: Don't execute memtransfer/memset if size isn't larger than zero.
[thirdparty/gcc.git] / libitm / ChangeLog
1 2012-03-05 Torvald Riegel <triegel@redhat.com>
2
3 * dispatch.h (CREATE_DISPATCH_METHODS_MEM): Don't execute
4 memtransfer/memset if size isn't larger than zero.
5
6 2012-03-02 Torvald Riegel <triegel@redhat.com>
7
8 * libitm.texi: Link to specification and add a usage example.
9
10 2012-02-24 Torvald Riegel <triegel@redhat.com>
11
12 * retry.cc (GTM::gtm_thread::number_of_threads_changed): Change
13 default dispatch for more than 1 thread to ml_wt.
14
15 2012-02-20 Torvald Riegel <triegel@redhat.com>
16
17 * method-gl.cc (gl_wt_dispatch::orec): Put on separate cacheline.
18
19 2012-02-20 Torvald Riegel <triegel@redhat.com>
20
21 * method-gl.cc (gl_wt_dispatch::rollback): Optimize memory orders.
22
23 2012-02-20 Torvald Riegel <triegel@redhat.com>
24
25 * method-gl.cc (gl_wt_dispatch::trycommit): Remove handling of
26 serial mode corner cases made obsolete by prior gtm_rwlock changes.
27 (gl_wt_dispatch.rollback): Same.
28
29 2012-02-20 Torvald Riegel <triegel@redhat.com>
30
31 * method-gl.cc (gl_wt_dispatch::pre_write): Optimize memory orders.
32
33 2012-02-20 Torvald Riegel <triegel@redhat.com>
34
35 * method-gl.cc (gl_wt_dispatch::memtransfer_static): Add missing undo
36 for RfW src. Optimize number of calls to gtm_thr.
37
38 2012-02-20 Torvald Riegel <triegel@redhat.com>
39
40 * beginend.cc (GTM::gtm_thread::begin_transaction): Move serial lock
41 acquisition to ...
42 * retry.cc (GTM::gtm_thread::decide_begin_dispatch): ... here.
43 (default_dispatch): Make atomic.
44 (GTM::gtm_thread::set_default_dispatch): Access atomically.
45 (GTM::gtm_thread::decide_retry_strategy): Access atomically and
46 use decide_begin_dispatch() if default_dispatch might have changed.
47 (GTM::gtm_thread::number_of_threads_changed): Initialize
48 default_dispatch here.
49
50 2012-02-15 Iain Sandoe <iains@gcc.gnu.org>
51 Patrick Marlier <patrick.marlier@gmail.com>
52
53 PR libitm/52220
54 * alloc_cpp.cc: No dummy definitions for darwin.
55 * eh_cpp.cc: Likewise.
56
57 2012-02-14 Richard Henderson <rth@redhat.com>
58
59 * config/x86/target.h (GTM_longjmp): Correct the .cfi corrections.
60
61 2012-02-14 Uros Bizjak <ubizjak@gmail.com>
62
63 * config/x86/target.h (GTM_longjmp): Correct .cfi directives.
64
65 2012-02-14 Torvald Riegel <triegel@redhat.com>
66
67 * libitm_i.h (GTM::gtm_rwlog_entry): New.
68 (GTM::gtm_thread): Add read and write logs.
69 (GTM::dispatch_ml_wt): Declare.
70 * retry.cc (parse_default_method): Support ml_wt.
71 * method-ml.cc: New file.
72 * Makefile.am: Add method-ml.cc.
73 * Makefile.in: Regenerate.
74
75 2012-02-14 Torvald Riegel <triegel@redhat.com>
76
77 * dispatch.h (GTM::abi_dispatch::supports): New.
78 (GTM::method_group::reinit): New.
79 * retry.cc (GTM::gtm_thread::decide_retry_strategy): Use reinit().
80 (GTM::gtm_thread::number_of_threads_changed): Check that the method
81 supports the current situation.
82
83 2012-02-14 Torvald Riegel <triegel@redhat.com>
84
85 * util.cc (GTM::xcalloc): New.
86 * common.h (GTM::xcalloc): Declare.
87
88 2012-02-14 Eric Botcazou <ebotcazou@adacore.com>
89
90 * config/sparc/target.h (cpu_relax): Read from CC register.
91 * config/sparc/sjlj.S (GTM_longjmp): Restore %fp atomically.
92
93 2012-02-14 Uros Bizjak <ubizjak@gmail.com>
94
95 * config/x86/target.h (GTM_longjmp): Jump indirect from memory address.
96
97 2012-02-13 Eric Botcazou <ebotcazou@adacore.com>
98
99 * configure.tgt (target_cpu): Handle sparc and sparc64/sparcv9.
100 * config/sparc/cacheline.h: New file.
101 * config/sparc/target.h: Likewise.
102 * config/sparc/sjlj.S: Likewise.
103 * config/linux/sparc/futex_bits.h: Likewise.
104
105 2012-02-13 Eric Botcazou <ebotcazou@adacore.com>
106
107 * configure.ac (link_itm): Fix comment.
108 * configure: Regenerate.
109 * testsuite/lib/libitm.exp: Do not pass -litm for the link.
110
111 2012-01-31 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
112
113 PR libitm/51822
114 * testsuite/libitm.c++/c++.exp (lang_link_flags): Add -shared-libgcc.
115 Correct libgomp references.
116
117 2012-01-24 Torvald Riegel <triegel@redhat.com>
118
119 * config/linux/rwlock.cc (GTM::gtm_rwlock::write_unlock): Fix reader
120 wake-up.
121
122 2012-01-24 Uros Bizjak <ubizjak@gmail.com>
123
124 * config/x86/target.h (gtm_jmpbuf) [__x86_64__]: Move rip to the
125 end of structure.
126 * config/x86/sjlj.S (_ITM_beginTransaction) [__x86_64__]: Update
127 offset values. Do not copy return address. Decrement stack
128 by 56 bytes only.
129 (GTM_longjump) [__x86_64__]: Update offset values.
130
131 2012-01-23 Uros Bizjak <ubizjak@gmail.com>
132
133 PR libitm/51830
134 * config/x86/sjlj.S (_ITM_beginTransaction) [!__x86_64__]: Load
135 the first function argument to %eax.
136
137 2012-01-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
138
139 * libitm.h (_ITM_getThreadnum): Remove.
140 * libitm.map (_ITM_getThreadnum): Remove from LIBITM_1.0.
141
142 2012-01-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
143
144 * clearcap.map: New file.
145 * acinclude.m4 (LIBITM_CHECK_LINKER_HWCAP): New test.
146 * configure.ac: Call it.
147 Clear HWCAP_LDFLAGS if defaulting to -mavx.
148 * Makefile.am (AM_LDFLAGS): Add $(HWCAP_LDFLAGS)
149 * configure: Regenerate.
150 * Makefile.in: Regenerate.
151 * testsuite/Makefile.in: Regenerate.
152
153 2012-01-17 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
154
155 PR libitm/51173
156 * testsuite/libitm.c++/static_ctor.C: Skip test, note PR, remove
157 include, exclude options.
158
159 2012-01-14 Torvald Riegel <triegel@redhat.com>
160
161 * local.cc (GTM::gtm_undolog::rollback): Truncate undo log after
162 rolling back.
163 * containers.h (GTM::vector::set_size): New.
164
165 2012-01-14 Torvald Riegel <triegel@redhat.com>
166
167 PR libitm/51855
168 * config/generic/tls.h (GTM::mask_stack_top): New.
169 (GTM::mask_stack_bottom): Declare.
170 * config/generic/tls.c (GTM::mask_stack_bottom): New.
171 * local.cc (gtm_undolog::rollback): Filter out any updates that
172 overlap the libitm stack. Add current transaction as parameter.
173 * libitm_i.h (GTM::gtm_undolog::rollback): Adapt.
174 * beginend.cc (GTM::gtm_thread::rollback): Adapt.
175 * testsuite/libitm.c/stackundo.c: New test.
176
177 2012-01-10 Richard Henderson <rth@redhat.com>
178
179 * libitm_i.h (_Unwind_DeleteException): Declare weak.
180 * eh_cpp.cc (_Unwind_DeleteException): Define for
181 !HAVE_ELF_STYLE_WEAKREF.
182
183 2012-01-08 Torvald Riegel <triegel@redhat.com>
184
185 * local.cc (GTM_LB): Use GTM::gtm_undolog.
186 (GTM::gtm_thread::drop_references_undolog): Remove.
187 (GTM::gtm_thread::commit_undolog,
188 GTM::gtm_thread::rollback_undolog): Move to ...
189 * libitm_i.h (GTM::gtm_undolog): ...here. New.
190 (GTM::gtm_undolog_entry): Remove.
191 (GTM::gtm_thread): Adapt.
192 * beginend.cc (GTM::gtm_thread::rollback): Adapt.
193 (GTM::gtm_thread::trycommit): Adapt.
194 * method-serial.cc (serial_dispatch::log): Adapt.
195 * method-gl.cc (gl_wt_dispatch::pre_write): Adapt.
196 (gl_wt_dispatch::store): Fix likely/unlikely.
197 * containers.h (GTM::vector::resize): Add additional_capacity
198 parameter and handle it.
199 (GTM::vector::resize_noinline): New/adapt.
200 (GTM::vector::push): New.
201
202 2012-01-06 Richard Henderson <rth@redhat.com>
203
204 * configure.tgt: Support powerpc-linux and powerpc-darwin.
205 * config/linux/powerpc/futex_bits.h: New file.
206 * config/powerpc/cacheline.h: New file.
207 * config/powerpc/sjlj.S: New file.
208 * config/powerpc/target.h: New file.
209 * config/generic/asmcfi.h (cfi_offset): New.
210 (cfi_restore, cfi_undefined): New.
211
212 2012-01-05 Aldy Hernandez <aldyh@redhat.com>
213
214 PR other/51171
215 * testsuite/libitm.c/reentrant.c: Remove xfail.
216 (thread): Pass x to pure().
217 From Patrik Marlier <patrick.marlier@gmail.com>.
218
219 2011-12-24 Torvald Riegel <triegel@redhat.com>
220
221 * beginend.cc (GTM::gtm_thread::trycommit): Don't enforce
222 privatization safety if already in serial mode.
223
224 2011-12-24 Torvald Riegel <triegel@redhat.com>
225
226 * beginend.cc (GTM::gtm_thread::restart): Add and handle
227 finish_serial_upgrade parameter.
228 * libitm.h (GTM::gtm_thread::restart): Adapt declaration.
229 * config/linux/rwlock.cc (GTM::gtm_rwlock::write_lock_generic):
230 Don't unset reader flag.
231 (GTM::gtm_rwlock::write_upgrade_finish): New.
232 * config/posix/rwlock.cc: Same.
233 * config/linux/rwlock.h (GTM::gtm_rwlock::write_upgrade_finish):
234 Declare.
235 * config/posix/rwlock.h: Same.
236 * method-serial.cc (GTM::gtm_thread::serialirr_mode): Unset reader
237 flag after commit or after rollback when restarting.
238
239 2011-12-24 Torvald Riegel <triegel@redhat.com>
240
241 * beginend.cc (GTM::gtm_thread::begin_transaction): Add comment.
242 (GTM::gtm_thread::try_commit): Changed memory order.
243 * config/linux/alpha/futex_bits.h (sys_futex0): Take atomic int
244 as parameter.
245 * config/linux/x86/futex_bits.h (sys_futex0): Same.
246 * config/linux/sh/futex_bits.h (sys_futex0): Same.
247 * config/linux/futex_bits.h (sys_futex0): Same.
248 * config/linux/futex.cc (futex_wait, futex_wake): Same.
249 * config/linux/futex.h (futex_wait, futex_wake): Same.
250 * config/linux/rwlock.h (gtm_rwlock::writers,
251 gtm_rwlock::writer_readers, gtm_rwlock::readers): Change to atomic
252 ints.
253 * config/linux/rwlock.cc (gtm_rwlock::read_lock,
254 gtm_rwlock::write_lock_generic, gtm_rwlock::read_unlock,
255 gtm_rwlock::write_unlock): Fix memory orders and fences.
256 * config/posix/rwlock.cc (gtm_rwlock::read_lock,
257 gtm_rwlock::write_lock_generic, gtm_rwlock::read_unlock,
258 gtm_rwlock::write_unlock): Same.
259 * config/linux/rwlock.h (gtm_rwlock::summary): Change to atomic int.
260 * method-gl.cc (gl_mg::init, gl_wt_dispatch::memtransfer_static,
261 gl_wt_dispatch::memset_static, gl_wt_dispatch::begin_or_restart):
262 Add comments.
263 (gl_wt_dispatch::pre_write, gl_wt_dispatch::validate,
264 gl_wt_dispatch::load, gl_wt_dispatch::store,
265 gl_wt_dispatch::try_commit, gl_wt_dispatch::rollback): Fix memory
266 orders and fences. Add comments.
267
268 2011-12-21 Jakub Jelinek <jakub@redhat.com>
269
270 * Makefile.am (AM_CXXFLAGS): Put $(XCFLAGS) first.
271 * Makefile.in: Regenerated.
272
273 2011-12-17 Kaz Kojima <kkojima@gcc.gnu.org>
274
275 * configure.tgt: Add sh* case.
276 * config/sh/target.h: New file.
277 * config/sh/sjlj.S: New file.
278 * config/linux/sh/futex_bits.h: New file.
279
280 2011-12-14 Richard Henderson <rth@redhat.com>
281
282 * config/arm/hwcap.h, config/arm/hwcap.cc: New files.
283 * config/arm/sjlj.S, config/arm/target.h: New files.
284 * config/generic/asmcfi.h (cfi_adjust_cfa_offset): New.
285 (cfi_rel_offset): New.
286 * config/linux/futex_bits.h: New file.
287 * config/linux/futex.cc: Include futex_bits.h here...
288 * config/linux/futex.h: ... not here.
289 * Makefile.am (libitm_la_SOURCES) <ARCH_ARM>: Add hwcap.cc.
290 * configure.ac (ARCH_AM): New conditional.
291 * Makefile.in, configure: Rebuild.
292 * configure.tgt: Handle ARM.
293
294 2011-12-13 Richard Henderson <rth@redhat.com>
295
296 * config/posix/rwlock.cc (gtm_rwlock::write_lock_generic): Fix
297 signed/unsigned comparison werror.
298
299 * local_atomic: New file.
300 * libitm_i.h: Include it.
301 (gtm_thread::shared_state): Use atomic template.
302 * beginend.cc (GTM::gtm_clock): Use atomic template.
303 (global_tid): Use atomic template if 64-bit atomics available.
304 (gtm_thread::gtm_thread): Update shared_state access.
305 (gtm_thread::trycommit): Likewise.
306 (choose_code_path): Update global_tid access.
307 * method-gl.cc (gl_mg::orec): Use atomic template. Update all users.
308 * stmlock.h (GTM::gtm_clock): Use atomic template.
309 (gtm_get_clock, gtm_inc_clock): Update accesses.
310 * config/linux/rwlock.cc (gtm_rwlock::read_lock): Remove
311 redundant __sync_synchronize after atomic shared_state access.
312 * config/posix/rwlock.cc (gtm_rwlock::read_lock): Likewise.
313 (gtm_rwlock::write_lock_generic): Likewise.
314 (gtm_rwlock::read_unlock): Likewise.
315 * config/alpha/target.h (atomic_read_barrier): Remove.
316 (atomic_write_barrier): Remove.
317 * config/x86/target.h (atomic_read_barrier): Remove.
318 (atomic_write_barrier): Remove.
319
320 2011-11-30 Richard Henderson <rth@redhat.com>
321
322 * libitm_i.h (GTM_longjmp): Swap first and second arguments.
323 * beginend.c (_ITM_abortTransaction): Update to match.
324 (GTM::gtm_thread::restart): Likewise.
325 * config/alpha/sjlj.S (GTM_longjmp): Likewise.
326 * config/x86/sjlj.S (GTM_longjmp): Likewise.
327
328 2011-11-23 Iain Sandoe <iains@gcc.gnu.org>
329
330 * Makefile.am (libitm_la_LDFLAGS): Remove "-no-undefined".
331 * Makefile.in: Regenerate.
332
333 2011-11-22 Iain Sandoe <iains@gcc.gnu.org>
334
335 * configure.ac: Use GCC_CHECK_ELF_STYLE_WEAKREF.
336 * alloc_cpp.cc: Generate dummy functions if we don't
337 HAVE_ELF_STYLE_WEAKREF.
338 * eh_cpp.cc: Likewise.
339 * configure: Regenerate.
340 * aclocal.m4: Likewise.
341 * config.h.in: Likewise.
342 * Makefile.in: Likewise.
343 * testsuite/Makefile.in: Likewise.
344
345 2011-11-22 Iain Sandoe <iains@gcc.gnu.org>
346
347 * config/x86/sjlj.S (CONCAT1, CONCAT2, SYM): Respond to
348 __USER_LABEL_PREFIX__ for targets that use it.
349 (TYPE, SIZE, HIDDEN): New macros to assist on non-elf targets.
350 (_ITM_beginTransaction): Use SYM, TYPE, SIZE macros to assist
351 in portability to non-elf targets.
352 (GTM_longjmp): Likewise.
353 * libitm_i.h (begin_transaction): Apply __USER_LABEL_PREFIX__
354 where required.
355
356 2011-11-22 Iain Sandoe <iains@gcc.gnu.org>
357
358 * testsuite/libitm.c/memcpy-1.c: Allow for MAP_ANON spelling.
359 * testsuite/libitm.c/memset-1.c: Likewise.
360
361 2011-11-21 Andreas Tobler <andreast@fgznet.ch>
362
363 * configure: Regenerate.
364
365 2011-11-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
366
367 * acinclude.m4 (LIBITM_CHECK_LINKER_FEATURES): Handle gold.
368 (LIBITM_ENABLE_SYMVERS): Handle sun style.
369 * Makefile.am: Handle sun style versioning.
370 (libitm_la_LINK): Add $(libitm_la_LDFLAGS).
371 * configure: Regenerate.
372 * Makefile.in: Regenerate.
373
374 2011-11-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
375
376 * config/generic/asmcfi.h: Fix comment.
377 * config/x86/sjlj.S (_ITM_beginTransaction): Provide ELF PIC code
378 sequence without .hidden support, error for non-ELF targets.
379 (GTM_longjmp) [__ELF__]: Only use .hidden if
380 HAVE_ATTRIBUTE_VISIBILITY.
381
382 2011-11-17 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
383
384 * alloc_cpp.cc [__osf__] (_ZnwX, _ZdlPv, _ZnaX, _ZdaPv,
385 _ZnwXRKSt9nothrow_t, _ZdlPvRKSt9nothrow_t, _ZdaPvRKSt9nothrow_t):
386 Dummy functions.
387 * eh_cpp.cc [__osf__] (__cxa_allocate_exception, __cxa_throw,
388 __cxa_begin_catch, __cxa_end_catch, __cxa_tm_cleanup): Likewise.
389
390 2011-11-16 Uros Bizjak <ubizjak@gmail.com>
391
392 PR bootstrap/51098
393 * acinclude.m4 (LIBITM_CHECK_AS_AVX): Fix target selector.
394 * configure: Regenerate.
395
396 2011-11-14 H.J. Lu <hongjiu.lu@intel.com>
397
398 * testsuite/lib/libitm.exp: Check ia32 instead of ilp32.
399
400 2011-11-10 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
401
402 * config/alpha/sjlj.S (_ITM_beginTransaction) [!__ELF__]: Don't use
403 .hidden.
404 (.note.GNU-stack): Only use if __linux__.
405 * alloc_cpp.cc [!__osf__] (_ZnaXRKSt9nothrow_t): Dummy function.
406 * testsuite/libitm.c/notx.c: Use dg-options "-pthread".
407 * testsuite/libitm.c/reentrant.c: Likewise.
408 * testsuite/libitm.c/simple-2.c: Likewise.
409 * testsuite/libitm.c/txrelease.c: Likewise.
410 * testsuite/libitm.c++/static_ctor.C: Likewise.
411
412 2011-11-10 Richard Henderson <rth@redhat.com>
413
414 * config/x86/x86_avx.cc: Remove #undef __AVX__ hack. Tidy comments.
415 * Makefile.am (x86_avx.lo): Only add -mavx if ARCH_X86_AVX.
416 * configure.ac (ARCH_X86_AVX): New conditional.
417 * Makefile.in, configure: Rebuild.
418
419 2011-11-09 Richard Henderson <rth@redhat.com>
420
421 * acinclude.m4 (LIBITM_CHECK_AS_AVX): New.
422 * configure.ac: Use it.
423 * config.h.in, configure: Rebuild.
424 * config/x86/x86_avx.cc: Handle !HAVE_AS_AVX.
425
426 2011-11-09 Richard Henderson <rth@redhat.com>
427
428 * barrier.tpl, memcpy.cc, memset.cc, method-wbetl.cc: Remove file.
429 * config/alpha/unaligned.h: Remove file.
430 * config/generic/unaligned.h: Remove file.
431 * config/x86/unaligned.h: Remove file.
432 * config/generic/cachepage.h: Remove file.
433 * config/posix/cachepage.cc: Remove file.
434 * config/generic/cacheline.cc: Remove file.
435 * config/x86/cacheline.cc: Remove file.
436 * config/generic/cacheline.h (gtm_cacheline): Remove the
437 store_mask, copy_mask, copy_mask_wb methods.
438 * config/x86/cacheline.h: Likewise.
439 * config/alpha/cacheline.h: Fall back to generic after setting size.
440 * config/generic/tls.cc (gtm_mask_stack): Remove.
441 * config/x86/x86_avx.cc (GTM_vpperm_shift): Remove.
442 (GTM_vpalignr_table): Remove.
443 * config/x86/x86_sse.cc (GTM_palignr_table): Remove.
444 (GTM_pshift_table): Remove.
445 * config/libitm_i.h: Don't include cachepage.h.
446 * Makefile.am (libitm_la_SOURCES): Remove cacheline.cc, cachepage.cc
447 * Makefile.in, testsuite/Makefile.in: Rebuild.
448
449 2011-11-09 Richard Henderson <rth@redhat.com>
450
451 * config/x86/cacheline.h (gtm_cacheline::store_mask): Use .byte
452 to emit branch prediction hint.
453
454 * config/x86/sjlj.S: Protect elf directives with __ELF__.
455 Protect .note.GNU-stack with __linux__.
456
457 * configure.ac (GCC_AS_CFI_PSEUDO_OP): Test it.
458 * configure, aclocal.m4, config.h.in: Rebuild.
459 * config/generic/asmcfi.h: New file.
460 * config/x86/sjlj.S: Use it.
461
462 2011-11-08 Richard Henderson <rth@redhat.com>
463
464 * local.cc (_ITM_LB): Use a normal call, not a function alias.
465
466 2011-11-08 Richard Henderson <rth@redhat.com>
467
468 * configure.tgt: Test correct directory for supported cpus.
469
470 * configure.ac: Exit if unsupported.
471 * configure: Rebuild.
472 * configure.tgt: Delete boilerplate from libgomp for unsupported
473 targets. Set UNSUPPORTED for unsupported targets.
474
475 2011-11-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
476
477 * configure.tgt: Handle i386 like i[456]86.
478 * config/generic/tls.h [!HAVE_ARCH_GTM_THREAD] (gtm_thr): Don't
479 take address.
480 * config/generic/tls.cc [!HAVE_ARCH_GTM_THREAD ||
481 !HAVE_ARCH_GTM_THREAD_DISP] (_gtm_thr_tls): New variable.
482
483 2011-11-05 Aldy Hernandez <aldyh@redhat.com>
484
485 * method-wbetl.cc: Update copyright notice.
486 * aatree.cc: Same.
487 * util.cc: Same.
488 * libitm.h: Same.
489 * memset.cc: Same.
490 * eh_cpp.cc: Same.
491 * barrier.tpl: Same.
492 * useraction.cc: Same.
493 * stmlock.h: Same.
494 * memcpy.cc: Same.
495 * common.h: Same.
496 * config/generic/tls.cc: Same.
497 * config/generic/cacheline.h: Same.
498 * config/generic/cachepage.h: Same.
499 * config/generic/cacheline.cc: Same.
500 * config/generic/unaligned.h: Same.
501 * config/x86/cacheline.h: Same.
502 * config/x86/cacheline.cc: Same.
503 * config/x86/unaligned.h: Same.
504 * config/alpha/cacheline.h: Same.
505 * config/alpha/unaligned.h: Same.
506 * config/alpha/sjlj.S: Same.
507 * config/posix/cachepage.cc: Same.
508 * config/linux/futex.h: Same.
509 * config/linux/alpha/futex_bits.h: Same.
510
511 2011-11-04 Torvald Riegel <triegel@redhat.com>
512
513 * libitm.texi: No cover text and invariant sections.
514
515 2011-11-03 Richard Henderson <rth@redhat.com>
516
517 * local_type_traits: New file.
518 * libitm_i.h: Use it. Use C headers, not C++ wrappers.
519
520 2011-11-03 Richard Henderson <rth@redhat.com>
521
522 * configure.ac: Don't test for gfortran.
523 * configure: Rebuild.
524
525 * testsuite/lib/libitm.exp: Don't include gfortran-dg.exp.
526 * testsuite/libitm.c++/c++.exp: Don't use gfortran-dg-runtest.
527
528 2011-11-03 Aldy Hernandez <aldyh@redhat.com>
529
530 * testsuite/libitm.c/memcpy-1.c: Add copyright notice.
531 * testsuite/libitm.c/memset-1.c: Same.
532 * testsuite/libitm.c/c.exp: Same.
533 * testsuite/lib/libitm-dg.exp: Same.
534 * testsuite/lib/libitm.exp: Same.
535 * testsuite/libitm.c++/c++.exp: Same.
536
537 2011-11-03 Aldy Hernandez <aldyh@redhat.com>
538
539 * testsuite/config/default.exp: Update copyright date.
540 * configure.ac: Add copyright info.
541 * configure.tgt: Same.
542
543 2011-11-03 Aldy Hernandez <aldyh@redhat.com>
544
545 * testsuite/libitm.c/reentrant.c: XFAIL.
546 * testsuite/libitm.c++/static_ctor.C: XFAIL.
547
548 2011-10-29 Torvald Riegel <triegel@redhat.com>
549
550 * beginend.cc (GTM::gtm_thread::rollback): Add aborting flag and
551 handle aborts.
552 (_ITM_abortTransaction): Handle aborts of outer transactions.
553 * libitm_i.h: Same.
554 * eh_cpp.cc (GTM::gtm_thread::revert_cpp_exceptions): Fix assertion.
555 * libitm.texi: Document aborts of outer transactions.
556 * testsuite/libitm.c/cancel.c: New file.
557
558 2011-10-19 Torvald Riegel <triegel@redhat.com>
559
560 * testsuite/*: Change __transaction to __transaction_atomic or
561 __transaction_relaxed.
562
563 2011-10-19 Torvald Riegel <triegel@redhat.com>
564
565 * config/linux/x86/tls.h (abi_disp): Make TLS slot read volatile.
566 (gtm_thr): Same.
567
568 2011-10-19 Torvald Riegel <triegel@redhat.com>
569
570 * libitm_i.h: Add gl_wt dispatch.
571 * retry.cc (parse_default_method): Same.
572 * method-gl.cc: New file.
573 * Makefile.am: Use method-gl.cc.
574 * Makefile.in: Rebuild.
575
576 2011-10-19 Torvald Riegel <triegel@redhat.com>
577
578 * beginend.cc (GTM::gtm_thread::trycommit): Ensure privatization
579 safety if requested by a TM method.
580 * dispatch.h (GTM::abi_dispatch::trycommit): Add parameter for
581 privatization safety.
582 * method-serial.cc: Same.
583
584 2011-10-19 Torvald Riegel <triegel@redhat.com>
585
586 * libitm_i.h: Renamed gtm_local_undo to gtm_undolog_entry.
587 (GTM::gtm_thread): Renamed local_undo to undolog. Renamed
588 undolog-related member functions from *_local to *_undolog.
589 * local.cc (gtm_thread::commit_undolog): Same.
590 * beginend.cc (GTM::gtm_thread::trycommit): Same.
591 (GTM::gtm_thread::rollback): Roll back undolog before
592 dispatch-specific rollback.
593
594 2011-10-19 Torvald Riegel <triegel@redhat.com>
595
596 * retry.cc (GTM::gtm_thread::decide_retry_strategy): Handle
597 re-initialization of the current method group.
598 * libitm_i.h (GTM::gtm_restart_reason): Add restart reason for this.
599
600 2011-10-19 Torvald Riegel <triegel@redhat.com>
601
602 * alloc.cc (commit_allocations_2): Do not free transaction-local
603 memory when committing a nested transaction.
604
605 2011-10-19 Torvald Riegel <triegel@redhat.com>
606
607 * method-serial.cc (GTM::gtm_thread::serialirr_mode): Fixed: Use
608 serial-irrevocable dispatch, not serial.
609
610 2011-10-19 Torvald Riegel <triegel@redhat.com>
611
612 * libitm_i.h (GTM::gtm_restart_reason): Re-arrange and clean up
613 declarations.
614 * dispatch.h (GTM::abi_dispatch::begin_or_restart): New.
615 * method-serial.cc: Implement begin_or_restart().
616 * beginend.cc (GTM::gtm_thread::begin_transaction): Call
617 dispatch-specific begin_or_restart().
618 (GTM::gtm_thread::restart): Same.
619
620 2011-08-23 Torvald Riegel <triegel@redhat.com>
621
622 * retry.cc (GTM::gtm_thread::decide_retry_strategy): Cleanup. Fix
623 restarting without switching to serial mode.
624 (GTM::gtm_thread::decide_begin_dispatch): Let the caller set the
625 transaction state. Choose closed-nesting alternative if available.
626 (GTM::gtm_thread::set_default_dispatch): New.
627 (parse_default_method): New.
628 (GTM::gtm_thread::number_of_threads_changed): New.
629 * method-serial.cc (GTM::serial_mg): New method group class.
630 (GTM::serialirr_dispatch): Belongs to serial_mg. Remove reinit and
631 fini.
632 (GTM::serial_dispatch): Same.
633 (GTM::serialirr_onwrite_dispatch): Same.
634 (GTM::gtm_thread::serialirr_mode): Remove calls to fini.
635 * beginend.cc (GTM::gtm_thread::~gtm_thread): Maintain number of
636 registered threads.
637 (GTM::gtm_thread::gtm_thread): Same.
638 (_ITM_abortTransaction): Remove calls to abi_dispatch::fini().
639 (GTM::gtm_thread::trycommit): Same. Reset number of restarts.
640 (GTM::gtm_thread::begin_transaction): Let decide_begin_dispatch()
641 choose dispatch but set state according to dispatch here.
642 * dispatch.h (GTM::abi_dispatch::fini): Move to method group.
643 (GTM::method_group): New class.
644 (GTM::abi_dispatch): Add comments. Maintain pointer to method_group.
645 * libitm_i.h (GTM::gtm_thread): Add declarations for new members.
646 * libitm.texi: Document TM methods, method groups, method life cycle.
647 Rename method sets to method groups.
648
649 2011-08-23 Torvald Riegel <triegel@redhat.com>
650
651 * config/x86/tls.h: Moved to ...
652 * config/linux/x86/tls.h: ... here.
653
654 2011-08-23 Torvald Riegel <triegel@redhat.com>
655
656 * config/x86/tls.h: Use __x86_64__ instead of __LP64__.
657 Add X32 support.
658 * config/x86/sjlj.S: Same.
659
660 2011-08-19 Torvald Riegel <triegel@redhat.com>
661
662 * config/linux/rwlock.h: New file.
663 * config/linux/rwlock.c: New file.
664 * configure.ac: Reenable futex support (undo SVN rev 157758).
665 * Makefile.am: Same.
666 * configure.tgt: Same.
667 * config/linux/alpha/futex_bits.h: Same.
668 * config/linux/futex.h: Same. Return number of woken processes.
669 * config/linux/futex.cc: Same.
670 (futex_wait): Remove spinning.
671 * config/linux/x86/futex_bits.h: Same. Set futex timeout to zero.
672 Use __x86_64__ instead of __LP64__.
673 * aclocal.m4: Include generic futex checks.
674 * configure: Rebuild.
675 * Makefile.in: Rebuild.
676 * testsuite/Makefile.in: Rebuild.
677 * beginend.cc: Include pthread.h.
678 * config/posix/cachepage.cc: Same.
679
680 2011-08-12 Torvald Riegel <triegel@redhat.com>
681
682 * config/x86/tls.h (gtm_tx, set_gtm_tx, setup_gtm_thr): Removed.
683 (abi_disp, set_abi_disp): Move to tx's TLS slot.
684 (set_gtm_thr): New.
685 * config/generic/tls.h (gtm_tx, set_gtm_tx, setup_gtm_thr): Removed.
686 (set_gtm_thr): New.
687 (GTM::gtm_thread::thread_num): Removed.
688 (GTM::gtm_thread): Renamed to GTM::gtm_thread_tls.
689 * libitm_i.h (GTM::gtm_transaction): Renamed to GTM::gtm_thread. More
690 tx-to-thread renaming.
691 * beginend.cc: Adapted to tx-to-thread renaming.
692 (GTM::gtm_thread::~gtm_thread): Extracted from thread_exit_handler().
693 (GTM::gtm_thread::gtm_thread): Extracted from begin_transaction().
694 * query.cc (_ITM_getTransactionId, _ITM_inTransaction): Renamed
695 gtm_transaction to gtm_thread.
696 (_ITM_getThreadnum): Removed. Not supported anymore.
697 * testsuite/libitm.c/notx.c (main): Removed _ITM_getThreadnum call.
698 * libitm.texi: Documented that _ITM_getThreadnum is not supported.
699 * useraction.cc: Renamed gtm_transaction to gtm_thread. Adapted to
700 gtm_tx-to-gtm_thr renaming if necessary.
701 * eh_cpp.cc: Same.
702 * local.cc: Same.
703 * retry.cc: Same.
704 * clone.cc: Same.
705 * alloc.cc: Same.
706 * alloc_c.cc: Same.
707 * alloc_cpp.cc: Same.
708 * method-serial.cc: Same.
709 * config/generic/tls.cc: Same.
710 * config/posix/rwlock.h (gtm_rwlock): Same.
711 * config/posix/rwlock.cc: Same. Adapted to more tx-to-thread renaming.
712
713 2011-08-12 Torvald Riegel <triegel@redhat.com>
714
715 * config/posix/rwlock.cc (gtm_rwlock::read_lock): Changed locking
716 implementation.
717 (gtm_rwlock::read_unlock): Same.
718 (gtm_rwlock::write_lock_generic): New. Generalized from ...
719 (gtm_rwlock::write_lock, gtm_rwlock::write_upgrade): ... these.
720 * libitm_i.h (GTM::gtm_transaction): Added shared_state.
721 * config/posix/rwlock.h (GTM::gtm_rwlock): Removed a_reader and
722 w_upgrade. Replaced by per-transaction flags (in shared_state).
723 Added c_confirmed_writers.
724 (GTM::gtm_rwlock::read_lock, GTM::gtm_rwlock::read_unlock,
725 GTM::gtm_rwlock::write_upgrade): Add tx parameter.
726 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Same.
727 * method-serial.cc (GTM::gtm_transaction::serialirr_mode): Same.
728 * beginend.cc (GTM::gtm_transaction::begin_transaction,
729 _ITM_abortTransaction, GTM::gtm_transaction::trycommit): Same.
730 * libitm.texi: Document locking conventions and implementations in
731 libitm.
732
733 2011-08-12 Torvald Riegel <triegel@redhat.com>
734
735 * libitm_i.h (next_tx): Add list of all threads' transaction.
736 * beginend.cc (GTM::gtm_transaction::begin_transaction): Register
737 transaction with list of transactions and ...
738 (thread_exit_handler): ... deregister here.
739 * config/alpha/target.h: Add HW_CACHELINE_SIZE setting.
740 * config/x86/target.h: Same.
741
742 2011-08-12 Torvald Riegel <triegel@redhat.com>
743
744 * testsuite/libitm.c++/static_ctor.C: New file.
745
746 2011-08-12 Torvald Riegel <triegel@redhat.com>
747
748 * testsuite/libitm.c/reentrant.c: New file.
749
750 2011-08-12 Torvald Riegel <triegel@redhat.com>
751
752 * config/generic/tls.h: Remove the free list for transactions and ...
753 * beginend.cc (GTM::gtm_transaction::operator new): ... allocate ...
754 (GTM::gtm_transaction::operator delete): ... and release here.
755 (thread_exit_handler): New. Delete tx when thread terminates.
756 (thread_exit_init): New.
757 (GTM::gtm_transaction::begin_transaction): Set up on-exit handler.
758 * testsuite/libitm.c/txrelease.c: New file.
759
760 2011-08-12 Torvald Riegel <triegel@redhat.com>
761
762 * query.cc (_ITM_getThreadnum): Set up gtm_thread if necessary.
763 * testsuite/libitm.c/notx.c: New file.
764
765 2011-08-12 Torvald Riegel <triegel@redhat.com>
766
767 * config/generic/tls.h (gtm_thread): Move local_tid from here ...
768 * libitm_i.h (local_tid): ... to here.
769 * beginend.cc (GTM::gtm_transaction::begin_transaction): Same.
770 (GTM::gtm_transaction::operator new): Set up gtm_thread if necessary.
771
772 2011-08-12 Torvald Riegel <triegel@redhat.com>
773
774 * retry.cc (GTM::gtm_transaction::decide_begin_dispatch): Use
775 serialirr_onwrite_dispatch as new default for now.
776 * method-serial.cc (serialirr_onwrite_dispatch): New.
777 (GTM::dispatch_serialirr_onwrite): New.
778 * libitm_i.h: Same.
779
780 2011-08-12 Torvald Riegel <triegel@redhat.com>
781
782 * beginend.cc (GTM::gtm_transaction::rollback): Roll back tx id as well.
783 * query.cc (_ITM_getTransactionId): There is no active transaction if
784 the current nesting level is zero.
785
786 2011-07-28 Torvald Riegel <triegel@redhat.com>
787
788 * beginend.cc (GTM::gtm_transaction::rollback): Fix nesting level
789 rollback.
790
791 2011-07-28 Torvald Riegel <triegel@redhat.com>
792
793 * retry.cc (GTM::gtm_transaction::decide_begin_dispatch): Get
794 transaction properties from the caller instead of from the
795 transaction object.
796 * libitm_i.h: Same.
797 * beginend.cc (GTM::gtm_transaction::begin_transaction): Same.
798
799 2011-07-28 Torvald Riegel <triegel@redhat.com>
800
801 * local.cc (gtm_transaction::rollback_local): Support closed nesting.
802 * eh_cpp.cc (GTM::gtm_transaction::revert_cpp_exceptions): Same.
803 * dispatch.h: Same.
804 * method-serial.cc: Same.
805 * beginend.cc (GTM::gtm_transaction::begin_transaction): Change to
806 flat nesting as default, and closed nesting on demand.
807 (GTM::gtm_transaction::rollback): Same.
808 (_ITM_abortTransaction): Same.
809 (GTM::gtm_transaction::restart): Same.
810 (GTM::gtm_transaction::trycommit): Same.
811 (GTM::gtm_transaction::trycommit_and_finalize): Removed.
812 (choose_code_path): New.
813 (GTM::gtm_transaction_cp::save): New.
814 (GTM::gtm_transaction_cp::commit): New.
815 * query.cc (_ITM_inTransaction): Support flat nesting.
816 * libitm_i.h (GTM::gtm_transaction_cp): New helper struct for nesting.
817 (GTM::gtm_transaction): Support flat and closed nesting.
818 * alloc.cc (commit_allocations_2): New.
819 (commit_cb_data): New helper struct.
820 (GTM::gtm_transaction::commit_allocations): Handle nested
821 commits/rollbacks.
822 * libitm.texi: Update user action section, add description of nesting.
823
824 2011-07-28 Torvald Riegel <triegel@redhat.com>
825
826 * libitm_i.h: Add closed nesting as restart reason.
827 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Same.
828
829 2011-07-28 Torvald Riegel <triegel@redhat.com>
830
831 * useraction.cc: Use vector instead of list to store actions.
832 Also support partial rollbacks for closed nesting.
833 * libitm_i.h (GTM::gtm_transaction::user_action): Same.
834 * beginend.cc: Same.
835
836 2011-07-28 Torvald Riegel <triegel@redhat.com>
837
838 * dispatch.h (GTM::abi_dispatch): Add can_run_uninstrumented_code and
839 closed_nesting flags, as well as a closed nesting alternative.
840 * method-serial.cc: Same.
841 (serial_dispatch): Renamed to serialirr_dispatch.
842 (GTM::dispatch_serialirr): Same.
843 (serial_dispatch_ul): Renamed to serial_dispatch.
844 (GTM::dispatch_serial): Same.
845
846 2011-07-28 Torvald Riegel <triegel@redhat.com>
847
848 * libitm.h (_ITM_codeProperties): Change pr_hasElse to the ABI's value.
849
850 2011-07-28 Torvald Riegel <triegel@redhat.com>
851
852 * aatree.h (aa_tree::remove): New.
853 (aa_tree::operator new): Add placement new.
854
855 2011-07-02 Torvald Riegel <triegel@redhat.com>
856
857 * containers.h: New file.
858 * util.cc (xmalloc, xrealloc): Accept cacheline-alloc flag.
859 * libitm_i.h (xmalloc, xrealloc): Moved declarations from here ...
860 * common.h: ... to here.
861 (local_undo): Use GTM::vector for gtm_transaction::local_undo.
862 * local.cc: Same.
863
864 2011-06-30 Torvald Riegel <triegel@redhat.com>
865
866 * libitm_i.h (STATE_ABORTING): Remove.
867 * beginend.cc (_ITM_abortTransaction): Same.
868 (GTM::gtm_transaction::trycommit_and_finalize): Same.
869 * libitm.h (_ITM_registerThrownObject, _ITM_tryCommitTransaction): Remove.
870 (_ITM_rollbackTransaction): Remove.
871 * beginend.cc: Same.
872 * libitm.map: Same.
873 * libitm.texi: Document these ABI changes.
874
875 2011-06-30 Torvald Riegel <triegel@redhat.com>
876
877 * libitm.texi: New file.
878 * Makefile.am: Add libitm.texi.
879 * Makefile.in: Rebuild.
880
881 2011-06-30 Torvald Riegel <triegel@redhat.com>
882
883 * libitm_i.h: Move parts to common.h and dispatch.h.
884 * common.h: New file.
885 * dispatch.h: New file, new dispatch class.
886 Rename GTM::abi_dispatch::lock_type to ls_modifier.
887 RenameGTM::abi_dispatch::NOLOCK to NONTXNAL.
888 * beginend.cc (GTM::gtm_transaction::begin_transaction): Delegate mode
889 decision to retry.cc.
890 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Use serial mode
891 only.
892 (GTM::gtm_transaction::decide_begin_dispatch): Same.
893 * method-serial.cc: Adapt to new dispatch. Add serial mode with undo
894 logging.
895 * barrier.cc: Use new barriers definitions.
896 (abi_dispatch::memmove_overlap_check): New.
897 * config/x86/x86_sse.cc: Same.
898 * config/x86/x86_avx.cc: Same.
899 * Makefile.am: Don't build readonly and wbetl methods, memset.cc and
900 memcpy.cc.
901 * Makefile.in: Rebuild.
902 * method-readonly.cc: Remove.
903 * method-wbetl.cc: Rename GTM::abi_dispatch::lock_type to ls_modifier.
904 Rename GTM::abi_dispatch::NOLOCK to NONTXNAL.
905
906 2011-06-30 Torvald Riegel <triegel@redhat.com>
907
908 * alloc_c.cc (_ITM_dropReferences): Don't support it anymore.
909 * testsuite/libitm.c++/dropref.C: _ITM_dropReferences is expected to fail.
910 * testsuite/libitm.c/dropref-2.c: Same.
911 * testsuite/libitm.c/dropref.c: Same.
912
913 2011-06-30 Torvald Riegel <triegel@redhat.com>
914
915 * config/generic/tls.h (gtm_disp): Rename to abi_disp.
916 * config/generic/tls.h (set_gtm_disp): Rename to set_abi_disp.
917 * libitm_i.h: Rename gtm_dispatch to abi_dispatch.
918 * alloc_c.cc: Same.
919 * barrier.tpl: Same.
920 * beginend.c: Same.
921 * config/generic/tls.h: Same.
922 * config/x86/tls.h: Same.
923 * libitm_i.h: Same.
924 * memcpy.cc: Same.
925 * memset.cc: Same.
926 * method-readonly.cc: Same.
927 * method-serial.cc: Same.
928 * method-wbetl.cc: Same.
929 * retry.cc: Same.
930
931 2011-03-03 Richard Henderson <rth@redhat.com>
932
933 * config/posix/rwlock.cc (write_upgrade): Add missing case.
934 From Patrik Marlier <patrick.marlier@unine.ch>.
935
936 2011-02-03 Richard Henderson <rth@redhat.com>
937
938 * acinclude.m4 (LIBITM_CHECK_SIZE_T_MANGLING): New.
939 * configure.ac: Use it.
940 * configure, config.h.in: Rebuild.
941 * alloc_cpp.cc (_ZnwX): Use MANGLE_SIZE_T in constructing the name.
942 (_ZnaX, _ZnwXRKSt9nothrow_t, _ZnaXRKSt9nothrow_t, _ZGTtnwX,
943 _ZGTtnaX, _ZGTtnwXRKSt9nothrow_t, _ZGTtnaXRKSt9nothrow_t): Likewise.
944 * libitm.map: Use wildcards to match size_t mangling.
945
946 2010-12-14 Richard Henderson <rth@redhat.com>
947
948 * beginend.cc (GTM::gtm_transaction::begin_transaction): Allocate
949 blocks of TIDs per thread.
950 * config/generic/tls.h (struct gtm_thread): Add local_tid member.
951 (setup_gtm_thr): Return the thread structure.
952 * config/x86/tls.h (setup_gtm_thr): Likewise.
953
954 2010-12-14 Richard Henderson <rth@redhat.com>
955
956 * clone.cc (table_lock): Remove.
957 (find_clone): Don't take it.
958 (ExcludeTransaction): New helper class.
959 (_ITM_registerTMCloneTable): Use it.
960 (_ITM_deregisterTMCloneTable): Likewise.
961
962 2010-12-14 Richard Henderson <rth@redhat.com>
963
964 * config/x86/tls.h: New file.
965
966 2010-07-15 Richard Henderson <rth@redhat.com>
967
968 * Makefile.am (AM_CXXFLAGS): Add -funwind-tables.
969 * Makefile.in: Rebuild.
970
971 2010-07-13 Aldy Hernandez <aldyh@redhat.com>
972
973 * method-wbetl.cc (trydropreference): Fix source line.
974
975 2010-07-13 Aldy Hernandez <aldyh@redhat.com>
976
977 * libitm.h: Add comment.
978 * libitm_i.h (begin_transaction): Add ITM_REGPARM.
979
980 2010-07-07 Aldy Hernandez <aldyh@redhat.com>
981
982 * configure.ac: Call LIBITM_CHECK_64BIT_SYNC_BUILTINS.
983 * beginend.cc (begin_transaction): If 64-bit sync builtins are not
984 available, use pthread mutexes.
985 * acinclude.m4 (LIBITM_CHECK_64BIT_SYNC_BUILTINS): New.
986 * config.h.in: Regenerate.
987 * configure: Regenerate.
988
989 2010-07-06 Aldy Hernandez <aldyh@redhat.com>
990
991 * libitm.h (ITM_PURE): Define.
992 Declare _ITM_malloc, _ITM_calloc, and _ITM_free.
993
994 2010-06-28 Aldy Hernandez <aldyh@redhat.com>
995
996 * method-wbetl.cc (class wbetl_dispatch): Add trydropreference.
997 (validate): Add comment.
998 (trydropreference): New.
999 * method-readonly.cc (class readonly_dispatch): Add
1000 trydropreference.
1001 * alloc_c.cc (_ITM_dropReferences): Remove const attribute.
1002 Call trydropreference().
1003 * libitm.h (_ITM_dropReferences): Remove const attribute.
1004 * method-serial.cc (class serial_dispatch): Add trydropreference.
1005 * libitm_i.h (struct gtm_dispatch): Add trydropreference.
1006
1007 2010-06-28 Aldy Hernandez <aldyh@redhat.com>
1008
1009 * memcpy.cc (do_memcpy): Comment.
1010
1011 2010-06-25 Aldy Hernandez <aldyh@redhat.com>
1012
1013 * barrier.tpl: Add comments throughout.
1014
1015 2010-06-24 Aldy Hernandez <aldyh@redhat.com>
1016
1017 * method-wbetl.cc (struct w_entry): Add comments.
1018 (trycommit): Same.
1019 (rollback): Same.
1020
1021 2010-06-24 Aldy Hernandez <aldyh@redhat.com>
1022
1023 * alloc_c.cc (_ITM_dropReferences): New.
1024 * libitm.map (_ITM_dropReferences): Add.
1025 * libitm.h (_ITM_dropReferences): Add transaction_pure attribute.
1026 * libitm_i.h (struct gtm_transaction): Declare
1027 drop_references_allocations and drop_references_local.
1028 * local.cc (rollback_local): Ignore memory when applicable.
1029 (drop_references_local): New.
1030
1031 2010-06-23 Richard Henderson <rth@redhat.com>
1032
1033 * barrier.tpl, beginend.cc, clone.cc, tls.h, memcpy.cc,
1034 memset.cc, method-serial.cc: Revert the 2010-06-16 change.
1035 * config/x86/target.h (struct gtm_jmpbuf): Change CFA type to void*.
1036 * config/alpha/target.h: Likewise.
1037 * config/generic/tls.cc (gtm_mask_stack): Use it.
1038
1039 2010-06-23 Richard Henderson <rth@redhat.com>
1040
1041 * config/posix/cachepage.cc (gtm_cacheline_page::operator new): Use
1042 a mutex instead of trying a lock-free compare-and-swap on the list.
1043 (gtm_cacheline_page::operator delete): Likewise.
1044
1045 2010-06-16 Richard Henderson <rth@redhat.com>
1046
1047 * method-wbetl.cc (wbetl_dispatch::trycommit): Discard changes
1048 that overlap the libitm stack.
1049 * barrier.tpl: Mark incoming stack.
1050 * beginend.cc (_ITM_rollbackTransaction, _ITM_abortTransaction,
1051 _ITM_commitTransaction, _ITM_commitTransactionEH): Likewise.
1052 * clone.cc (_ITM_getTMCloneOrIrrevocable): Likewise.
1053 * memcpy.cc, memset.cc: Likewise.
1054 * method-serial.cc (_ITM_changeTransactionMode): Likewise.
1055 * config/generic/tls.h (gtm_thread): Add stack_top member.
1056 (gtm_stack_top, set_gtm_stack_top, struct gtm_stack_marker): New.
1057 * libitm_i.h (gtm_mask_stack): Declare.
1058 * config/generic/tls.cc: New file.
1059 * Makefile.am (libitm_la_SOURCES): Add it.
1060 (AM_CXXFLAGS): Turn off exceptions.
1061 * Makefile.in: Rebuild.
1062
1063 2010-06-16 Richard Henderson <rth@redhat.com>
1064
1065 * alloc.cc (struct gtm_alloc_action): Move definition ...
1066 * libitm_i.h: ... here.
1067 (class gtm_transaction): Declare new and delete.
1068 * beginend.cc (alloc_tx): Reformulate as operator new.
1069 (free_tx): Reformulate as operator delete.
1070 * config/generic/tls.h (gtm_thread): Change free_tx member to void *.
1071
1072 2010-06-11 Richard Henderson <rth@redhat.com>
1073
1074 * clone.cc (clone_entry_compare): Fix typo.
1075 From Patrik Marlier <patrick.marlier@unine.ch>.
1076
1077 2010-05-13 Richard Henderson <rth@redhat.com>
1078
1079 * alloc_c.cc (_ITM_malloc, _ITM_calloc, _ITM_free): Wrap functions
1080 in extern "C".
1081
1082 2010-05-07 Aldy Hernandez <aldyh@redhat.com>
1083
1084 * libitm_i.h (struct gtm_transaction): Remove
1085 get_allocation_size.
1086 (record_allocation): Remove size parameter.
1087 * libitm.map (_ITM_realloc): Remove.
1088 * alloc_c.cc (_ITM_realloc): Remove.
1089 (_ITM_malloc): Remove size argument to record_allocation.
1090 (_ITM_calloc): Same.
1091 * alloc_cpp.cc (_ZGTtnwm): Same.
1092 (_ZGTtnwmRKSt9nothrow_t): Same.
1093 (_ZGTtnam): Same.
1094 (_ZGTtnamRKSt9nothrow_t): Same.
1095 * alloc.cc (struct gtm_alloc_action): Remove size.
1096 (get_allocation_size): Remove.
1097 (commit_allocations): Add comment.
1098 (record_allocation): Remove size parameter.
1099 (forget_allocation): Remove set of size.
1100
1101 2010-04-19 Aldy Hernandez <aldyh@redhat.com>
1102
1103 * Makefile.am (abi_version): New.
1104 (AM_CXXFLAGS): Pass abi_version.
1105 * Makefile.in: Regenerate.
1106 * config/x86/unaligned.h: Remove always_inline kludge for vectors.
1107
1108 2010-04-06 Aldy Hernandez <aldyh@redhat.com>
1109
1110 * clone.cc (_ITM_getTMCloneOrIrrevocable): Rename from
1111 _ITM_getTMCloneOrIrrevokable.
1112 * libitm.h (_ITM_getTMCloneOrIrrevocable): Same.
1113 * libitm.map (_ITM_getTMCloneOrIrrevocable): Same.
1114
1115 2010-03-26 Aldy Hernandez <aldyh@redhat.com>
1116
1117 * configure.ac: Remove Linux futex support.
1118 * configure.tgt (config_path): Same.
1119 * Makefile.am: Same.
1120 * config/linux: Remove entire directory.
1121 * configure: Rebuild.
1122 * Makefile.in: Rebuild.
1123 * testsuite/Makefile.in: Rebuild.
1124
1125 2010-03-09 Aldy Hernandez <aldyh@redhat.com>
1126
1127 * retry.cc (decide_retry_strategy): Set state to STATE_SERIAL when
1128 switching to serial mode.
1129 * beginend.cc (trycommit_and_finalize): Unlock serial_lock.
1130
1131 2010-03-03 Aldy Hernandez <aldyh@redhat.com>
1132
1133 * configure.tgt: Add emacs -*- tags.
1134 * barrier.tpl: Same.
1135
1136 2010-02-23 Aldy Hernandez <aldyh@redhat.com>
1137
1138 * Makefile.am: Rename serial.cc to method-serial.cc.
1139 * Makefile.in: Regenerate with automake 1.11.1.
1140 * testsuite/Makefile.in: Same.
1141 * aclocal.m4: Regenerate with aclocal 1.11.1.
1142 * method-serial.cc: Rename from serial.cc.
1143 * libitm_i.h (struct gtm_transaction): Update comment on
1144 serialirr_mode.
1145
1146 2010-02-22 Aldy Hernandez <aldyh@redhat.com>
1147
1148 * libitm_i.h (GTM_longjmp): Add ITM_REGPARM.
1149 * config/linux/rwlock.h (class gtm_rwlock): Add comments.
1150
1151 2010-02-11 Aldy Hernandez <aldyh@redhat.com>
1152
1153 * configure: Rebuild.
1154
1155 2009-11-12 Richard Henderson <rth@redhat.com>
1156
1157 * Rewrite everything in C++.
1158
1159 2009-11-03 Richard Henderson <rth@redhat.com>
1160
1161 * config/x86/x86_sse.c, config/x86/x86_avx.c: New files.
1162 * Makefile.am (libitm_la_SOURCES): Add them.
1163 * configure.ac (ARCH_X86): New conditional.
1164 * Makefile.in, configure: Rebuild.
1165 * configure.tgt: Set up ARCH; do cflags setup at the same time.
1166 Move futex setup into "other system configury" case.
1167 * local.c (rollback_local): Merge into ...
1168 (GTM_rollback_local): ... here.
1169 (GTM_LB): Rename from GTM_alloc_local; do the memcpy here.
1170 (_ITM_LB): Define as an alias to GTM_LB.
1171
1172 2009-11-03 Richard Henderson <rth@redhat.com>
1173
1174 * method-readonly.c: New file.
1175 * Makefile.am (libitm_la_SOURCES): Add it.
1176 * Makefile.in: Rebuild.
1177 * beginend.c (gtm_stmlock_array, gtm_clock): New.
1178 (GTM_begin_transaction): Use dispatch_readonly for read-only txn.
1179 * libitm_i.h (gtm_stmlock, gtm_version): Move from method-wbetl.c.
1180 (GTM_VERSION_MAX, GTM_VERSION_INVALID, gtm_stmlock_owned_p,
1181 gtm_stmlock_set_owned, gtm_stmlock_get_addr,
1182 gtm_stmlock_get_version, gtm_stmlock_set_version, LOCK_ARRAY_SIZE,
1183 gtm_stmlock_array, gtm_get_stmlock, gtm_clock, RESTART_NOT_READONLY,
1184 gtm_get_clock, gtm_inc_clock): New.
1185 * method-wbetl.c (gtm_version, gtm_stmlock, OWNED_MASK, VERSION_MAX,
1186 LOCK_GET_OWNED, LOCK_SET_ADDR, LOCK_GET_ADDR, LOCK_GET_TIMESTAMP,
1187 LOCK_SET_TIMESTAMP, LOCK_ARRAY_SIZE, LOCK_MASK, LOCK_IDX, GET_LOCK,
1188 locks, gclock, CLOCK, GET_CLOCK, FETCH_AND_INC_CLOCK): Remove and
1189 replace uses with new libitm_i.h symbols.
1190 (dispatch_wbetl): Rename from wbetl_dispatch.
1191 * retry.c (GTM_decide_retry_strategy): If RESTART_NOT_READONLY, move
1192 away from dispatch_readonly; abort if the beginTransaction call
1193 asserted that the transaction was readonly.
1194
1195 2009-11-03 Richard Henderson <rth@redhat.com>
1196
1197 * memset.c: New file.
1198 * Makefile.am (libitm_la_SOURCES): Add it.
1199 * Makefile.in: Rebuild.
1200 * testsuite/libitm.c/memset-1.c: New.
1201
1202 2009-11-03 Richard Henderson <rth@redhat.com>
1203
1204 * dispatch.c: Remove file.
1205 * useraction.c (struct gtm_user_action): Move from libitm.h.
1206 * serial.c (GTM_null_read_lock, GTM_null_write_lock): New.
1207 (serial_memset, serial_memmove, serial_memcpy): Remove.
1208 (serial_W*, serial_R*): Remove.
1209 (serial_dispatch): Update to match.
1210 * configure.ac: Move Werror down below configure checks. Don't
1211 check for sys/loadavg.h, do check for malloc.h. Don't check for
1212 getloadavg and clock_gettime; do check for memalign, posix_memalign.
1213 Use GCC_AC_FUNC_MMAP_BLACKLIST
1214 * libitm.h: Split out all internal items to...
1215 * libitm_i.h: ... here. New file.
1216 * copymask.c: New file.
1217 * local.c (struct gtm_local_undo): Move from libitm.h.
1218 (GTM_alloc_local): Rename from alloc_local; export.
1219 * memcpy.c: New file.
1220 * alloc_c.c (_ITM_realloc): Use _ITM_memcpyRnWt directly.
1221 * config/posix/page.c: New file.
1222 * config/posix/target_tls.h: Remove file.
1223 * barrier.c: New file.
1224 * Makefile.am (libitm_la_SOURCES): Add barrier.c, memcpy.c,
1225 copymask.c, page.c.
1226 * alloc.c (struct gtm_alloc_action): Move from libitm.h.
1227 * method-wbetl.c: Rewrite for new cacheline methods.
1228 * Makefile.in, configure, testsuite/Makefile.in, config.h.in: Rebuild.
1229
1230 * config/alpha/sjlj.S: Fix typo.
1231 * config/alpha/target_i.h: Copy functions from alpha/target.h.
1232 * config/alpha/copymask.c: New file.
1233 * config/alpha/target.h (CACHELINE_SIZE): New.
1234 (STRICT_ALIGNMENT, PAGE_SIZE, FIXED_PAGE_SIZE): New.
1235
1236 * config/x86/target_i.h: Copy functions from x86/target.h.
1237 * config/x86/copymask.c: New file.
1238 * config/x86/target.h (_ITM_ALL_TARGET_TYPES): Remove.
1239 (CACHELINE_SIZE, STRICT_ALIGNMENT): New.
1240 (PAGE_SIZE, FIXED_PAGE_SIZE): New.
1241 * config/x86/target_tls.h: Move contents to target_i.h.
1242
1243 * testsuite/libitm.c/clone-1.c: Include libitm.h.
1244 * testsuite/libitm.c/memcpy-1.c: New.
1245
1246 2009-10-22 Richard Henderson <rth@redhat.com>
1247
1248 * Makefile.am (CCAS, CCASFLAGS, LTCCASCOMPILE): Remove.
1249 (AM_CCASFLAGS): New.
1250 * configure.ac: Add AM_PROG_AS. Use m4_rename_force for
1251 saving/restoring _AC_ARG_VAR_PRECIOUS.
1252 * Makefile.in, aclocal.m4, config.h.in, configure,
1253 testsuite/Makefile.in: Rebuild with automake 1.11; autoconf 2.64.
1254
1255 2009-10-22 Richard Henderson <rth@redhat.com>
1256
1257 * testsuite/*: Update for new compiler syntax.
1258
1259 2009-10-21 Richard Henderson <rth@redhat.com>
1260
1261 * libitm.h (_ITM_abortReason): Add outerAbort.
1262
1263 2009-08-03 Richard Henderson <rth@redhat.com>
1264
1265 * libitm.map (_ITM_commitTransactionEH, _ITM_cxa_allocate_exception,
1266 _ITM_cxa_begin_catch, _ITM_cxa_end_catch, _ITM_cxa_throw): Export.
1267 * method-wbetl.c (struct w_entry): Remove mask.
1268 (wbetl_write, wbetl_load): Return pointer to word containing the data;
1269 adjust all callers.
1270
1271 2009-07-22 Richard Henderson <rth@redhat.com>
1272
1273 * eh_cpp.c: New file.
1274 * Makefile.am (libitm_la_SOURCES): Add it.
1275 * Makefile.in: Rebuild.
1276 * beginend.c (GTM_rollback_transaction): Undo exception state.
1277 (GTM_trycommit_transaction): Mark inline.
1278 (GTM_trycommit_and_finalize_transaction): Split out from ...
1279 (_ITM_commitTransaction): ... here.
1280 (_ITM_commitTransactionEH): New function.
1281 * libitm.h (struct gtm_transaction): Add cxa_catch_count,
1282 cxa_unthrown, eh_in_flight; reorder.
1283
1284 * testsuite/libitm.c++/c++.exp: New.
1285 * testsuite/libitm.c++/eh-1.C: New.
1286
1287 * aatree.c (aa_free): Remove REGPARM.
1288 * aatree.h: Remove all REGPARM.
1289
1290 2009-07-18 Richard Henderson <rth@redhat.com>
1291
1292 * aatree.c, aatree.h, alloc.c, alloc_c.c, alloc_cpp.c: New files.
1293 * Makefile.am (libitm_la_SOURCES): Add them.
1294 * Makefile.in: Rebuild.
1295 * beginend.c (GTM_rollback_transaction): Use GTM_commit_allocations.
1296 (GTM_trycommit_transaction): Likewise.
1297 * libitm.h: Include aatree.h
1298 (struct gtm_alloc_action): New.
1299 (struct gtm_transaction): Add alloc_actions.
1300 (GTM_record_allocation, GTM_forget_allocation): Declare.
1301 (GTM_get_allocation_size, GTM_commit_allocations): Declare.
1302 * libitm.map (_ITM_malloc, _ITM_calloc, _ITM_realloc, _ITM_free,
1303 _ZGTtnwm, _ZGTtnam, _ZGTtdlPv, _ZGTtdaPv, _ZGTtnwmRKSt9nothrow_t,
1304 _ZGTtnamRKSt9nothrow_t, _ZGTtdlPvRKSt9nothrow_t,
1305 _ZGTtdaPvRKSt9nothrow_t): Export.
1306
1307 2009-07-18 Richard Henderson <rth@redhat.com>
1308
1309 * target_tls.h: Move ...
1310 * config/posix/target_tls.h: ... here.
1311
1312 2009-07-07 Richard Henderson <rth@redhat.com>
1313
1314 * config/x86/target.h (atomic_write_barrier): Use sfence if available.
1315
1316 2009-07-07 Richard Henderson <rth@redhat.com>
1317
1318 * Update to GPL3.
1319
1320 2009-07-07 Richard Henderson <rth@redhat.com>
1321
1322 * libitm.h (struct gtm_transaction): Widen id to _ITM_transactionId_t.
1323 * beginend.c (global_tid): Widen to _ITM_transactionId_t.
1324
1325 * configure.tgt: Don't use -ftls-model for x86 linux.
1326 * libitm.h: Include target.h after standard includes.
1327 (_gtm_thr): Rename from gtm_thr.
1328 (setup_gtm_thr, gtm_thr, gtm_tx, set_gtm_tx): New.
1329 (gtm_disp, set_gtm_disp): New.
1330 * beginend.c, dispatch.c, local.c, method-wbetl.c, query.c,
1331 retry.c, serial.c, useraction.c: Use accessor functions throughout.
1332 * config/alpha/target_tls.h, config/x86/target_tls.h: New files.
1333
1334 2009-07-07 Richard Henderson <rth@redhat.com>
1335
1336 * config/linux/rwlock.c (EZ): New define. Use it throughout.
1337
1338 2009-07-06 Richard Henderson <rth@redhat.com>
1339
1340 * libitm.h (_ITM_SRCLOCATION_DECL_1, _ITM_SRCLOCATION_DECL_2): Remove.
1341 (_ITM_SRCLOCATION_DEFN_1, _ITM_SRCLOCATION_DEFN_2): Remove.
1342 (_ITM_beginTransaction): Take variadic arguments.
1343 (_ITM_registerThrownObject): Declare.
1344 * beginend.c, serial.c: Update.
1345 * libitm.map: Add _ITM_registerThrownObject.
1346
1347 2009-01-28 Richard Henderson <rth@redhat.com>
1348
1349 * Makefile.am (libitm_la_SOURCES): Add clone.c.
1350 * Makefile.in: Rebuild.
1351 * beginend.c (_ITM_abortTransaction): Abort if irrevokable.
1352 (GTM_restart_transaction): Fix uninstrumented code check.
1353 * retry.c (GTM_decide_retry_strategy): Add serial check.
1354 * serial.c (GTM_serialmode): Add irrevokable variable. Don't
1355 automatically go irrevokable when in serial mode.
1356 * clone.c: New file.
1357 * libitm.h, libitm.map: Update.
1358
1359 2009-01-27 Richard Henderson <rth@redhat.com>
1360
1361 * Makefile.am (LTCCASCOMPILE): Define.
1362 (libitm_la_SOURCES): Add methid-wbetl.c.
1363 * testsuite/Makefile.am: New
1364 * configure.ac: Add testsuite/Makefile.
1365 * Makefile.in, testsuite/Makefile.in, configure: Regenerate.
1366 * beginend.c (GTM_begin_transaction): Install wbetl_dispatch.
1367 (_ITM_abortTransaction): Finalize implementation method; pass
1368 transaction properties to longjmp.
1369 (GTM_restart_transaction): Split out from ...
1370 (_ITM_commitTransaction): ... here.
1371 * config/linux/x86/futex_bits.h (cpu_relax, atomic_write_barrier):
1372 Move to config/x86/target.h.
1373 * config/linux/alpha/futex_bits.h: New.
1374 * config/x86/sjlj.S (GTM_longjmp): Fix 64-bit input register.
1375 * config/x86/target.h: Disable target types for 32-bit.
1376 * config/alpha/sjlj.S, config/alpha/target.h: New.
1377 * libitm.h (struct gtm_dispatch): Add init, fini.
1378 (enum restart_reason): New.
1379 (struct gtm_transaction): Add method and restarts.
1380 * retry.c (GTM_decide_retry_strategy): Implement.
1381 * serial.c (serial_init, serial_fini): New.
1382 (GTM_serialmode): Finialize outgoing method.
1383 * method-wbetl.c: New.
1384
1385 2008-12-09 Richard Henderson <rth@redhat.com>
1386
1387 * config/x86/target.h (_ITM_ALL_TARGET_TYPES, _ITM_TYPE_ATTR): New.
1388 * configure.tgt (i386-*, x86_64-*): Don't force SSE.
1389 * dispatch.c (_ITM_##R##T, _ITM_##W##T): Use _ITM_TYPE_ATTR.
1390 * libitm.h (_ITM_ALL_TARGET_TYPES, _ITM_TYPE_ATTR): Provide default.
1391 (_ITM_TYPE_M64, _ITM_TYPE_M128, _ITM_TYPE_M256): Move to x86 header.
1392 (_ITM_ALL_TYPES): Use _ITM_ALL_TARGET_TYPES.
1393 * local.c (_ITM_L##T): Use _ITM_TYPE_ATTR.
1394 * serial.c (serial_R##T, serial_W##T): Likewise.
1395
1396 2008-11-21 Richard Henderson <rth@redhat.com>
1397
1398 * Initial commit.