1 2012-01-14 Torvald Riegel <triegel@redhat.com>
4 * config/generic/tls.h (GTM::mask_stack_top): New.
5 (GTM::mask_stack_bottom): Declare.
6 * config/generic/tls.c (GTM::mask_stack_bottom): New.
7 * local.cc (gtm_undolog::rollback): Filter out any updates that
8 overlap the libitm stack. Add current transaction as parameter.
9 * libitm_i.h (GTM::gtm_undolog::rollback): Adapt.
10 * beginend.cc (GTM::gtm_thread::rollback): Adapt.
11 * testsuite/libitm.c/stackundo.c: New test.
13 2012-01-10 Richard Henderson <rth@redhat.com>
15 * libitm_i.h (_Unwind_DeleteException): Declare weak.
16 * eh_cpp.cc (_Unwind_DeleteException): Define for
17 !HAVE_ELF_STYLE_WEAKREF.
19 2012-01-08 Torvald Riegel <triegel@redhat.com>
21 * local.cc (GTM_LB): Use GTM::gtm_undolog.
22 (GTM::gtm_thread::drop_references_undolog): Remove.
23 (GTM::gtm_thread::commit_undolog,
24 GTM::gtm_thread::rollback_undolog): Move to ...
25 * libitm_i.h (GTM::gtm_undolog): ...here. New.
26 (GTM::gtm_undolog_entry): Remove.
27 (GTM::gtm_thread): Adapt.
28 * beginend.cc (GTM::gtm_thread::rollback): Adapt.
29 (GTM::gtm_thread::trycommit): Adapt.
30 * method-serial.cc (serial_dispatch::log): Adapt.
31 * method-gl.cc (gl_wt_dispatch::pre_write): Adapt.
32 (gl_wt_dispatch::store): Fix likely/unlikely.
33 * containers.h (GTM::vector::resize): Add additional_capacity
34 parameter and handle it.
35 (GTM::vector::resize_noinline): New/adapt.
36 (GTM::vector::push): New.
38 2012-01-06 Richard Henderson <rth@redhat.com>
40 * configure.tgt: Support powerpc-linux and powerpc-darwin.
41 * config/linux/powerpc/futex_bits.h: New file.
42 * config/powerpc/cacheline.h: New file.
43 * config/powerpc/sjlj.S: New file.
44 * config/powerpc/target.h: New file.
45 * config/generic/asmcfi.h (cfi_offset): New.
46 (cfi_restore, cfi_undefined): New.
48 2012-01-05 Aldy Hernandez <aldyh@redhat.com>
51 * testsuite/libitm.c/reentrant.c: Remove xfail.
52 (thread): Pass x to pure().
53 From Patrik Marlier <patrick.marlier@gmail.com>.
55 2011-12-24 Torvald Riegel <triegel@redhat.com>
57 * beginend.cc (GTM::gtm_thread::trycommit): Don't enforce
58 privatization safety if already in serial mode.
60 2011-12-24 Torvald Riegel <triegel@redhat.com>
62 * beginend.cc (GTM::gtm_thread::restart): Add and handle
63 finish_serial_upgrade parameter.
64 * libitm.h (GTM::gtm_thread::restart): Adapt declaration.
65 * config/linux/rwlock.cc (GTM::gtm_rwlock::write_lock_generic):
66 Don't unset reader flag.
67 (GTM::gtm_rwlock::write_upgrade_finish): New.
68 * config/posix/rwlock.cc: Same.
69 * config/linux/rwlock.h (GTM::gtm_rwlock::write_upgrade_finish):
71 * config/posix/rwlock.h: Same.
72 * method-serial.cc (GTM::gtm_thread::serialirr_mode): Unset reader
73 flag after commit or after rollback when restarting.
75 2011-12-24 Torvald Riegel <triegel@redhat.com>
77 * beginend.cc (GTM::gtm_thread::begin_transaction): Add comment.
78 (GTM::gtm_thread::try_commit): Changed memory order.
79 * config/linux/alpha/futex_bits.h (sys_futex0): Take atomic int
81 * config/linux/x86/futex_bits.h (sys_futex0): Same.
82 * config/linux/sh/futex_bits.h (sys_futex0): Same.
83 * config/linux/futex_bits.h (sys_futex0): Same.
84 * config/linux/futex.cc (futex_wait, futex_wake): Same.
85 * config/linux/futex.h (futex_wait, futex_wake): Same.
86 * config/linux/rwlock.h (gtm_rwlock::writers,
87 gtm_rwlock::writer_readers, gtm_rwlock::readers): Change to atomic
89 * config/linux/rwlock.cc (gtm_rwlock::read_lock,
90 gtm_rwlock::write_lock_generic, gtm_rwlock::read_unlock,
91 gtm_rwlock::write_unlock): Fix memory orders and fences.
92 * config/posix/rwlock.cc (gtm_rwlock::read_lock,
93 gtm_rwlock::write_lock_generic, gtm_rwlock::read_unlock,
94 gtm_rwlock::write_unlock): Same.
95 * config/linux/rwlock.h (gtm_rwlock::summary): Change to atomic int.
96 * method-gl.cc (gl_mg::init, gl_wt_dispatch::memtransfer_static,
97 gl_wt_dispatch::memset_static, gl_wt_dispatch::begin_or_restart):
99 (gl_wt_dispatch::pre_write, gl_wt_dispatch::validate,
100 gl_wt_dispatch::load, gl_wt_dispatch::store,
101 gl_wt_dispatch::try_commit, gl_wt_dispatch::rollback): Fix memory
102 orders and fences. Add comments.
104 2011-12-21 Jakub Jelinek <jakub@redhat.com>
106 * Makefile.am (AM_CXXFLAGS): Put $(XCFLAGS) first.
107 * Makefile.in: Regenerated.
109 2011-12-17 Kaz Kojima <kkojima@gcc.gnu.org>
111 * configure.tgt: Add sh* case.
112 * config/sh/target.h: New file.
113 * config/sh/sjlj.S: New file.
114 * config/linux/sh/futex_bits.h: New file.
116 2011-12-14 Richard Henderson <rth@redhat.com>
118 * config/arm/hwcap.h, config/arm/hwcap.cc: New files.
119 * config/arm/sjlj.S, config/arm/target.h: New files.
120 * config/generic/asmcfi.h (cfi_adjust_cfa_offset): New.
121 (cfi_rel_offset): New.
122 * config/linux/futex_bits.h: New file.
123 * config/linux/futex.cc: Include futex_bits.h here...
124 * config/linux/futex.h: ... not here.
125 * Makefile.am (libitm_la_SOURCES) <ARCH_ARM>: Add hwcap.cc.
126 * configure.ac (ARCH_AM): New conditional.
127 * Makefile.in, configure: Rebuild.
128 * configure.tgt: Handle ARM.
130 2011-12-13 Richard Henderson <rth@redhat.com>
132 * config/posix/rwlock.cc (gtm_rwlock::write_lock_generic): Fix
133 signed/unsigned comparison werror.
135 * local_atomic: New file.
136 * libitm_i.h: Include it.
137 (gtm_thread::shared_state): Use atomic template.
138 * beginend.cc (GTM::gtm_clock): Use atomic template.
139 (global_tid): Use atomic template if 64-bit atomics available.
140 (gtm_thread::gtm_thread): Update shared_state access.
141 (gtm_thread::trycommit): Likewise.
142 (choose_code_path): Update global_tid access.
143 * method-gl.cc (gl_mg::orec): Use atomic template. Update all users.
144 * stmlock.h (GTM::gtm_clock): Use atomic template.
145 (gtm_get_clock, gtm_inc_clock): Update accesses.
146 * config/linux/rwlock.cc (gtm_rwlock::read_lock): Remove
147 redundant __sync_synchronize after atomic shared_state access.
148 * config/posix/rwlock.cc (gtm_rwlock::read_lock): Likewise.
149 (gtm_rwlock::write_lock_generic): Likewise.
150 (gtm_rwlock::read_unlock): Likewise.
151 * config/alpha/target.h (atomic_read_barrier): Remove.
152 (atomic_write_barrier): Remove.
153 * config/x86/target.h (atomic_read_barrier): Remove.
154 (atomic_write_barrier): Remove.
156 2011-11-30 Richard Henderson <rth@redhat.com>
158 * libitm_i.h (GTM_longjmp): Swap first and second arguments.
159 * beginend.c (_ITM_abortTransaction): Update to match.
160 (GTM::gtm_thread::restart): Likewise.
161 * config/alpha/sjlj.S (GTM_longjmp): Likewise.
162 * config/x86/sjlj.S (GTM_longjmp): Likewise.
164 2011-11-23 Iain Sandoe <iains@gcc.gnu.org>
166 * Makefile.am (libitm_la_LDFLAGS): Remove "-no-undefined".
167 * Makefile.in: Regenerate.
169 2011-11-22 Iain Sandoe <iains@gcc.gnu.org>
171 * configure.ac: Use GCC_CHECK_ELF_STYLE_WEAKREF.
172 * alloc_cpp.cc: Generate dummy functions if we don't
173 HAVE_ELF_STYLE_WEAKREF.
174 * eh_cpp.cc: Likewise.
175 * configure: Regenerate.
176 * aclocal.m4: Likewise.
177 * config.h.in: Likewise.
178 * Makefile.in: Likewise.
179 * testsuite/Makefile.in: Likewise.
181 2011-11-22 Iain Sandoe <iains@gcc.gnu.org>
183 * config/x86/sjlj.S (CONCAT1, CONCAT2, SYM): Respond to
184 __USER_LABEL_PREFIX__ for targets that use it.
185 (TYPE, SIZE, HIDDEN): New macros to assist on non-elf targets.
186 (_ITM_beginTransaction): Use SYM, TYPE, SIZE macros to assist
187 in portability to non-elf targets.
188 (GTM_longjmp): Likewise.
189 * libitm_i.h (begin_transaction): Apply __USER_LABEL_PREFIX__
192 2011-11-22 Iain Sandoe <iains@gcc.gnu.org>
194 * testsuite/libitm.c/memcpy-1.c: Allow for MAP_ANON spelling.
195 * testsuite/libitm.c/memset-1.c: Likewise.
197 2011-11-21 Andreas Tobler <andreast@fgznet.ch>
199 * configure: Regenerate.
201 2011-11-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
203 * acinclude.m4 (LIBITM_CHECK_LINKER_FEATURES): Handle gold.
204 (LIBITM_ENABLE_SYMVERS): Handle sun style.
205 * Makefile.am: Handle sun style versioning.
206 (libitm_la_LINK): Add $(libitm_la_LDFLAGS).
207 * configure: Regenerate.
208 * Makefile.in: Regenerate.
210 2011-11-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
212 * config/generic/asmcfi.h: Fix comment.
213 * config/x86/sjlj.S (_ITM_beginTransaction): Provide ELF PIC code
214 sequence without .hidden support, error for non-ELF targets.
215 (GTM_longjmp) [__ELF__]: Only use .hidden if
216 HAVE_ATTRIBUTE_VISIBILITY.
218 2011-11-17 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
220 * alloc_cpp.cc [__osf__] (_ZnwX, _ZdlPv, _ZnaX, _ZdaPv,
221 _ZnwXRKSt9nothrow_t, _ZdlPvRKSt9nothrow_t, _ZdaPvRKSt9nothrow_t):
223 * eh_cpp.cc [__osf__] (__cxa_allocate_exception, __cxa_throw,
224 __cxa_begin_catch, __cxa_end_catch, __cxa_tm_cleanup): Likewise.
226 2011-11-16 Uros Bizjak <ubizjak@gmail.com>
229 * acinclude.m4 (LIBITM_CHECK_AS_AVX): Fix target selector.
230 * configure: Regenerate.
232 2011-11-14 H.J. Lu <hongjiu.lu@intel.com>
234 * testsuite/lib/libitm.exp: Check ia32 instead of ilp32.
236 2011-11-10 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
238 * config/alpha/sjlj.S (_ITM_beginTransaction) [!__ELF__]: Don't use
240 (.note.GNU-stack): Only use if __linux__.
241 * alloc_cpp.cc [!__osf__] (_ZnaXRKSt9nothrow_t): Dummy function.
242 * testsuite/libitm.c/notx.c: Use dg-options "-pthread".
243 * testsuite/libitm.c/reentrant.c: Likewise.
244 * testsuite/libitm.c/simple-2.c: Likewise.
245 * testsuite/libitm.c/txrelease.c: Likewise.
246 * testsuite/libitm.c++/static_ctor.C: Likewise.
248 2011-11-10 Richard Henderson <rth@redhat.com>
250 * config/x86/x86_avx.cc: Remove #undef __AVX__ hack. Tidy comments.
251 * Makefile.am (x86_avx.lo): Only add -mavx if ARCH_X86_AVX.
252 * configure.ac (ARCH_X86_AVX): New conditional.
253 * Makefile.in, configure: Rebuild.
255 2011-11-09 Richard Henderson <rth@redhat.com>
257 * acinclude.m4 (LIBITM_CHECK_AS_AVX): New.
258 * configure.ac: Use it.
259 * config.h.in, configure: Rebuild.
260 * config/x86/x86_avx.cc: Handle !HAVE_AS_AVX.
262 2011-11-09 Richard Henderson <rth@redhat.com>
264 * barrier.tpl, memcpy.cc, memset.cc, method-wbetl.cc: Remove file.
265 * config/alpha/unaligned.h: Remove file.
266 * config/generic/unaligned.h: Remove file.
267 * config/x86/unaligned.h: Remove file.
268 * config/generic/cachepage.h: Remove file.
269 * config/posix/cachepage.cc: Remove file.
270 * config/generic/cacheline.cc: Remove file.
271 * config/x86/cacheline.cc: Remove file.
272 * config/generic/cacheline.h (gtm_cacheline): Remove the
273 store_mask, copy_mask, copy_mask_wb methods.
274 * config/x86/cacheline.h: Likewise.
275 * config/alpha/cacheline.h: Fall back to generic after setting size.
276 * config/generic/tls.cc (gtm_mask_stack): Remove.
277 * config/x86/x86_avx.cc (GTM_vpperm_shift): Remove.
278 (GTM_vpalignr_table): Remove.
279 * config/x86/x86_sse.cc (GTM_palignr_table): Remove.
280 (GTM_pshift_table): Remove.
281 * config/libitm_i.h: Don't include cachepage.h.
282 * Makefile.am (libitm_la_SOURCES): Remove cacheline.cc, cachepage.cc
283 * Makefile.in, testsuite/Makefile.in: Rebuild.
285 2011-11-09 Richard Henderson <rth@redhat.com>
287 * config/x86/cacheline.h (gtm_cacheline::store_mask): Use .byte
288 to emit branch prediction hint.
290 * config/x86/sjlj.S: Protect elf directives with __ELF__.
291 Protect .note.GNU-stack with __linux__.
293 * configure.ac (GCC_AS_CFI_PSEUDO_OP): Test it.
294 * configure, aclocal.m4, config.h.in: Rebuild.
295 * config/generic/asmcfi.h: New file.
296 * config/x86/sjlj.S: Use it.
298 2011-11-08 Richard Henderson <rth@redhat.com>
300 * local.cc (_ITM_LB): Use a normal call, not a function alias.
302 2011-11-08 Richard Henderson <rth@redhat.com>
304 * configure.tgt: Test correct directory for supported cpus.
306 * configure.ac: Exit if unsupported.
307 * configure: Rebuild.
308 * configure.tgt: Delete boilerplate from libgomp for unsupported
309 targets. Set UNSUPPORTED for unsupported targets.
311 2011-11-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
313 * configure.tgt: Handle i386 like i[456]86.
314 * config/generic/tls.h [!HAVE_ARCH_GTM_THREAD] (gtm_thr): Don't
316 * config/generic/tls.cc [!HAVE_ARCH_GTM_THREAD ||
317 !HAVE_ARCH_GTM_THREAD_DISP] (_gtm_thr_tls): New variable.
319 2011-11-05 Aldy Hernandez <aldyh@redhat.com>
321 * method-wbetl.cc: Update copyright notice.
328 * useraction.cc: Same.
332 * config/generic/tls.cc: Same.
333 * config/generic/cacheline.h: Same.
334 * config/generic/cachepage.h: Same.
335 * config/generic/cacheline.cc: Same.
336 * config/generic/unaligned.h: Same.
337 * config/x86/cacheline.h: Same.
338 * config/x86/cacheline.cc: Same.
339 * config/x86/unaligned.h: Same.
340 * config/alpha/cacheline.h: Same.
341 * config/alpha/unaligned.h: Same.
342 * config/alpha/sjlj.S: Same.
343 * config/posix/cachepage.cc: Same.
344 * config/linux/futex.h: Same.
345 * config/linux/alpha/futex_bits.h: Same.
347 2011-11-04 Torvald Riegel <triegel@redhat.com>
349 * libitm.texi: No cover text and invariant sections.
351 2011-11-03 Richard Henderson <rth@redhat.com>
353 * local_type_traits: New file.
354 * libitm_i.h: Use it. Use C headers, not C++ wrappers.
356 2011-11-03 Richard Henderson <rth@redhat.com>
358 * configure.ac: Don't test for gfortran.
359 * configure: Rebuild.
361 * testsuite/lib/libitm.exp: Don't include gfortran-dg.exp.
362 * testsuite/libitm.c++/c++.exp: Don't use gfortran-dg-runtest.
364 2011-11-03 Aldy Hernandez <aldyh@redhat.com>
366 * testsuite/libitm.c/memcpy-1.c: Add copyright notice.
367 * testsuite/libitm.c/memset-1.c: Same.
368 * testsuite/libitm.c/c.exp: Same.
369 * testsuite/lib/libitm-dg.exp: Same.
370 * testsuite/lib/libitm.exp: Same.
371 * testsuite/libitm.c++/c++.exp: Same.
373 2011-11-03 Aldy Hernandez <aldyh@redhat.com>
375 * testsuite/config/default.exp: Update copyright date.
376 * configure.ac: Add copyright info.
377 * configure.tgt: Same.
379 2011-11-03 Aldy Hernandez <aldyh@redhat.com>
381 * testsuite/libitm.c/reentrant.c: XFAIL.
382 * testsuite/libitm.c++/static_ctor.C: XFAIL.
384 2011-10-29 Torvald Riegel <triegel@redhat.com>
386 * beginend.cc (GTM::gtm_thread::rollback): Add aborting flag and
388 (_ITM_abortTransaction): Handle aborts of outer transactions.
390 * eh_cpp.cc (GTM::gtm_thread::revert_cpp_exceptions): Fix assertion.
391 * libitm.texi: Document aborts of outer transactions.
392 * testsuite/libitm.c/cancel.c: New file.
394 2011-10-19 Torvald Riegel <triegel@redhat.com>
396 * testsuite/*: Change __transaction to __transaction_atomic or
397 __transaction_relaxed.
399 2011-10-19 Torvald Riegel <triegel@redhat.com>
401 * config/linux/x86/tls.h (abi_disp): Make TLS slot read volatile.
404 2011-10-19 Torvald Riegel <triegel@redhat.com>
406 * libitm_i.h: Add gl_wt dispatch.
407 * retry.cc (parse_default_method): Same.
408 * method-gl.cc: New file.
409 * Makefile.am: Use method-gl.cc.
410 * Makefile.in: Rebuild.
412 2011-10-19 Torvald Riegel <triegel@redhat.com>
414 * beginend.cc (GTM::gtm_thread::trycommit): Ensure privatization
415 safety if requested by a TM method.
416 * dispatch.h (GTM::abi_dispatch::trycommit): Add parameter for
417 privatization safety.
418 * method-serial.cc: Same.
420 2011-10-19 Torvald Riegel <triegel@redhat.com>
422 * libitm_i.h: Renamed gtm_local_undo to gtm_undolog_entry.
423 (GTM::gtm_thread): Renamed local_undo to undolog. Renamed
424 undolog-related member functions from *_local to *_undolog.
425 * local.cc (gtm_thread::commit_undolog): Same.
426 * beginend.cc (GTM::gtm_thread::trycommit): Same.
427 (GTM::gtm_thread::rollback): Roll back undolog before
428 dispatch-specific rollback.
430 2011-10-19 Torvald Riegel <triegel@redhat.com>
432 * retry.cc (GTM::gtm_thread::decide_retry_strategy): Handle
433 re-initialization of the current method group.
434 * libitm_i.h (GTM::gtm_restart_reason): Add restart reason for this.
436 2011-10-19 Torvald Riegel <triegel@redhat.com>
438 * alloc.cc (commit_allocations_2): Do not free transaction-local
439 memory when committing a nested transaction.
441 2011-10-19 Torvald Riegel <triegel@redhat.com>
443 * method-serial.cc (GTM::gtm_thread::serialirr_mode): Fixed: Use
444 serial-irrevocable dispatch, not serial.
446 2011-10-19 Torvald Riegel <triegel@redhat.com>
448 * libitm_i.h (GTM::gtm_restart_reason): Re-arrange and clean up
450 * dispatch.h (GTM::abi_dispatch::begin_or_restart): New.
451 * method-serial.cc: Implement begin_or_restart().
452 * beginend.cc (GTM::gtm_thread::begin_transaction): Call
453 dispatch-specific begin_or_restart().
454 (GTM::gtm_thread::restart): Same.
456 2011-08-23 Torvald Riegel <triegel@redhat.com>
458 * retry.cc (GTM::gtm_thread::decide_retry_strategy): Cleanup. Fix
459 restarting without switching to serial mode.
460 (GTM::gtm_thread::decide_begin_dispatch): Let the caller set the
461 transaction state. Choose closed-nesting alternative if available.
462 (GTM::gtm_thread::set_default_dispatch): New.
463 (parse_default_method): New.
464 (GTM::gtm_thread::number_of_threads_changed): New.
465 * method-serial.cc (GTM::serial_mg): New method group class.
466 (GTM::serialirr_dispatch): Belongs to serial_mg. Remove reinit and
468 (GTM::serial_dispatch): Same.
469 (GTM::serialirr_onwrite_dispatch): Same.
470 (GTM::gtm_thread::serialirr_mode): Remove calls to fini.
471 * beginend.cc (GTM::gtm_thread::~gtm_thread): Maintain number of
473 (GTM::gtm_thread::gtm_thread): Same.
474 (_ITM_abortTransaction): Remove calls to abi_dispatch::fini().
475 (GTM::gtm_thread::trycommit): Same. Reset number of restarts.
476 (GTM::gtm_thread::begin_transaction): Let decide_begin_dispatch()
477 choose dispatch but set state according to dispatch here.
478 * dispatch.h (GTM::abi_dispatch::fini): Move to method group.
479 (GTM::method_group): New class.
480 (GTM::abi_dispatch): Add comments. Maintain pointer to method_group.
481 * libitm_i.h (GTM::gtm_thread): Add declarations for new members.
482 * libitm.texi: Document TM methods, method groups, method life cycle.
483 Rename method sets to method groups.
485 2011-08-23 Torvald Riegel <triegel@redhat.com>
487 * config/x86/tls.h: Moved to ...
488 * config/linux/x86/tls.h: ... here.
490 2011-08-23 Torvald Riegel <triegel@redhat.com>
492 * config/x86/tls.h: Use __x86_64__ instead of __LP64__.
494 * config/x86/sjlj.S: Same.
496 2011-08-19 Torvald Riegel <triegel@redhat.com>
498 * config/linux/rwlock.h: New file.
499 * config/linux/rwlock.c: New file.
500 * configure.ac: Reenable futex support (undo SVN rev 157758).
502 * configure.tgt: Same.
503 * config/linux/alpha/futex_bits.h: Same.
504 * config/linux/futex.h: Same. Return number of woken processes.
505 * config/linux/futex.cc: Same.
506 (futex_wait): Remove spinning.
507 * config/linux/x86/futex_bits.h: Same. Set futex timeout to zero.
508 Use __x86_64__ instead of __LP64__.
509 * aclocal.m4: Include generic futex checks.
510 * configure: Rebuild.
511 * Makefile.in: Rebuild.
512 * testsuite/Makefile.in: Rebuild.
513 * beginend.cc: Include pthread.h.
514 * config/posix/cachepage.cc: Same.
516 2011-08-12 Torvald Riegel <triegel@redhat.com>
518 * config/x86/tls.h (gtm_tx, set_gtm_tx, setup_gtm_thr): Removed.
519 (abi_disp, set_abi_disp): Move to tx's TLS slot.
521 * config/generic/tls.h (gtm_tx, set_gtm_tx, setup_gtm_thr): Removed.
523 (GTM::gtm_thread::thread_num): Removed.
524 (GTM::gtm_thread): Renamed to GTM::gtm_thread_tls.
525 * libitm_i.h (GTM::gtm_transaction): Renamed to GTM::gtm_thread. More
526 tx-to-thread renaming.
527 * beginend.cc: Adapted to tx-to-thread renaming.
528 (GTM::gtm_thread::~gtm_thread): Extracted from thread_exit_handler().
529 (GTM::gtm_thread::gtm_thread): Extracted from begin_transaction().
530 * query.cc (_ITM_getTransactionId, _ITM_inTransaction): Renamed
531 gtm_transaction to gtm_thread.
532 (_ITM_getThreadnum): Removed. Not supported anymore.
533 * testsuite/libitm.c/notx.c (main): Removed _ITM_getThreadnum call.
534 * libitm.texi: Documented that _ITM_getThreadnum is not supported.
535 * useraction.cc: Renamed gtm_transaction to gtm_thread. Adapted to
536 gtm_tx-to-gtm_thr renaming if necessary.
543 * alloc_cpp.cc: Same.
544 * method-serial.cc: Same.
545 * config/generic/tls.cc: Same.
546 * config/posix/rwlock.h (gtm_rwlock): Same.
547 * config/posix/rwlock.cc: Same. Adapted to more tx-to-thread renaming.
549 2011-08-12 Torvald Riegel <triegel@redhat.com>
551 * config/posix/rwlock.cc (gtm_rwlock::read_lock): Changed locking
553 (gtm_rwlock::read_unlock): Same.
554 (gtm_rwlock::write_lock_generic): New. Generalized from ...
555 (gtm_rwlock::write_lock, gtm_rwlock::write_upgrade): ... these.
556 * libitm_i.h (GTM::gtm_transaction): Added shared_state.
557 * config/posix/rwlock.h (GTM::gtm_rwlock): Removed a_reader and
558 w_upgrade. Replaced by per-transaction flags (in shared_state).
559 Added c_confirmed_writers.
560 (GTM::gtm_rwlock::read_lock, GTM::gtm_rwlock::read_unlock,
561 GTM::gtm_rwlock::write_upgrade): Add tx parameter.
562 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Same.
563 * method-serial.cc (GTM::gtm_transaction::serialirr_mode): Same.
564 * beginend.cc (GTM::gtm_transaction::begin_transaction,
565 _ITM_abortTransaction, GTM::gtm_transaction::trycommit): Same.
566 * libitm.texi: Document locking conventions and implementations in
569 2011-08-12 Torvald Riegel <triegel@redhat.com>
571 * libitm_i.h (next_tx): Add list of all threads' transaction.
572 * beginend.cc (GTM::gtm_transaction::begin_transaction): Register
573 transaction with list of transactions and ...
574 (thread_exit_handler): ... deregister here.
575 * config/alpha/target.h: Add HW_CACHELINE_SIZE setting.
576 * config/x86/target.h: Same.
578 2011-08-12 Torvald Riegel <triegel@redhat.com>
580 * testsuite/libitm.c++/static_ctor.C: New file.
582 2011-08-12 Torvald Riegel <triegel@redhat.com>
584 * testsuite/libitm.c/reentrant.c: New file.
586 2011-08-12 Torvald Riegel <triegel@redhat.com>
588 * config/generic/tls.h: Remove the free list for transactions and ...
589 * beginend.cc (GTM::gtm_transaction::operator new): ... allocate ...
590 (GTM::gtm_transaction::operator delete): ... and release here.
591 (thread_exit_handler): New. Delete tx when thread terminates.
592 (thread_exit_init): New.
593 (GTM::gtm_transaction::begin_transaction): Set up on-exit handler.
594 * testsuite/libitm.c/txrelease.c: New file.
596 2011-08-12 Torvald Riegel <triegel@redhat.com>
598 * query.cc (_ITM_getThreadnum): Set up gtm_thread if necessary.
599 * testsuite/libitm.c/notx.c: New file.
601 2011-08-12 Torvald Riegel <triegel@redhat.com>
603 * config/generic/tls.h (gtm_thread): Move local_tid from here ...
604 * libitm_i.h (local_tid): ... to here.
605 * beginend.cc (GTM::gtm_transaction::begin_transaction): Same.
606 (GTM::gtm_transaction::operator new): Set up gtm_thread if necessary.
608 2011-08-12 Torvald Riegel <triegel@redhat.com>
610 * retry.cc (GTM::gtm_transaction::decide_begin_dispatch): Use
611 serialirr_onwrite_dispatch as new default for now.
612 * method-serial.cc (serialirr_onwrite_dispatch): New.
613 (GTM::dispatch_serialirr_onwrite): New.
616 2011-08-12 Torvald Riegel <triegel@redhat.com>
618 * beginend.cc (GTM::gtm_transaction::rollback): Roll back tx id as well.
619 * query.cc (_ITM_getTransactionId): There is no active transaction if
620 the current nesting level is zero.
622 2011-07-28 Torvald Riegel <triegel@redhat.com>
624 * beginend.cc (GTM::gtm_transaction::rollback): Fix nesting level
627 2011-07-28 Torvald Riegel <triegel@redhat.com>
629 * retry.cc (GTM::gtm_transaction::decide_begin_dispatch): Get
630 transaction properties from the caller instead of from the
633 * beginend.cc (GTM::gtm_transaction::begin_transaction): Same.
635 2011-07-28 Torvald Riegel <triegel@redhat.com>
637 * local.cc (gtm_transaction::rollback_local): Support closed nesting.
638 * eh_cpp.cc (GTM::gtm_transaction::revert_cpp_exceptions): Same.
640 * method-serial.cc: Same.
641 * beginend.cc (GTM::gtm_transaction::begin_transaction): Change to
642 flat nesting as default, and closed nesting on demand.
643 (GTM::gtm_transaction::rollback): Same.
644 (_ITM_abortTransaction): Same.
645 (GTM::gtm_transaction::restart): Same.
646 (GTM::gtm_transaction::trycommit): Same.
647 (GTM::gtm_transaction::trycommit_and_finalize): Removed.
648 (choose_code_path): New.
649 (GTM::gtm_transaction_cp::save): New.
650 (GTM::gtm_transaction_cp::commit): New.
651 * query.cc (_ITM_inTransaction): Support flat nesting.
652 * libitm_i.h (GTM::gtm_transaction_cp): New helper struct for nesting.
653 (GTM::gtm_transaction): Support flat and closed nesting.
654 * alloc.cc (commit_allocations_2): New.
655 (commit_cb_data): New helper struct.
656 (GTM::gtm_transaction::commit_allocations): Handle nested
658 * libitm.texi: Update user action section, add description of nesting.
660 2011-07-28 Torvald Riegel <triegel@redhat.com>
662 * libitm_i.h: Add closed nesting as restart reason.
663 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Same.
665 2011-07-28 Torvald Riegel <triegel@redhat.com>
667 * useraction.cc: Use vector instead of list to store actions.
668 Also support partial rollbacks for closed nesting.
669 * libitm_i.h (GTM::gtm_transaction::user_action): Same.
672 2011-07-28 Torvald Riegel <triegel@redhat.com>
674 * dispatch.h (GTM::abi_dispatch): Add can_run_uninstrumented_code and
675 closed_nesting flags, as well as a closed nesting alternative.
676 * method-serial.cc: Same.
677 (serial_dispatch): Renamed to serialirr_dispatch.
678 (GTM::dispatch_serialirr): Same.
679 (serial_dispatch_ul): Renamed to serial_dispatch.
680 (GTM::dispatch_serial): Same.
682 2011-07-28 Torvald Riegel <triegel@redhat.com>
684 * libitm.h (_ITM_codeProperties): Change pr_hasElse to the ABI's value.
686 2011-07-28 Torvald Riegel <triegel@redhat.com>
688 * aatree.h (aa_tree::remove): New.
689 (aa_tree::operator new): Add placement new.
691 2011-07-02 Torvald Riegel <triegel@redhat.com>
693 * containers.h: New file.
694 * util.cc (xmalloc, xrealloc): Accept cacheline-alloc flag.
695 * libitm_i.h (xmalloc, xrealloc): Moved declarations from here ...
696 * common.h: ... to here.
697 (local_undo): Use GTM::vector for gtm_transaction::local_undo.
700 2011-06-30 Torvald Riegel <triegel@redhat.com>
702 * libitm_i.h (STATE_ABORTING): Remove.
703 * beginend.cc (_ITM_abortTransaction): Same.
704 (GTM::gtm_transaction::trycommit_and_finalize): Same.
705 * libitm.h (_ITM_registerThrownObject, _ITM_tryCommitTransaction): Remove.
706 (_ITM_rollbackTransaction): Remove.
709 * libitm.texi: Document these ABI changes.
711 2011-06-30 Torvald Riegel <triegel@redhat.com>
713 * libitm.texi: New file.
714 * Makefile.am: Add libitm.texi.
715 * Makefile.in: Rebuild.
717 2011-06-30 Torvald Riegel <triegel@redhat.com>
719 * libitm_i.h: Move parts to common.h and dispatch.h.
720 * common.h: New file.
721 * dispatch.h: New file, new dispatch class.
722 Rename GTM::abi_dispatch::lock_type to ls_modifier.
723 RenameGTM::abi_dispatch::NOLOCK to NONTXNAL.
724 * beginend.cc (GTM::gtm_transaction::begin_transaction): Delegate mode
725 decision to retry.cc.
726 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Use serial mode
728 (GTM::gtm_transaction::decide_begin_dispatch): Same.
729 * method-serial.cc: Adapt to new dispatch. Add serial mode with undo
731 * barrier.cc: Use new barriers definitions.
732 (abi_dispatch::memmove_overlap_check): New.
733 * config/x86/x86_sse.cc: Same.
734 * config/x86/x86_avx.cc: Same.
735 * Makefile.am: Don't build readonly and wbetl methods, memset.cc and
737 * Makefile.in: Rebuild.
738 * method-readonly.cc: Remove.
739 * method-wbetl.cc: Rename GTM::abi_dispatch::lock_type to ls_modifier.
740 Rename GTM::abi_dispatch::NOLOCK to NONTXNAL.
742 2011-06-30 Torvald Riegel <triegel@redhat.com>
744 * alloc_c.cc (_ITM_dropReferences): Don't support it anymore.
745 * testsuite/libitm.c++/dropref.C: _ITM_dropReferences is expected to fail.
746 * testsuite/libitm.c/dropref-2.c: Same.
747 * testsuite/libitm.c/dropref.c: Same.
749 2011-06-30 Torvald Riegel <triegel@redhat.com>
751 * config/generic/tls.h (gtm_disp): Rename to abi_disp.
752 * config/generic/tls.h (set_gtm_disp): Rename to set_abi_disp.
753 * libitm_i.h: Rename gtm_dispatch to abi_dispatch.
757 * config/generic/tls.h: Same.
758 * config/x86/tls.h: Same.
762 * method-readonly.cc: Same.
763 * method-serial.cc: Same.
764 * method-wbetl.cc: Same.
767 2011-03-03 Richard Henderson <rth@redhat.com>
769 * config/posix/rwlock.cc (write_upgrade): Add missing case.
770 From Patrik Marlier <patrick.marlier@unine.ch>.
772 2011-02-03 Richard Henderson <rth@redhat.com>
774 * acinclude.m4 (LIBITM_CHECK_SIZE_T_MANGLING): New.
775 * configure.ac: Use it.
776 * configure, config.h.in: Rebuild.
777 * alloc_cpp.cc (_ZnwX): Use MANGLE_SIZE_T in constructing the name.
778 (_ZnaX, _ZnwXRKSt9nothrow_t, _ZnaXRKSt9nothrow_t, _ZGTtnwX,
779 _ZGTtnaX, _ZGTtnwXRKSt9nothrow_t, _ZGTtnaXRKSt9nothrow_t): Likewise.
780 * libitm.map: Use wildcards to match size_t mangling.
782 2010-12-14 Richard Henderson <rth@redhat.com>
784 * beginend.cc (GTM::gtm_transaction::begin_transaction): Allocate
785 blocks of TIDs per thread.
786 * config/generic/tls.h (struct gtm_thread): Add local_tid member.
787 (setup_gtm_thr): Return the thread structure.
788 * config/x86/tls.h (setup_gtm_thr): Likewise.
790 2010-12-14 Richard Henderson <rth@redhat.com>
792 * clone.cc (table_lock): Remove.
793 (find_clone): Don't take it.
794 (ExcludeTransaction): New helper class.
795 (_ITM_registerTMCloneTable): Use it.
796 (_ITM_deregisterTMCloneTable): Likewise.
798 2010-12-14 Richard Henderson <rth@redhat.com>
800 * config/x86/tls.h: New file.
802 2010-07-15 Richard Henderson <rth@redhat.com>
804 * Makefile.am (AM_CXXFLAGS): Add -funwind-tables.
805 * Makefile.in: Rebuild.
807 2010-07-13 Aldy Hernandez <aldyh@redhat.com>
809 * method-wbetl.cc (trydropreference): Fix source line.
811 2010-07-13 Aldy Hernandez <aldyh@redhat.com>
813 * libitm.h: Add comment.
814 * libitm_i.h (begin_transaction): Add ITM_REGPARM.
816 2010-07-07 Aldy Hernandez <aldyh@redhat.com>
818 * configure.ac: Call LIBITM_CHECK_64BIT_SYNC_BUILTINS.
819 * beginend.cc (begin_transaction): If 64-bit sync builtins are not
820 available, use pthread mutexes.
821 * acinclude.m4 (LIBITM_CHECK_64BIT_SYNC_BUILTINS): New.
822 * config.h.in: Regenerate.
823 * configure: Regenerate.
825 2010-07-06 Aldy Hernandez <aldyh@redhat.com>
827 * libitm.h (ITM_PURE): Define.
828 Declare _ITM_malloc, _ITM_calloc, and _ITM_free.
830 2010-06-28 Aldy Hernandez <aldyh@redhat.com>
832 * method-wbetl.cc (class wbetl_dispatch): Add trydropreference.
833 (validate): Add comment.
834 (trydropreference): New.
835 * method-readonly.cc (class readonly_dispatch): Add
837 * alloc_c.cc (_ITM_dropReferences): Remove const attribute.
838 Call trydropreference().
839 * libitm.h (_ITM_dropReferences): Remove const attribute.
840 * method-serial.cc (class serial_dispatch): Add trydropreference.
841 * libitm_i.h (struct gtm_dispatch): Add trydropreference.
843 2010-06-28 Aldy Hernandez <aldyh@redhat.com>
845 * memcpy.cc (do_memcpy): Comment.
847 2010-06-25 Aldy Hernandez <aldyh@redhat.com>
849 * barrier.tpl: Add comments throughout.
851 2010-06-24 Aldy Hernandez <aldyh@redhat.com>
853 * method-wbetl.cc (struct w_entry): Add comments.
857 2010-06-24 Aldy Hernandez <aldyh@redhat.com>
859 * alloc_c.cc (_ITM_dropReferences): New.
860 * libitm.map (_ITM_dropReferences): Add.
861 * libitm.h (_ITM_dropReferences): Add transaction_pure attribute.
862 * libitm_i.h (struct gtm_transaction): Declare
863 drop_references_allocations and drop_references_local.
864 * local.cc (rollback_local): Ignore memory when applicable.
865 (drop_references_local): New.
867 2010-06-23 Richard Henderson <rth@redhat.com>
869 * barrier.tpl, beginend.cc, clone.cc, tls.h, memcpy.cc,
870 memset.cc, method-serial.cc: Revert the 2010-06-16 change.
871 * config/x86/target.h (struct gtm_jmpbuf): Change CFA type to void*.
872 * config/alpha/target.h: Likewise.
873 * config/generic/tls.cc (gtm_mask_stack): Use it.
875 2010-06-23 Richard Henderson <rth@redhat.com>
877 * config/posix/cachepage.cc (gtm_cacheline_page::operator new): Use
878 a mutex instead of trying a lock-free compare-and-swap on the list.
879 (gtm_cacheline_page::operator delete): Likewise.
881 2010-06-16 Richard Henderson <rth@redhat.com>
883 * method-wbetl.cc (wbetl_dispatch::trycommit): Discard changes
884 that overlap the libitm stack.
885 * barrier.tpl: Mark incoming stack.
886 * beginend.cc (_ITM_rollbackTransaction, _ITM_abortTransaction,
887 _ITM_commitTransaction, _ITM_commitTransactionEH): Likewise.
888 * clone.cc (_ITM_getTMCloneOrIrrevocable): Likewise.
889 * memcpy.cc, memset.cc: Likewise.
890 * method-serial.cc (_ITM_changeTransactionMode): Likewise.
891 * config/generic/tls.h (gtm_thread): Add stack_top member.
892 (gtm_stack_top, set_gtm_stack_top, struct gtm_stack_marker): New.
893 * libitm_i.h (gtm_mask_stack): Declare.
894 * config/generic/tls.cc: New file.
895 * Makefile.am (libitm_la_SOURCES): Add it.
896 (AM_CXXFLAGS): Turn off exceptions.
897 * Makefile.in: Rebuild.
899 2010-06-16 Richard Henderson <rth@redhat.com>
901 * alloc.cc (struct gtm_alloc_action): Move definition ...
902 * libitm_i.h: ... here.
903 (class gtm_transaction): Declare new and delete.
904 * beginend.cc (alloc_tx): Reformulate as operator new.
905 (free_tx): Reformulate as operator delete.
906 * config/generic/tls.h (gtm_thread): Change free_tx member to void *.
908 2010-06-11 Richard Henderson <rth@redhat.com>
910 * clone.cc (clone_entry_compare): Fix typo.
911 From Patrik Marlier <patrick.marlier@unine.ch>.
913 2010-05-13 Richard Henderson <rth@redhat.com>
915 * alloc_c.cc (_ITM_malloc, _ITM_calloc, _ITM_free): Wrap functions
918 2010-05-07 Aldy Hernandez <aldyh@redhat.com>
920 * libitm_i.h (struct gtm_transaction): Remove
922 (record_allocation): Remove size parameter.
923 * libitm.map (_ITM_realloc): Remove.
924 * alloc_c.cc (_ITM_realloc): Remove.
925 (_ITM_malloc): Remove size argument to record_allocation.
927 * alloc_cpp.cc (_ZGTtnwm): Same.
928 (_ZGTtnwmRKSt9nothrow_t): Same.
930 (_ZGTtnamRKSt9nothrow_t): Same.
931 * alloc.cc (struct gtm_alloc_action): Remove size.
932 (get_allocation_size): Remove.
933 (commit_allocations): Add comment.
934 (record_allocation): Remove size parameter.
935 (forget_allocation): Remove set of size.
937 2010-04-19 Aldy Hernandez <aldyh@redhat.com>
939 * Makefile.am (abi_version): New.
940 (AM_CXXFLAGS): Pass abi_version.
941 * Makefile.in: Regenerate.
942 * config/x86/unaligned.h: Remove always_inline kludge for vectors.
944 2010-04-06 Aldy Hernandez <aldyh@redhat.com>
946 * clone.cc (_ITM_getTMCloneOrIrrevocable): Rename from
947 _ITM_getTMCloneOrIrrevokable.
948 * libitm.h (_ITM_getTMCloneOrIrrevocable): Same.
949 * libitm.map (_ITM_getTMCloneOrIrrevocable): Same.
951 2010-03-26 Aldy Hernandez <aldyh@redhat.com>
953 * configure.ac: Remove Linux futex support.
954 * configure.tgt (config_path): Same.
956 * config/linux: Remove entire directory.
957 * configure: Rebuild.
958 * Makefile.in: Rebuild.
959 * testsuite/Makefile.in: Rebuild.
961 2010-03-09 Aldy Hernandez <aldyh@redhat.com>
963 * retry.cc (decide_retry_strategy): Set state to STATE_SERIAL when
964 switching to serial mode.
965 * beginend.cc (trycommit_and_finalize): Unlock serial_lock.
967 2010-03-03 Aldy Hernandez <aldyh@redhat.com>
969 * configure.tgt: Add emacs -*- tags.
972 2010-02-23 Aldy Hernandez <aldyh@redhat.com>
974 * Makefile.am: Rename serial.cc to method-serial.cc.
975 * Makefile.in: Regenerate with automake 1.11.1.
976 * testsuite/Makefile.in: Same.
977 * aclocal.m4: Regenerate with aclocal 1.11.1.
978 * method-serial.cc: Rename from serial.cc.
979 * libitm_i.h (struct gtm_transaction): Update comment on
982 2010-02-22 Aldy Hernandez <aldyh@redhat.com>
984 * libitm_i.h (GTM_longjmp): Add ITM_REGPARM.
985 * config/linux/rwlock.h (class gtm_rwlock): Add comments.
987 2010-02-11 Aldy Hernandez <aldyh@redhat.com>
989 * configure: Rebuild.
991 2009-11-12 Richard Henderson <rth@redhat.com>
993 * Rewrite everything in C++.
995 2009-11-03 Richard Henderson <rth@redhat.com>
997 * config/x86/x86_sse.c, config/x86/x86_avx.c: New files.
998 * Makefile.am (libitm_la_SOURCES): Add them.
999 * configure.ac (ARCH_X86): New conditional.
1000 * Makefile.in, configure: Rebuild.
1001 * configure.tgt: Set up ARCH; do cflags setup at the same time.
1002 Move futex setup into "other system configury" case.
1003 * local.c (rollback_local): Merge into ...
1004 (GTM_rollback_local): ... here.
1005 (GTM_LB): Rename from GTM_alloc_local; do the memcpy here.
1006 (_ITM_LB): Define as an alias to GTM_LB.
1008 2009-11-03 Richard Henderson <rth@redhat.com>
1010 * method-readonly.c: New file.
1011 * Makefile.am (libitm_la_SOURCES): Add it.
1012 * Makefile.in: Rebuild.
1013 * beginend.c (gtm_stmlock_array, gtm_clock): New.
1014 (GTM_begin_transaction): Use dispatch_readonly for read-only txn.
1015 * libitm_i.h (gtm_stmlock, gtm_version): Move from method-wbetl.c.
1016 (GTM_VERSION_MAX, GTM_VERSION_INVALID, gtm_stmlock_owned_p,
1017 gtm_stmlock_set_owned, gtm_stmlock_get_addr,
1018 gtm_stmlock_get_version, gtm_stmlock_set_version, LOCK_ARRAY_SIZE,
1019 gtm_stmlock_array, gtm_get_stmlock, gtm_clock, RESTART_NOT_READONLY,
1020 gtm_get_clock, gtm_inc_clock): New.
1021 * method-wbetl.c (gtm_version, gtm_stmlock, OWNED_MASK, VERSION_MAX,
1022 LOCK_GET_OWNED, LOCK_SET_ADDR, LOCK_GET_ADDR, LOCK_GET_TIMESTAMP,
1023 LOCK_SET_TIMESTAMP, LOCK_ARRAY_SIZE, LOCK_MASK, LOCK_IDX, GET_LOCK,
1024 locks, gclock, CLOCK, GET_CLOCK, FETCH_AND_INC_CLOCK): Remove and
1025 replace uses with new libitm_i.h symbols.
1026 (dispatch_wbetl): Rename from wbetl_dispatch.
1027 * retry.c (GTM_decide_retry_strategy): If RESTART_NOT_READONLY, move
1028 away from dispatch_readonly; abort if the beginTransaction call
1029 asserted that the transaction was readonly.
1031 2009-11-03 Richard Henderson <rth@redhat.com>
1033 * memset.c: New file.
1034 * Makefile.am (libitm_la_SOURCES): Add it.
1035 * Makefile.in: Rebuild.
1036 * testsuite/libitm.c/memset-1.c: New.
1038 2009-11-03 Richard Henderson <rth@redhat.com>
1040 * dispatch.c: Remove file.
1041 * useraction.c (struct gtm_user_action): Move from libitm.h.
1042 * serial.c (GTM_null_read_lock, GTM_null_write_lock): New.
1043 (serial_memset, serial_memmove, serial_memcpy): Remove.
1044 (serial_W*, serial_R*): Remove.
1045 (serial_dispatch): Update to match.
1046 * configure.ac: Move Werror down below configure checks. Don't
1047 check for sys/loadavg.h, do check for malloc.h. Don't check for
1048 getloadavg and clock_gettime; do check for memalign, posix_memalign.
1049 Use GCC_AC_FUNC_MMAP_BLACKLIST
1050 * libitm.h: Split out all internal items to...
1051 * libitm_i.h: ... here. New file.
1052 * copymask.c: New file.
1053 * local.c (struct gtm_local_undo): Move from libitm.h.
1054 (GTM_alloc_local): Rename from alloc_local; export.
1055 * memcpy.c: New file.
1056 * alloc_c.c (_ITM_realloc): Use _ITM_memcpyRnWt directly.
1057 * config/posix/page.c: New file.
1058 * config/posix/target_tls.h: Remove file.
1059 * barrier.c: New file.
1060 * Makefile.am (libitm_la_SOURCES): Add barrier.c, memcpy.c,
1062 * alloc.c (struct gtm_alloc_action): Move from libitm.h.
1063 * method-wbetl.c: Rewrite for new cacheline methods.
1064 * Makefile.in, configure, testsuite/Makefile.in, config.h.in: Rebuild.
1066 * config/alpha/sjlj.S: Fix typo.
1067 * config/alpha/target_i.h: Copy functions from alpha/target.h.
1068 * config/alpha/copymask.c: New file.
1069 * config/alpha/target.h (CACHELINE_SIZE): New.
1070 (STRICT_ALIGNMENT, PAGE_SIZE, FIXED_PAGE_SIZE): New.
1072 * config/x86/target_i.h: Copy functions from x86/target.h.
1073 * config/x86/copymask.c: New file.
1074 * config/x86/target.h (_ITM_ALL_TARGET_TYPES): Remove.
1075 (CACHELINE_SIZE, STRICT_ALIGNMENT): New.
1076 (PAGE_SIZE, FIXED_PAGE_SIZE): New.
1077 * config/x86/target_tls.h: Move contents to target_i.h.
1079 * testsuite/libitm.c/clone-1.c: Include libitm.h.
1080 * testsuite/libitm.c/memcpy-1.c: New.
1082 2009-10-22 Richard Henderson <rth@redhat.com>
1084 * Makefile.am (CCAS, CCASFLAGS, LTCCASCOMPILE): Remove.
1085 (AM_CCASFLAGS): New.
1086 * configure.ac: Add AM_PROG_AS. Use m4_rename_force for
1087 saving/restoring _AC_ARG_VAR_PRECIOUS.
1088 * Makefile.in, aclocal.m4, config.h.in, configure,
1089 testsuite/Makefile.in: Rebuild with automake 1.11; autoconf 2.64.
1091 2009-10-22 Richard Henderson <rth@redhat.com>
1093 * testsuite/*: Update for new compiler syntax.
1095 2009-10-21 Richard Henderson <rth@redhat.com>
1097 * libitm.h (_ITM_abortReason): Add outerAbort.
1099 2009-08-03 Richard Henderson <rth@redhat.com>
1101 * libitm.map (_ITM_commitTransactionEH, _ITM_cxa_allocate_exception,
1102 _ITM_cxa_begin_catch, _ITM_cxa_end_catch, _ITM_cxa_throw): Export.
1103 * method-wbetl.c (struct w_entry): Remove mask.
1104 (wbetl_write, wbetl_load): Return pointer to word containing the data;
1107 2009-07-22 Richard Henderson <rth@redhat.com>
1109 * eh_cpp.c: New file.
1110 * Makefile.am (libitm_la_SOURCES): Add it.
1111 * Makefile.in: Rebuild.
1112 * beginend.c (GTM_rollback_transaction): Undo exception state.
1113 (GTM_trycommit_transaction): Mark inline.
1114 (GTM_trycommit_and_finalize_transaction): Split out from ...
1115 (_ITM_commitTransaction): ... here.
1116 (_ITM_commitTransactionEH): New function.
1117 * libitm.h (struct gtm_transaction): Add cxa_catch_count,
1118 cxa_unthrown, eh_in_flight; reorder.
1120 * testsuite/libitm.c++/c++.exp: New.
1121 * testsuite/libitm.c++/eh-1.C: New.
1123 * aatree.c (aa_free): Remove REGPARM.
1124 * aatree.h: Remove all REGPARM.
1126 2009-07-18 Richard Henderson <rth@redhat.com>
1128 * aatree.c, aatree.h, alloc.c, alloc_c.c, alloc_cpp.c: New files.
1129 * Makefile.am (libitm_la_SOURCES): Add them.
1130 * Makefile.in: Rebuild.
1131 * beginend.c (GTM_rollback_transaction): Use GTM_commit_allocations.
1132 (GTM_trycommit_transaction): Likewise.
1133 * libitm.h: Include aatree.h
1134 (struct gtm_alloc_action): New.
1135 (struct gtm_transaction): Add alloc_actions.
1136 (GTM_record_allocation, GTM_forget_allocation): Declare.
1137 (GTM_get_allocation_size, GTM_commit_allocations): Declare.
1138 * libitm.map (_ITM_malloc, _ITM_calloc, _ITM_realloc, _ITM_free,
1139 _ZGTtnwm, _ZGTtnam, _ZGTtdlPv, _ZGTtdaPv, _ZGTtnwmRKSt9nothrow_t,
1140 _ZGTtnamRKSt9nothrow_t, _ZGTtdlPvRKSt9nothrow_t,
1141 _ZGTtdaPvRKSt9nothrow_t): Export.
1143 2009-07-18 Richard Henderson <rth@redhat.com>
1145 * target_tls.h: Move ...
1146 * config/posix/target_tls.h: ... here.
1148 2009-07-07 Richard Henderson <rth@redhat.com>
1150 * config/x86/target.h (atomic_write_barrier): Use sfence if available.
1152 2009-07-07 Richard Henderson <rth@redhat.com>
1156 2009-07-07 Richard Henderson <rth@redhat.com>
1158 * libitm.h (struct gtm_transaction): Widen id to _ITM_transactionId_t.
1159 * beginend.c (global_tid): Widen to _ITM_transactionId_t.
1161 * configure.tgt: Don't use -ftls-model for x86 linux.
1162 * libitm.h: Include target.h after standard includes.
1163 (_gtm_thr): Rename from gtm_thr.
1164 (setup_gtm_thr, gtm_thr, gtm_tx, set_gtm_tx): New.
1165 (gtm_disp, set_gtm_disp): New.
1166 * beginend.c, dispatch.c, local.c, method-wbetl.c, query.c,
1167 retry.c, serial.c, useraction.c: Use accessor functions throughout.
1168 * config/alpha/target_tls.h, config/x86/target_tls.h: New files.
1170 2009-07-07 Richard Henderson <rth@redhat.com>
1172 * config/linux/rwlock.c (EZ): New define. Use it throughout.
1174 2009-07-06 Richard Henderson <rth@redhat.com>
1176 * libitm.h (_ITM_SRCLOCATION_DECL_1, _ITM_SRCLOCATION_DECL_2): Remove.
1177 (_ITM_SRCLOCATION_DEFN_1, _ITM_SRCLOCATION_DEFN_2): Remove.
1178 (_ITM_beginTransaction): Take variadic arguments.
1179 (_ITM_registerThrownObject): Declare.
1180 * beginend.c, serial.c: Update.
1181 * libitm.map: Add _ITM_registerThrownObject.
1183 2009-01-28 Richard Henderson <rth@redhat.com>
1185 * Makefile.am (libitm_la_SOURCES): Add clone.c.
1186 * Makefile.in: Rebuild.
1187 * beginend.c (_ITM_abortTransaction): Abort if irrevokable.
1188 (GTM_restart_transaction): Fix uninstrumented code check.
1189 * retry.c (GTM_decide_retry_strategy): Add serial check.
1190 * serial.c (GTM_serialmode): Add irrevokable variable. Don't
1191 automatically go irrevokable when in serial mode.
1192 * clone.c: New file.
1193 * libitm.h, libitm.map: Update.
1195 2009-01-27 Richard Henderson <rth@redhat.com>
1197 * Makefile.am (LTCCASCOMPILE): Define.
1198 (libitm_la_SOURCES): Add methid-wbetl.c.
1199 * testsuite/Makefile.am: New
1200 * configure.ac: Add testsuite/Makefile.
1201 * Makefile.in, testsuite/Makefile.in, configure: Regenerate.
1202 * beginend.c (GTM_begin_transaction): Install wbetl_dispatch.
1203 (_ITM_abortTransaction): Finalize implementation method; pass
1204 transaction properties to longjmp.
1205 (GTM_restart_transaction): Split out from ...
1206 (_ITM_commitTransaction): ... here.
1207 * config/linux/x86/futex_bits.h (cpu_relax, atomic_write_barrier):
1208 Move to config/x86/target.h.
1209 * config/linux/alpha/futex_bits.h: New.
1210 * config/x86/sjlj.S (GTM_longjmp): Fix 64-bit input register.
1211 * config/x86/target.h: Disable target types for 32-bit.
1212 * config/alpha/sjlj.S, config/alpha/target.h: New.
1213 * libitm.h (struct gtm_dispatch): Add init, fini.
1214 (enum restart_reason): New.
1215 (struct gtm_transaction): Add method and restarts.
1216 * retry.c (GTM_decide_retry_strategy): Implement.
1217 * serial.c (serial_init, serial_fini): New.
1218 (GTM_serialmode): Finialize outgoing method.
1219 * method-wbetl.c: New.
1221 2008-12-09 Richard Henderson <rth@redhat.com>
1223 * config/x86/target.h (_ITM_ALL_TARGET_TYPES, _ITM_TYPE_ATTR): New.
1224 * configure.tgt (i386-*, x86_64-*): Don't force SSE.
1225 * dispatch.c (_ITM_##R##T, _ITM_##W##T): Use _ITM_TYPE_ATTR.
1226 * libitm.h (_ITM_ALL_TARGET_TYPES, _ITM_TYPE_ATTR): Provide default.
1227 (_ITM_TYPE_M64, _ITM_TYPE_M128, _ITM_TYPE_M256): Move to x86 header.
1228 (_ITM_ALL_TYPES): Use _ITM_ALL_TARGET_TYPES.
1229 * local.c (_ITM_L##T): Use _ITM_TYPE_ATTR.
1230 * serial.c (serial_R##T, serial_W##T): Likewise.
1232 2008-11-21 Richard Henderson <rth@redhat.com>