]> git.ipfire.org Git - thirdparty/gcc.git/blame - libitm/ChangeLog
re PR c/68908 (inefficient code for _Atomic operations)
[thirdparty/gcc.git] / libitm / ChangeLog
CommitLineData
e7f7330f
TR
12015-11-26 Torvald Riegel <triegel@redhat.com>
2
3 * method-ml.cc (ml_mg): Use multiplicative instead of simple hashing.
4 (ml_wt_dispatch::pre_write): Adapt.
5 (ml_wt_dispatch::pre_load): Likewise.
6
4f8a3b87
TR
72015-11-22 Torvald Riegel <triegel@redhat.com>
8
9 * libitm_i.h (gtm_alloc_action): Remove union.
10 * testsuite/libitm.c/alloc-1.c: New.
11
258c1d07
TR
122015-11-19 Torvald Riegel <triegel@redhat.com>
13
14 * testsuite/libitm.c++/eh-5.C: New.
15 * libitm.h (_ITM_cxa_free_exception): New.
16 * libitm.map (_ITM_cxa_free_exception): Add it.
17 * libitm.texi: Update ABI docs.
18 * libitm_i.h (gtm_transaction_cp::cxa_unthrown): Remove.
19 (gtm_transaction_cp::cxa_uncaught_count): Add.
20 (gtm_thread::cxa_unthrown): Remove.
21 (gtm_thread::cxa_uncaught_count_ptr): Add.
22 (gtm_thread::cxa_uncaught_count): Add.
23 (gtm_thread::drop_references_allocations): Rename to...
24 (gtm_thread::discard_allocation): ... this and adapt.
25 (gtm_thread::init_cpp_exceptions): New.
26 * beginend.cc (gtm_thread::gtm_thread): Adapt EH handling.
27 (gtm_thread::begin_transaction): Likewise.
28 (gtm_transaction_cp::save): Likewise.
29 (gtm_thread::trycommit): Likewise.
30 * eh_cpp.cc: Add overview comments.
31 (__cxa_eh_globals, __cxa_get_globals, __cxa_free_exception): Declare.
32 (free_any_exception, _ITM_cxa_free_exception): New.
33 (gtm_thread::init_cpp_exceptions): Define.
34 (_ITM_cxa_allocate_exception, _ITM_cxa_throw): Adapt.
35 (_ITM_cxa_begin_catch, _ITM_cxa_end_catch): Likewise.
36 (gtm_thread::revert_cpp_exceptions): Likewise.
37
c518678b
TR
382015-11-09 Torvald Riegel <triegel@redhat.com>
39
40 * alloc_cpp.cc (_ZdlPvX, _ZdlPvXRKSt9nothrow_t, _ZGTtdlPvX,
41 _ZGTtdlPvXRKSt9nothrow_t, delsz_opnt): New.
42 * libitm.map: Add _ZGTtdlPvX and _ZGTtdlPvXRKSt9nothrow_t.
43 * libitm_i.h (gtm_alloc_action): Add free_fn_sz and sz. Add comments.
44 (gtm_thread::forget_allocations): New overload with size_t argument.
45 * alloc.c (gtm_thread::forget_allocation): Define new overload and
46 adapt existing one.
47 (gtm_thread::record_allocation): Adapt.
48 (gtm_thread::commit_allocations_1): Adapt.
49 (gtm_thread::commit_allocations_2): Adapt.
50 * testsuite/libitm.c++/newdelete.C: New.
51
1e44e857
DJ
522015-10-27 Daniel Jacobowitz <dan@codesourcery.com>
53 Joseph Myers <joseph@codesourcery.com>
54 Mark Shinwell <shinwell@codesourcery.com>
55 Andrew Stubbs <ams@codesourcery.com>
56 Rich Felker <dalias@libc.org>
57
58 * config/sh/sjlj.S (_ITM_beginTransaction): Bypass PLT calling
59 GTM_begin_transaction for compatibility with FDPIC.
60
9e531d37
DM
612015-10-09 David Malcolm <dmalcolm@redhat.com>
62
63 * testsuite/lib/libitm.exp: Load multiline.exp before prune.exp,
64 using load_gcc_lib.
65
c629c246
GFM
662015-08-20 Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org> (tiny change)
67
68 PR libitm/61164
69 * local_atomic (__always_inline): Rename to...
70 (__libitm_always_inline): ... this.
71
cd5a9a74
CSLL
722015-07-03 Carlos Sánchez de La Lama <csanchezdll@gmail.com>
73
74 PR target/52482
75 * config/powerpc/sjlj.S: Port to Xcode 2.5.
76
ea023bcf
UB
772015-05-27 Uros Bizjak <ubizjak@gmail.com>
78
d778b5a0
UB
79 * config/linux/x86/futex_bits.h (sys_futex0) [__x86_64__]: Change
80 operands "op" and "val" to int.
81
822015-05-27 Uros Bizjak <ubizjak@gmail.com>
83
84 * config/linux/sh/futex_bits.h (sys_futex0) Change operands
85 "op" and "val" to int.
86
872015-05-27 Uros Bizjak <ubizjak@gmail.com>
88
89 * config/linux/alpha/futex_bits.h (sys_futex0) Change operands
90 "op" and "val" to int.
91
922015-05-27 Uros Bizjak <ubizjak@gmail.com>
93
94 * config/linux/futex.cc (gtm_futex_wait, gtm_futex_wake):
95 Declare as static int.
96 (FUTEX_PRIVATE_FLAG): Remove L suffix.
97 * config/linux/futex_bits.h (sys_futex0) Change operand "op" to int.
98
992015-05-27 Uros Bizjak <ubizjak@gmail.com>
100
101 * config/linux/x86/futex_bits.h (sys_futex0) [__PIC__]: Remove
102 sys_futex0 function.
ea023bcf 103
503902f9
MH
1042015-05-13 Michael Haubenwallner <michael.haubenwallner@ssi-schaefer.com>
105
106 * Makefile.in: Regenerated with automake-1.11.6.
107 * aclocal.m4: Likewise.
108 * configure: Likewise.
109 * testsuite/Makefile.in: Likewise.
110
96ce40cb
GR
1112015-04-22 Gregor Richards <gregor.richards@uwaterloo.ca>
112
113 * config/arm/hwcap.cc: Use fcntl.h instead of sys/fcntl.h.
114 * config/linux/x86/tls.h: Only use __GLIBC_PREREQ if defined.
115
3a07b160
L
1162015-01-15 H.J. Lu <hongjiu.lu@intel.com>
117
118 PR libitm/64360
119 * libitm.c/stackundo.c (test2): Make it static.
120 (test1): Likewise.
121
5624e564
JJ
1222015-01-05 Jakub Jelinek <jakub@redhat.com>
123
124 Update copyright years.
125
b67cd4e3
JJ
1262015-01-05 Jakub Jelinek <jakub@redhat.com>
127
128 * libitm.texi: Bump @copying's copyright year.
129
69aef6dc
KT
1302014-12-12 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
131
132 * testsuite/lib/libitm.exp: Load target-utils.exp.
133 Move load of target-supports.exp earlier.
134
68bc9270
UB
1352014-12-03 Uros Bizjak <ubizjak@gmail.com>
136
137 * configure.tgt (x86_64): Tune -m32 multilib to generic.
138
a699d672
L
1392014-11-21 H.J. Lu <hongjiu.lu@intel.com>
140
141 PR bootstrap/63784
142 * configure: Regenerated.
143
ebf6d33b
FXC
1442014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
145
146 PR target/63610
147 * configure: Regenerate.
148
99183741
MP
1492014-10-06 Marek Polacek <polacek@redhat.com>
150
151 * testsuite/libitm.c/memcpy-1.c: Declare getpagesize.
152 * testsuite/libitm.c/memset-1.c: Likewise.
153
b6334cf4
RH
1542014-07-24 Richard Henderson <rth@redhat.com>
155
156 * config/aarch64/sjlj.S (_ITM_beginTransaction): Use post-inc
157 addressing mode in epilogue.
158
3c698bf0
RO
1592014-05-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
160
161 * acinclude.m4 (LIBITM_CHECK_LINKER_HWCAP): Check for
162 -mclear-hwcap instead.
163 * configure: Regenerate.
164 * clearcap.map: Remove.
165
dbed5a9b
JM
1662014-05-21 John Marino <gnugcc@marino.st>
167
168 * configure.tgt (*-*-dragonfly*): New target.
169
b17f08dd
RH
1702014-05-19 Richard Henderson <rth@redhat.com>
171
172 * config/aarch64/sjlj.S: New file.
173 * config/aarch64/target.h: New file.
174 * configure.tgt: Enable aarch64.
175
5e1f630a
RO
1762014-04-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
177
178 * config/generic/asmcfi.h: Also check for
179 __GCC_HAVE_DWARF2_CFI_ASM.
180
84c2f4b0
RH
1812013-04-02 Richard Henderson <rth@redhat.com>
182
183 * config/alpha/target.h (PAGE_SIZE, FIXED_PAGE_SIZE): Remove.
184 * config/arm/target.h, config/sh/target.h: Likewise.
185 * config/sparc/target.h, config/x86/target.h: Likewise.
186
7cc51d64
JJ
1872014-03-26 Jakub Jelinek <jakub@redhat.com>
188
189 * config/linux/futex_bits.h: Include errno.h.
190 (sys_futex0): If syscall returns -1, return -errno rather than
191 -1.
192
c288ec8f
JM
1932014-03-26 Joseph Myers <joseph@codesourcery.com>
194
195 * libitm.texi (Index): Rename to Library Index.
196
ed100f5d
L
1972014-01-13 H.J. Lu <hongjiu.lu@intel.com>
198
199 PR libitm/53113
200 * Makefile.am (x86_sse.lo): Append -msse to CXXFLAGS.
201 (x86_avx.lo): Append -mavx to CXXFLAGS.
202 * Makefile.in: Regenerate.
203
f93608e6
RS
2042014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
205
206 Update copyright years
207
98db73df
TB
2082014-01-02 Tobias Burnus <burnus@net-b.de>
209
210 * libitm.texi: Bump @copying's copyright year.
211
b54214fe
UW
2122013-11-14 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
213
214 * config/powerpc/sjlj.S [__powerpc64__ && _CALL_ELF == 2]:
215 (FUNC): Define ELFv2 variant.
216 (END): Likewise.
217 (HIDDEN): Likewise.
218 (CALL): Likewise.
219 (BASE): Likewise.
220 (LR_SAVE): Likewise.
221
3cbe17f7
AM
2222013-09-20 Alan Modra <amodra@gmail.com>
223
224 * configure: Regenerate.
225
6fb471d8
TR
2262013-08-30 Torvald Riegel <triegel@redhat.com>
227
228 * config/posix/rwlock.cc: Fix initialization order.
229
bec9ec3f
TR
2302013-08-30 Torvald Riegel <triegel@redhat.com>
231
232 * libitm_i.h (gtm_thread): Assign an asm name to serial_lock.
233 (htm_fastpath): Assign an asm name.
234 * libitm.h (_ITM_codeProperties): Add non-ABI flags used by custom
235 HTM fast paths.
236 (_ITM_actions): Likewise.
237 * config/x86/target.h (HTM_CUSTOM_FASTPATH): Enable custom fastpath on
238 x86_64.
239 * config/x86/sjlj.S (_ITM_beginTransaction): Add custom HTM fast path.
240 * config/posix/rwlock.h (gtm_rwlock): Update comments. Move summary
241 field to the start of the structure.
242 * config/linux/rwlock.h (gtm_rwlock): Update comments.
243 * beginend.cc (gtm_thread::begin_transaction): Add retry policy
244 handling for custom HTM fast paths.
245
1869217f
AK
2462013-08-14 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
247 Revert:
248 2013-08-02 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
249
250 * configure.tgt: Add -msoft-float to XCFLAGS.
251
d62d5152
AK
2522013-08-02 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
253
254 * configure.tgt: Add -msoft-float to XCFLAGS.
255
aaaffb2a
AK
2562013-07-29 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
257
258 * config/s390/target.h (htm_begin, htm_commit, htm_abort)
259 (htm_transaction_active): Enable zEC12 instructions in the
260 assembler.
261 * configure.tgt: Remove -Wa,-march=zEC12 from XCFLAGS.
262
167f68ed
AK
2632013-07-17 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
264
265 * acinclude.m4: Add htm asm check for s390.
266 * configure.tgt: Add -mhtm and -Wa,-march=zEC12 to the options.
267 * configure: Regenerate.
268 * config/s390/target.h: Remove __HTM__ check.
269 (htm_available): Call getauxval to get hwcaps and check whether
270 HTM is available or not.
271
0258b6e4
PB
2722013-07-15 Peter Bergner <bergner@vnet.ibm.com>
273
274 * acinclude.m4 (LIBITM_CHECK_AS_HTM): New.
275 * configure.ac: Use it.
276 (AC_CHECK_HEADERS): Check for sys/auxv.h.
277 (AC_CHECK_FUNCS): Check for getauxval.
278 * config.h.in, configure: Rebuild.
279 * configure.tgt (target_cpu): Add -mhtm to XCFLAGS.
280 * config/powerpc/target.h: Include sys/auxv.h and htmintrin.h.
281 (USE_HTM_FASTPATH): Define.
282 (_TBEGIN_STARTED, _TBEGIN_INDETERMINATE, _TBEGIN_PERSISTENT,
283 _HTM_RETRIES) New macros.
284 (htm_abort, htm_abort_should_retry, htm_available, htm_begin, htm_init,
285 htm_begin_success, htm_commit, htm_transaction_active): New functions.
286
5a3fe9b6
AK
2872013-06-27 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
288
289 * config/s390/target.h: Include htmintrin.h.
290 (_HTM_ITM_RETRIES): New macro definition.
291 (htm_available, htm_init, htm_begin, htm_begin_success)
292 (htm_commit, htm_abort, htm_abort_should_retry): New functions.
293
6c84d576
IS
2942013-06-20 Iain Sandoe <iain@codesourcery.com>
295 Cesar Philippidis <cesar@codesourcery.com>
296
297 * testsuite/lib/libitm.exp: Reorder lib loads into dependency order.
298 Do not load_gcc_lib gcc-dg.exp and add a comment as to why.
299 * testsuite/libitm.c/c.exp: load_gcc_lib gcc-dg.exp.
300 * testsuite/libitm.c++/c++.exp: load_gcc_lib gcc-dg.exp.
301
480c696b
TR
3022013-06-20 Torvald Riegel <triegel@redhat.com>
303
304 * query.cc (_ITM_inTransaction): Abort when using the HTM fastpath.
305 (_ITM_getTransactionId): Same.
306 * config/x86/target.h (htm_transaction_active): New.
307
b1db457b
TR
3082013-06-20 Torvald Riegel <triegel@redhat.com>
309
310 PR libitm/57643
311 * beginend.cc (gtm_thread::begin_transaction): Handle reentrancy in
312 the HTM fastpath.
313
51249377
GP
3142013-03-31 Gerald Pfeifer <gerald@pfeifer.com>
315
316 PR bootstrap/56714
317 * local_atomic (__always_inline): Always define our version.
318 (__calculate_memory_order): Mark inline.
319 (atomic_thread_fence): Ditto.
320 (atomic_signal_fence): Ditto.
321 (atomic_bool::atomic_flag_test_and_set_explicit): Ditto.
322 (atomic_bool::atomic_flag_clear_explicit): Ditto.
323 (atomic_bool::atomic_flag_test_and_set): Ditto.
324 (atomic_bool::atomic_flag_clear): Ditto.
325
f818478b
JJ
3262013-04-23 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
327
328 * config/s390/sjlj.S: New file.
329 * config/s390/target.h: New file.
330 * configure.tgt: Set options for S/390.
331
ab4425be
AK
3322013-03-23 Andi Kleen <ak@linux.intel.com>
333
334 * local_atomic (__always_inline): Add.
335 (__calculate_memory_order, atomic_thread_fence,
336 atomic_signal_fence, test_and_set, clear, store, load,
337 exchange, compare_exchange_weak, compare_exchange_strong,
338 fetch_add, fetch_sub, fetch_and, fetch_or, fetch_xor):
339 Add __always_inline to force inlining.
340
6c59ffd1
IS
3412013-02-11 Iain Sandoe <iain@codesourcery.com>
342 Jack Howarth <howarth@bromo.med.uc.edu>
343 Patrick Marlier <patrick.marlier@gmail.com>
344
345 PR libitm/55693
346 * alloc_cpp.cc: Enable function declarations on darwin.
347 * eh_cpp.cc: Likewise.
348
75f9527c
RS
3492013-02-03 Richard Sandiford <rdsandiford@googlemail.com>
350
351 Update copyright years.
352
64fbcc74
TR
3532012-11-09 Torvald Riegel <triegel@redhat.com>
354
355 * beginend.cc (htm_fastpath): New.
356 (gtm_thread::begin_transaction, _ITM_commitTransaction,
357 _ITM_commitTransactionEH): Add HTM fastpath handling.
358 * config/linux/rwlock.h (gtm_rwlock.is_write_locked): New.
359 * config/posix/rwlock.h (gtm_rwlock.is_write_locked): New.
360 * config/x86/target.h (htm_available, htm_init, htm_begin_success,
361 htm_begin, htm_commit, htm_abort, htm_abort_should_retry): New.
362 * configure.tgt: Add -mrtm to XCFLAGS.
363 * method-serial.cc (htm_mg, o_htm_mg, htm_dispatch, dispatch_htm): New.
364 (gtm_thread::serialirr_mode): Add HTM fastpath handling.
365 * libitm_i.h (htm_fastpath, dispatch_htm): Declare.
366 * retry.cc (parse_default_method): Add HTM method parsing.
367 (gtm_thread::number_of_threads_changed): Use HTM by default if
368 available.
369
b9efc877
TS
3702012-11-04 Thomas Schwinge <thomas@codesourcery.com>
371
372 * configure: Regenerate.
373
07d3b5c8
RH
3742012-10-31 Richard Henderson <rth@redhat.com>
375
376 * acinclude.m4 (LIBITM_CHECK_AS_RTM): New.
377 * configure.ac: Use it.
378 * config.h.in, configure: Rebuild.
379 * testsuite/Makefile.in: Rebuild.
380
eb00e959
TR
3812012-10-24 Torvald Riegel <triegel@redhat.com>
382
383 * libitm.texi: Clarify ABI requirements for data-logging functions.
384
b679c813
TR
3852012-10-24 Torvald Riegel <triegel@redhat.com>
386
387 * retry.cc (gtm_thread::decide_begin_dispatch): Ask dispatch whether
388 it requires serial mode instead of assuming that for certain
389 dispatchs.
390 * dispatch.h (abi_dispatch::requires_serial): New.
391 (abi_dispatch::abi_dispatch): Adapt.
392 * method-gl.cc (gl_wt_dispatch::gl_wt_dispatch): Adapt.
393 * method-ml.cc (ml_wt_dispatch::ml_wt_dispatch): Same.
394 * method-serial.cc (serialirr_dispatch::serialirr_dispatch,
395 serial_dispatch::serial_dispatch,
396 serialirr_onwrite_dispatch::serialirr_onwrite_dispatch): Same.
397
0c609a21
UB
3982012-10-02 Uros Bizjak <ubizjak@gmail.com>
399
400 * config/x86/target.h (struct gtm_jmpbuf): Merge x86_64
401 and ia32 declarations some more.
402 * config/x86/sjlj.S (_ITM_beginTransaction): Move ret to common code.
403
c0758df9
JJ
4042012-09-20 Jakub Jelinek <jakub@redhat.com>
405
406 PR other/43620
407 * configure.ac (AM_INIT_AUTOMAKE): Add no-dist.
408 * configure: Regenerate.
409 * Makefile.in: Regenerate.
410
690c45b8
DE
4112012-09-14 David Edelsohn <dje.gcc@gmail.com>
412
413 * configure: Regenerated.
414
68a12ef3
UB
4152012-07-31 Uros Bizjak <ubizjak@gmail.com>
416
417 * config/x86/target.h (cpu_relax): Use __builtin_ia32_pause.
418
f2f9a097
PM
4192012-05-21 Patrick Marlier <patrick.marlier@gmail.com>
420
421 * eh_cpp.cc: Fix __cxa_end_catch declaration.
422
e6d5f8c9
L
4232012-05-16 H.J. Lu <hongjiu.lu@intel.com>
424
425 * configure: Regenerated.
426
0100e3b3
L
4272012-04-04 H.J. Lu <hongjiu.lu@intel.com>
428
429 PR libitm/52854
430 * config/x86/target.h (gtm_jmpbuf): Replace long with long long
431 for x86-64.
432
2f6935f4
TG
4332012-04-03 Tristan Gingold <gingold@adacore.com>
434
435 * configure: Regenerate.
436
b9c23a61
L
4372012-03-31 H.J. Lu <hongjiu.lu@intel.com>
438
439 PR bootstrap/52812
440 * configure.tgt (i[456]86-*-linux*): Handle -mx32 like -m64.
441
6a26a74d
BRF
4422012-03-16 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
443
444 * testsuite/lib/libitm.exp: load fortran-modules.exp
445
b24513a1
RO
4462012-03-14 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
447
448 * configure.tgt (*-*-irix6*): Remove.
449
0d23faac
TR
4502012-03-13 Torvald Riegel <triegel@redhat.com>
451
452 PR libitm/52526
453 * config/linux/rwlock.cc (GTM::gtm_rwlock::read_lock): Fix lost
454 wake-up.
455
5c30094f
RO
4562012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
457
458 * configure.tgt (*-*-osf*): Remove.
459 * configure: Regenerate.
460
d28b0b08
TR
4612012-03-05 Torvald Riegel <triegel@redhat.com>
462
463 * dispatch.h (CREATE_DISPATCH_METHODS_MEM): Don't execute
464 memtransfer/memset if size isn't larger than zero.
465
034209bc
TR
4662012-03-02 Torvald Riegel <triegel@redhat.com>
467
468 * libitm.texi: Link to specification and add a usage example.
469
bc8da6ba
TR
4702012-02-24 Torvald Riegel <triegel@redhat.com>
471
472 * retry.cc (GTM::gtm_thread::number_of_threads_changed): Change
473 default dispatch for more than 1 thread to ml_wt.
474
63b08143
TR
4752012-02-20 Torvald Riegel <triegel@redhat.com>
476
477 * method-gl.cc (gl_wt_dispatch::orec): Put on separate cacheline.
478
4c9bd6ac
TR
4792012-02-20 Torvald Riegel <triegel@redhat.com>
480
481 * method-gl.cc (gl_wt_dispatch::rollback): Optimize memory orders.
482
651ff415
TR
4832012-02-20 Torvald Riegel <triegel@redhat.com>
484
485 * method-gl.cc (gl_wt_dispatch::trycommit): Remove handling of
486 serial mode corner cases made obsolete by prior gtm_rwlock changes.
487 (gl_wt_dispatch.rollback): Same.
488
efee0113
TR
4892012-02-20 Torvald Riegel <triegel@redhat.com>
490
491 * method-gl.cc (gl_wt_dispatch::pre_write): Optimize memory orders.
492
33a03827
TR
4932012-02-20 Torvald Riegel <triegel@redhat.com>
494
495 * method-gl.cc (gl_wt_dispatch::memtransfer_static): Add missing undo
496 for RfW src. Optimize number of calls to gtm_thr.
497
a19db3f2
TR
4982012-02-20 Torvald Riegel <triegel@redhat.com>
499
500 * beginend.cc (GTM::gtm_thread::begin_transaction): Move serial lock
501 acquisition to ...
502 * retry.cc (GTM::gtm_thread::decide_begin_dispatch): ... here.
503 (default_dispatch): Make atomic.
504 (GTM::gtm_thread::set_default_dispatch): Access atomically.
505 (GTM::gtm_thread::decide_retry_strategy): Access atomically and
506 use decide_begin_dispatch() if default_dispatch might have changed.
507 (GTM::gtm_thread::number_of_threads_changed): Initialize
508 default_dispatch here.
509
e948a1fb
IS
5102012-02-15 Iain Sandoe <iains@gcc.gnu.org>
511 Patrick Marlier <patrick.marlier@gmail.com>
512
513 PR libitm/52220
514 * alloc_cpp.cc: No dummy definitions for darwin.
515 * eh_cpp.cc: Likewise.
516
72824d5e
RH
5172012-02-14 Richard Henderson <rth@redhat.com>
518
519 * config/x86/target.h (GTM_longjmp): Correct the .cfi corrections.
520
1f319dba
UB
5212012-02-14 Uros Bizjak <ubizjak@gmail.com>
522
523 * config/x86/target.h (GTM_longjmp): Correct .cfi directives.
524
31772c95
TR
5252012-02-14 Torvald Riegel <triegel@redhat.com>
526
527 * libitm_i.h (GTM::gtm_rwlog_entry): New.
528 (GTM::gtm_thread): Add read and write logs.
529 (GTM::dispatch_ml_wt): Declare.
530 * retry.cc (parse_default_method): Support ml_wt.
531 * method-ml.cc: New file.
532 * Makefile.am: Add method-ml.cc.
533 * Makefile.in: Regenerate.
534
5b9cf5d2
TR
5352012-02-14 Torvald Riegel <triegel@redhat.com>
536
537 * dispatch.h (GTM::abi_dispatch::supports): New.
538 (GTM::method_group::reinit): New.
539 * retry.cc (GTM::gtm_thread::decide_retry_strategy): Use reinit().
540 (GTM::gtm_thread::number_of_threads_changed): Check that the method
541 supports the current situation.
542
7d33bcb7
TR
5432012-02-14 Torvald Riegel <triegel@redhat.com>
544
545 * util.cc (GTM::xcalloc): New.
546 * common.h (GTM::xcalloc): Declare.
547
62513f7b
EB
5482012-02-14 Eric Botcazou <ebotcazou@adacore.com>
549
550 * config/sparc/target.h (cpu_relax): Read from CC register.
551 * config/sparc/sjlj.S (GTM_longjmp): Restore %fp atomically.
552
5532012-02-14 Uros Bizjak <ubizjak@gmail.com>
d4a698d4
UB
554
555 * config/x86/target.h (GTM_longjmp): Jump indirect from memory address.
556
f3f5e3c3
EB
5572012-02-13 Eric Botcazou <ebotcazou@adacore.com>
558
62513f7b 559 * configure.tgt (target_cpu): Handle sparc and sparc64/sparcv9.
f3f5e3c3
EB
560 * config/sparc/cacheline.h: New file.
561 * config/sparc/target.h: Likewise.
562 * config/sparc/sjlj.S: Likewise.
563 * config/linux/sparc/futex_bits.h: Likewise.
564
5652012-02-13 Eric Botcazou <ebotcazou@adacore.com>
255a9a1b
EB
566
567 * configure.ac (link_itm): Fix comment.
568 * configure: Regenerate.
569 * testsuite/lib/libitm.exp: Do not pass -litm for the link.
570
681355e3
RO
5712012-01-31 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
572
fc985d2f 573 PR libitm/51822
62513f7b 574 * testsuite/libitm.c++/c++.exp (lang_link_flags): Add -shared-libgcc.
681355e3
RO
575 Correct libgomp references.
576
999bcff5
TR
5772012-01-24 Torvald Riegel <triegel@redhat.com>
578
579 * config/linux/rwlock.cc (GTM::gtm_rwlock::write_unlock): Fix reader
580 wake-up.
581
9848887a
UB
5822012-01-24 Uros Bizjak <ubizjak@gmail.com>
583
584 * config/x86/target.h (gtm_jmpbuf) [__x86_64__]: Move rip to the
585 end of structure.
586 * config/x86/sjlj.S (_ITM_beginTransaction) [__x86_64__]: Update
587 offset values. Do not copy return address. Decrement stack
588 by 56 bytes only.
589 (GTM_longjump) [__x86_64__]: Update offset values.
590
5752c591
UB
5912012-01-23 Uros Bizjak <ubizjak@gmail.com>
592
593 PR libitm/51830
594 * config/x86/sjlj.S (_ITM_beginTransaction) [!__x86_64__]: Load
595 the first function argument to %eax.
596
61e72ca4
RO
5972012-01-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
598
599 * libitm.h (_ITM_getThreadnum): Remove.
600 * libitm.map (_ITM_getThreadnum): Remove from LIBITM_1.0.
601
9ce91011
RO
6022012-01-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
603
604 * clearcap.map: New file.
605 * acinclude.m4 (LIBITM_CHECK_LINKER_HWCAP): New test.
606 * configure.ac: Call it.
607 Clear HWCAP_LDFLAGS if defaulting to -mavx.
608 * Makefile.am (AM_LDFLAGS): Add $(HWCAP_LDFLAGS)
609 * configure: Regenerate.
610 * Makefile.in: Regenerate.
611 * testsuite/Makefile.in: Regenerate.
612
3b4f05ec
RO
6132012-01-17 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
614
615 PR libitm/51173
616 * testsuite/libitm.c++/static_ctor.C: Skip test, note PR, remove
617 include, exclude options.
618
aab74ee9
TR
6192012-01-14 Torvald Riegel <triegel@redhat.com>
620
621 * local.cc (GTM::gtm_undolog::rollback): Truncate undo log after
622 rolling back.
623 * containers.h (GTM::vector::set_size): New.
624
07b6642b
TR
6252012-01-14 Torvald Riegel <triegel@redhat.com>
626
627 PR libitm/51855
628 * config/generic/tls.h (GTM::mask_stack_top): New.
629 (GTM::mask_stack_bottom): Declare.
630 * config/generic/tls.c (GTM::mask_stack_bottom): New.
631 * local.cc (gtm_undolog::rollback): Filter out any updates that
632 overlap the libitm stack. Add current transaction as parameter.
633 * libitm_i.h (GTM::gtm_undolog::rollback): Adapt.
634 * beginend.cc (GTM::gtm_thread::rollback): Adapt.
635 * testsuite/libitm.c/stackundo.c: New test.
636
8377e5e5
RH
6372012-01-10 Richard Henderson <rth@redhat.com>
638
639 * libitm_i.h (_Unwind_DeleteException): Declare weak.
640 * eh_cpp.cc (_Unwind_DeleteException): Define for
641 !HAVE_ELF_STYLE_WEAKREF.
642
11f30bb0
TR
6432012-01-08 Torvald Riegel <triegel@redhat.com>
644
645 * local.cc (GTM_LB): Use GTM::gtm_undolog.
646 (GTM::gtm_thread::drop_references_undolog): Remove.
647 (GTM::gtm_thread::commit_undolog,
648 GTM::gtm_thread::rollback_undolog): Move to ...
649 * libitm_i.h (GTM::gtm_undolog): ...here. New.
650 (GTM::gtm_undolog_entry): Remove.
651 (GTM::gtm_thread): Adapt.
652 * beginend.cc (GTM::gtm_thread::rollback): Adapt.
653 (GTM::gtm_thread::trycommit): Adapt.
654 * method-serial.cc (serial_dispatch::log): Adapt.
655 * method-gl.cc (gl_wt_dispatch::pre_write): Adapt.
656 (gl_wt_dispatch::store): Fix likely/unlikely.
657 * containers.h (GTM::vector::resize): Add additional_capacity
658 parameter and handle it.
659 (GTM::vector::resize_noinline): New/adapt.
660 (GTM::vector::push): New.
661
a32e5e93
RH
6622012-01-06 Richard Henderson <rth@redhat.com>
663
664 * configure.tgt: Support powerpc-linux and powerpc-darwin.
665 * config/linux/powerpc/futex_bits.h: New file.
666 * config/powerpc/cacheline.h: New file.
667 * config/powerpc/sjlj.S: New file.
668 * config/powerpc/target.h: New file.
669 * config/generic/asmcfi.h (cfi_offset): New.
670 (cfi_restore, cfi_undefined): New.
671
1f53a8e6
AH
6722012-01-05 Aldy Hernandez <aldyh@redhat.com>
673
674 PR other/51171
675 * testsuite/libitm.c/reentrant.c: Remove xfail.
676 (thread): Pass x to pure().
be223aaf 677 From Patrik Marlier <patrick.marlier@gmail.com>.
1f53a8e6 678
c898f7b8
TR
6792011-12-24 Torvald Riegel <triegel@redhat.com>
680
681 * beginend.cc (GTM::gtm_thread::trycommit): Don't enforce
682 privatization safety if already in serial mode.
683
610e3901
TR
6842011-12-24 Torvald Riegel <triegel@redhat.com>
685
686 * beginend.cc (GTM::gtm_thread::restart): Add and handle
687 finish_serial_upgrade parameter.
688 * libitm.h (GTM::gtm_thread::restart): Adapt declaration.
689 * config/linux/rwlock.cc (GTM::gtm_rwlock::write_lock_generic):
690 Don't unset reader flag.
691 (GTM::gtm_rwlock::write_upgrade_finish): New.
692 * config/posix/rwlock.cc: Same.
693 * config/linux/rwlock.h (GTM::gtm_rwlock::write_upgrade_finish):
694 Declare.
695 * config/posix/rwlock.h: Same.
696 * method-serial.cc (GTM::gtm_thread::serialirr_mode): Unset reader
697 flag after commit or after rollback when restarting.
698
799142bf
TR
6992011-12-24 Torvald Riegel <triegel@redhat.com>
700
701 * beginend.cc (GTM::gtm_thread::begin_transaction): Add comment.
702 (GTM::gtm_thread::try_commit): Changed memory order.
703 * config/linux/alpha/futex_bits.h (sys_futex0): Take atomic int
704 as parameter.
705 * config/linux/x86/futex_bits.h (sys_futex0): Same.
706 * config/linux/sh/futex_bits.h (sys_futex0): Same.
707 * config/linux/futex_bits.h (sys_futex0): Same.
708 * config/linux/futex.cc (futex_wait, futex_wake): Same.
709 * config/linux/futex.h (futex_wait, futex_wake): Same.
710 * config/linux/rwlock.h (gtm_rwlock::writers,
711 gtm_rwlock::writer_readers, gtm_rwlock::readers): Change to atomic
712 ints.
713 * config/linux/rwlock.cc (gtm_rwlock::read_lock,
714 gtm_rwlock::write_lock_generic, gtm_rwlock::read_unlock,
715 gtm_rwlock::write_unlock): Fix memory orders and fences.
716 * config/posix/rwlock.cc (gtm_rwlock::read_lock,
717 gtm_rwlock::write_lock_generic, gtm_rwlock::read_unlock,
718 gtm_rwlock::write_unlock): Same.
719 * config/linux/rwlock.h (gtm_rwlock::summary): Change to atomic int.
720 * method-gl.cc (gl_mg::init, gl_wt_dispatch::memtransfer_static,
721 gl_wt_dispatch::memset_static, gl_wt_dispatch::begin_or_restart):
722 Add comments.
723 (gl_wt_dispatch::pre_write, gl_wt_dispatch::validate,
724 gl_wt_dispatch::load, gl_wt_dispatch::store,
725 gl_wt_dispatch::try_commit, gl_wt_dispatch::rollback): Fix memory
726 orders and fences. Add comments.
727
b0f96e35
JJ
7282011-12-21 Jakub Jelinek <jakub@redhat.com>
729
730 * Makefile.am (AM_CXXFLAGS): Put $(XCFLAGS) first.
731 * Makefile.in: Regenerated.
732
cc163247
KK
7332011-12-17 Kaz Kojima <kkojima@gcc.gnu.org>
734
735 * configure.tgt: Add sh* case.
736 * config/sh/target.h: New file.
737 * config/sh/sjlj.S: New file.
738 * config/linux/sh/futex_bits.h: New file.
739
aebac0ca
RH
7402011-12-14 Richard Henderson <rth@redhat.com>
741
742 * config/arm/hwcap.h, config/arm/hwcap.cc: New files.
743 * config/arm/sjlj.S, config/arm/target.h: New files.
744 * config/generic/asmcfi.h (cfi_adjust_cfa_offset): New.
745 (cfi_rel_offset): New.
746 * config/linux/futex_bits.h: New file.
747 * config/linux/futex.cc: Include futex_bits.h here...
748 * config/linux/futex.h: ... not here.
749 * Makefile.am (libitm_la_SOURCES) <ARCH_ARM>: Add hwcap.cc.
750 * configure.ac (ARCH_AM): New conditional.
751 * Makefile.in, configure: Rebuild.
752 * configure.tgt: Handle ARM.
753
36cfbee1
RH
7542011-12-13 Richard Henderson <rth@redhat.com>
755
5d9d05d3
RH
756 * config/posix/rwlock.cc (gtm_rwlock::write_lock_generic): Fix
757 signed/unsigned comparison werror.
758
36cfbee1
RH
759 * local_atomic: New file.
760 * libitm_i.h: Include it.
761 (gtm_thread::shared_state): Use atomic template.
762 * beginend.cc (GTM::gtm_clock): Use atomic template.
763 (global_tid): Use atomic template if 64-bit atomics available.
764 (gtm_thread::gtm_thread): Update shared_state access.
765 (gtm_thread::trycommit): Likewise.
766 (choose_code_path): Update global_tid access.
767 * method-gl.cc (gl_mg::orec): Use atomic template. Update all users.
768 * stmlock.h (GTM::gtm_clock): Use atomic template.
769 (gtm_get_clock, gtm_inc_clock): Update accesses.
770 * config/linux/rwlock.cc (gtm_rwlock::read_lock): Remove
771 redundant __sync_synchronize after atomic shared_state access.
772 * config/posix/rwlock.cc (gtm_rwlock::read_lock): Likewise.
773 (gtm_rwlock::write_lock_generic): Likewise.
774 (gtm_rwlock::read_unlock): Likewise.
775 * config/alpha/target.h (atomic_read_barrier): Remove.
776 (atomic_write_barrier): Remove.
777 * config/x86/target.h (atomic_read_barrier): Remove.
778 (atomic_write_barrier): Remove.
779
062f93f2
RH
7802011-11-30 Richard Henderson <rth@redhat.com>
781
782 * libitm_i.h (GTM_longjmp): Swap first and second arguments.
783 * beginend.c (_ITM_abortTransaction): Update to match.
784 (GTM::gtm_thread::restart): Likewise.
785 * config/alpha/sjlj.S (GTM_longjmp): Likewise.
786 * config/x86/sjlj.S (GTM_longjmp): Likewise.
787
bd8aaa86
IS
7882011-11-23 Iain Sandoe <iains@gcc.gnu.org>
789
790 * Makefile.am (libitm_la_LDFLAGS): Remove "-no-undefined".
791 * Makefile.in: Regenerate.
792
8cf36bb3
IS
7932011-11-22 Iain Sandoe <iains@gcc.gnu.org>
794
795 * configure.ac: Use GCC_CHECK_ELF_STYLE_WEAKREF.
796 * alloc_cpp.cc: Generate dummy functions if we don't
797 HAVE_ELF_STYLE_WEAKREF.
798 * eh_cpp.cc: Likewise.
799 * configure: Regenerate.
800 * aclocal.m4: Likewise.
801 * config.h.in: Likewise.
802 * Makefile.in: Likewise.
803 * testsuite/Makefile.in: Likewise.
804
0b41ebef
IS
8052011-11-22 Iain Sandoe <iains@gcc.gnu.org>
806
807 * config/x86/sjlj.S (CONCAT1, CONCAT2, SYM): Respond to
808 __USER_LABEL_PREFIX__ for targets that use it.
8cf36bb3 809 (TYPE, SIZE, HIDDEN): New macros to assist on non-elf targets.
0b41ebef
IS
810 (_ITM_beginTransaction): Use SYM, TYPE, SIZE macros to assist
811 in portability to non-elf targets.
8cf36bb3 812 (GTM_longjmp): Likewise.
0b41ebef
IS
813 * libitm_i.h (begin_transaction): Apply __USER_LABEL_PREFIX__
814 where required.
815
9c9d352a
IS
8162011-11-22 Iain Sandoe <iains@gcc.gnu.org>
817
818 * testsuite/libitm.c/memcpy-1.c: Allow for MAP_ANON spelling.
819 * testsuite/libitm.c/memset-1.c: Likewise.
820
c6084f68
AT
8212011-11-21 Andreas Tobler <andreast@fgznet.ch>
822
823 * configure: Regenerate.
824
adcd36bc
RO
8252011-11-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
826
827 * acinclude.m4 (LIBITM_CHECK_LINKER_FEATURES): Handle gold.
828 (LIBITM_ENABLE_SYMVERS): Handle sun style.
829 * Makefile.am: Handle sun style versioning.
830 (libitm_la_LINK): Add $(libitm_la_LDFLAGS).
831 * configure: Regenerate.
832 * Makefile.in: Regenerate.
833
59659b59
RO
8342011-11-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
835
836 * config/generic/asmcfi.h: Fix comment.
837 * config/x86/sjlj.S (_ITM_beginTransaction): Provide ELF PIC code
838 sequence without .hidden support, error for non-ELF targets.
839 (GTM_longjmp) [__ELF__]: Only use .hidden if
840 HAVE_ATTRIBUTE_VISIBILITY.
841
d846e425
RO
8422011-11-17 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
843
844 * alloc_cpp.cc [__osf__] (_ZnwX, _ZdlPv, _ZnaX, _ZdaPv,
845 _ZnwXRKSt9nothrow_t, _ZdlPvRKSt9nothrow_t, _ZdaPvRKSt9nothrow_t):
846 Dummy functions.
847 * eh_cpp.cc [__osf__] (__cxa_allocate_exception, __cxa_throw,
848 __cxa_begin_catch, __cxa_end_catch, __cxa_tm_cleanup): Likewise.
849
80713347
UB
8502011-11-16 Uros Bizjak <ubizjak@gmail.com>
851
852 PR bootstrap/51098
853 * acinclude.m4 (LIBITM_CHECK_AS_AVX): Fix target selector.
854 * configure: Regenerate.
855
2841f85e
L
8562011-11-14 H.J. Lu <hongjiu.lu@intel.com>
857
858 * testsuite/lib/libitm.exp: Check ia32 instead of ilp32.
859
8851b429
RO
8602011-11-10 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
861
862 * config/alpha/sjlj.S (_ITM_beginTransaction) [!__ELF__]: Don't use
863 .hidden.
864 (.note.GNU-stack): Only use if __linux__.
865 * alloc_cpp.cc [!__osf__] (_ZnaXRKSt9nothrow_t): Dummy function.
866 * testsuite/libitm.c/notx.c: Use dg-options "-pthread".
867 * testsuite/libitm.c/reentrant.c: Likewise.
868 * testsuite/libitm.c/simple-2.c: Likewise.
869 * testsuite/libitm.c/txrelease.c: Likewise.
870 * testsuite/libitm.c++/static_ctor.C: Likewise.
871
d4b17902
RH
8722011-11-10 Richard Henderson <rth@redhat.com>
873
874 * config/x86/x86_avx.cc: Remove #undef __AVX__ hack. Tidy comments.
875 * Makefile.am (x86_avx.lo): Only add -mavx if ARCH_X86_AVX.
876 * configure.ac (ARCH_X86_AVX): New conditional.
877 * Makefile.in, configure: Rebuild.
878
430616e7
RH
8792011-11-09 Richard Henderson <rth@redhat.com>
880
881 * acinclude.m4 (LIBITM_CHECK_AS_AVX): New.
882 * configure.ac: Use it.
883 * config.h.in, configure: Rebuild.
884 * config/x86/x86_avx.cc: Handle !HAVE_AS_AVX.
885
79b1edb6
RH
8862011-11-09 Richard Henderson <rth@redhat.com>
887
888 * barrier.tpl, memcpy.cc, memset.cc, method-wbetl.cc: Remove file.
889 * config/alpha/unaligned.h: Remove file.
890 * config/generic/unaligned.h: Remove file.
891 * config/x86/unaligned.h: Remove file.
892 * config/generic/cachepage.h: Remove file.
893 * config/posix/cachepage.cc: Remove file.
894 * config/generic/cacheline.cc: Remove file.
895 * config/x86/cacheline.cc: Remove file.
896 * config/generic/cacheline.h (gtm_cacheline): Remove the
897 store_mask, copy_mask, copy_mask_wb methods.
898 * config/x86/cacheline.h: Likewise.
899 * config/alpha/cacheline.h: Fall back to generic after setting size.
900 * config/generic/tls.cc (gtm_mask_stack): Remove.
901 * config/x86/x86_avx.cc (GTM_vpperm_shift): Remove.
902 (GTM_vpalignr_table): Remove.
903 * config/x86/x86_sse.cc (GTM_palignr_table): Remove.
904 (GTM_pshift_table): Remove.
905 * config/libitm_i.h: Don't include cachepage.h.
906 * Makefile.am (libitm_la_SOURCES): Remove cacheline.cc, cachepage.cc
907 * Makefile.in, testsuite/Makefile.in: Rebuild.
908
4bdd090f
RH
9092011-11-09 Richard Henderson <rth@redhat.com>
910
8ee9fac2
RH
911 * config/x86/cacheline.h (gtm_cacheline::store_mask): Use .byte
912 to emit branch prediction hint.
913
9bdc6343
RH
914 * config/x86/sjlj.S: Protect elf directives with __ELF__.
915 Protect .note.GNU-stack with __linux__.
916
4bdd090f
RH
917 * configure.ac (GCC_AS_CFI_PSEUDO_OP): Test it.
918 * configure, aclocal.m4, config.h.in: Rebuild.
919 * config/generic/asmcfi.h: New file.
920 * config/x86/sjlj.S: Use it.
921
4408b086
RH
9222011-11-08 Richard Henderson <rth@redhat.com>
923
924 * local.cc (_ITM_LB): Use a normal call, not a function alias.
925
01f3428c
RH
9262011-11-08 Richard Henderson <rth@redhat.com>
927
3d3b05ff
RH
928 * configure.tgt: Test correct directory for supported cpus.
929
01f3428c
RH
930 * configure.ac: Exit if unsupported.
931 * configure: Rebuild.
932 * configure.tgt: Delete boilerplate from libgomp for unsupported
933 targets. Set UNSUPPORTED for unsupported targets.
934
07f03cd3
RO
9352011-11-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
936
937 * configure.tgt: Handle i386 like i[456]86.
938 * config/generic/tls.h [!HAVE_ARCH_GTM_THREAD] (gtm_thr): Don't
939 take address.
940 * config/generic/tls.cc [!HAVE_ARCH_GTM_THREAD ||
941 !HAVE_ARCH_GTM_THREAD_DISP] (_gtm_thr_tls): New variable.
942
0a35513e
AH
9432011-11-05 Aldy Hernandez <aldyh@redhat.com>
944
945 * method-wbetl.cc: Update copyright notice.
946 * aatree.cc: Same.
947 * util.cc: Same.
948 * libitm.h: Same.
949 * memset.cc: Same.
950 * eh_cpp.cc: Same.
951 * barrier.tpl: Same.
952 * useraction.cc: Same.
953 * stmlock.h: Same.
954 * memcpy.cc: Same.
955 * common.h: Same.
956 * config/generic/tls.cc: Same.
957 * config/generic/cacheline.h: Same.
958 * config/generic/cachepage.h: Same.
959 * config/generic/cacheline.cc: Same.
960 * config/generic/unaligned.h: Same.
961 * config/x86/cacheline.h: Same.
962 * config/x86/cacheline.cc: Same.
963 * config/x86/unaligned.h: Same.
964 * config/alpha/cacheline.h: Same.
965 * config/alpha/unaligned.h: Same.
966 * config/alpha/sjlj.S: Same.
967 * config/posix/cachepage.cc: Same.
968 * config/linux/futex.h: Same.
969 * config/linux/alpha/futex_bits.h: Same.
970
9712011-11-04 Torvald Riegel <triegel@redhat.com>
972
973 * libitm.texi: No cover text and invariant sections.
974
9752011-11-03 Richard Henderson <rth@redhat.com>
976
977 * local_type_traits: New file.
978 * libitm_i.h: Use it. Use C headers, not C++ wrappers.
979
9802011-11-03 Richard Henderson <rth@redhat.com>
981
982 * configure.ac: Don't test for gfortran.
983 * configure: Rebuild.
984
985 * testsuite/lib/libitm.exp: Don't include gfortran-dg.exp.
986 * testsuite/libitm.c++/c++.exp: Don't use gfortran-dg-runtest.
987
9882011-11-03 Aldy Hernandez <aldyh@redhat.com>
989
990 * testsuite/libitm.c/memcpy-1.c: Add copyright notice.
991 * testsuite/libitm.c/memset-1.c: Same.
992 * testsuite/libitm.c/c.exp: Same.
993 * testsuite/lib/libitm-dg.exp: Same.
994 * testsuite/lib/libitm.exp: Same.
995 * testsuite/libitm.c++/c++.exp: Same.
996
9972011-11-03 Aldy Hernandez <aldyh@redhat.com>
998
999 * testsuite/config/default.exp: Update copyright date.
1000 * configure.ac: Add copyright info.
1001 * configure.tgt: Same.
1002
10032011-11-03 Aldy Hernandez <aldyh@redhat.com>
1004
1005 * testsuite/libitm.c/reentrant.c: XFAIL.
1006 * testsuite/libitm.c++/static_ctor.C: XFAIL.
1007
10082011-10-29 Torvald Riegel <triegel@redhat.com>
1009
1010 * beginend.cc (GTM::gtm_thread::rollback): Add aborting flag and
1011 handle aborts.
1012 (_ITM_abortTransaction): Handle aborts of outer transactions.
1013 * libitm_i.h: Same.
1014 * eh_cpp.cc (GTM::gtm_thread::revert_cpp_exceptions): Fix assertion.
1015 * libitm.texi: Document aborts of outer transactions.
1016 * testsuite/libitm.c/cancel.c: New file.
1017
10182011-10-19 Torvald Riegel <triegel@redhat.com>
1019
1020 * testsuite/*: Change __transaction to __transaction_atomic or
1021 __transaction_relaxed.
1022
10232011-10-19 Torvald Riegel <triegel@redhat.com>
1024
1025 * config/linux/x86/tls.h (abi_disp): Make TLS slot read volatile.
1026 (gtm_thr): Same.
1027
10282011-10-19 Torvald Riegel <triegel@redhat.com>
1029
1030 * libitm_i.h: Add gl_wt dispatch.
1031 * retry.cc (parse_default_method): Same.
1032 * method-gl.cc: New file.
1033 * Makefile.am: Use method-gl.cc.
1034 * Makefile.in: Rebuild.
1035
10362011-10-19 Torvald Riegel <triegel@redhat.com>
1037
1038 * beginend.cc (GTM::gtm_thread::trycommit): Ensure privatization
1039 safety if requested by a TM method.
1040 * dispatch.h (GTM::abi_dispatch::trycommit): Add parameter for
1041 privatization safety.
1042 * method-serial.cc: Same.
1043
10442011-10-19 Torvald Riegel <triegel@redhat.com>
1045
1046 * libitm_i.h: Renamed gtm_local_undo to gtm_undolog_entry.
1047 (GTM::gtm_thread): Renamed local_undo to undolog. Renamed
1048 undolog-related member functions from *_local to *_undolog.
1049 * local.cc (gtm_thread::commit_undolog): Same.
1050 * beginend.cc (GTM::gtm_thread::trycommit): Same.
1051 (GTM::gtm_thread::rollback): Roll back undolog before
1052 dispatch-specific rollback.
1053
10542011-10-19 Torvald Riegel <triegel@redhat.com>
1055
1056 * retry.cc (GTM::gtm_thread::decide_retry_strategy): Handle
1057 re-initialization of the current method group.
1058 * libitm_i.h (GTM::gtm_restart_reason): Add restart reason for this.
1059
10602011-10-19 Torvald Riegel <triegel@redhat.com>
1061
1062 * alloc.cc (commit_allocations_2): Do not free transaction-local
1063 memory when committing a nested transaction.
1064
10652011-10-19 Torvald Riegel <triegel@redhat.com>
1066
1067 * method-serial.cc (GTM::gtm_thread::serialirr_mode): Fixed: Use
1068 serial-irrevocable dispatch, not serial.
1069
10702011-10-19 Torvald Riegel <triegel@redhat.com>
1071
1072 * libitm_i.h (GTM::gtm_restart_reason): Re-arrange and clean up
1073 declarations.
1074 * dispatch.h (GTM::abi_dispatch::begin_or_restart): New.
1075 * method-serial.cc: Implement begin_or_restart().
1076 * beginend.cc (GTM::gtm_thread::begin_transaction): Call
1077 dispatch-specific begin_or_restart().
1078 (GTM::gtm_thread::restart): Same.
1079
10802011-08-23 Torvald Riegel <triegel@redhat.com>
1081
1082 * retry.cc (GTM::gtm_thread::decide_retry_strategy): Cleanup. Fix
1083 restarting without switching to serial mode.
1084 (GTM::gtm_thread::decide_begin_dispatch): Let the caller set the
1085 transaction state. Choose closed-nesting alternative if available.
1086 (GTM::gtm_thread::set_default_dispatch): New.
1087 (parse_default_method): New.
1088 (GTM::gtm_thread::number_of_threads_changed): New.
1089 * method-serial.cc (GTM::serial_mg): New method group class.
1090 (GTM::serialirr_dispatch): Belongs to serial_mg. Remove reinit and
1091 fini.
1092 (GTM::serial_dispatch): Same.
1093 (GTM::serialirr_onwrite_dispatch): Same.
1094 (GTM::gtm_thread::serialirr_mode): Remove calls to fini.
1095 * beginend.cc (GTM::gtm_thread::~gtm_thread): Maintain number of
1096 registered threads.
1097 (GTM::gtm_thread::gtm_thread): Same.
1098 (_ITM_abortTransaction): Remove calls to abi_dispatch::fini().
1099 (GTM::gtm_thread::trycommit): Same. Reset number of restarts.
1100 (GTM::gtm_thread::begin_transaction): Let decide_begin_dispatch()
1101 choose dispatch but set state according to dispatch here.
1102 * dispatch.h (GTM::abi_dispatch::fini): Move to method group.
1103 (GTM::method_group): New class.
1104 (GTM::abi_dispatch): Add comments. Maintain pointer to method_group.
1105 * libitm_i.h (GTM::gtm_thread): Add declarations for new members.
1106 * libitm.texi: Document TM methods, method groups, method life cycle.
1107 Rename method sets to method groups.
1108
11092011-08-23 Torvald Riegel <triegel@redhat.com>
1110
1111 * config/x86/tls.h: Moved to ...
1112 * config/linux/x86/tls.h: ... here.
1113
11142011-08-23 Torvald Riegel <triegel@redhat.com>
1115
1116 * config/x86/tls.h: Use __x86_64__ instead of __LP64__.
1117 Add X32 support.
1118 * config/x86/sjlj.S: Same.
1119
11202011-08-19 Torvald Riegel <triegel@redhat.com>
1121
1122 * config/linux/rwlock.h: New file.
1123 * config/linux/rwlock.c: New file.
1124 * configure.ac: Reenable futex support (undo SVN rev 157758).
1125 * Makefile.am: Same.
1126 * configure.tgt: Same.
1127 * config/linux/alpha/futex_bits.h: Same.
1128 * config/linux/futex.h: Same. Return number of woken processes.
1129 * config/linux/futex.cc: Same.
1130 (futex_wait): Remove spinning.
1131 * config/linux/x86/futex_bits.h: Same. Set futex timeout to zero.
1132 Use __x86_64__ instead of __LP64__.
1133 * aclocal.m4: Include generic futex checks.
1134 * configure: Rebuild.
1135 * Makefile.in: Rebuild.
1136 * testsuite/Makefile.in: Rebuild.
1137 * beginend.cc: Include pthread.h.
1138 * config/posix/cachepage.cc: Same.
1139
11402011-08-12 Torvald Riegel <triegel@redhat.com>
1141
1142 * config/x86/tls.h (gtm_tx, set_gtm_tx, setup_gtm_thr): Removed.
1143 (abi_disp, set_abi_disp): Move to tx's TLS slot.
1144 (set_gtm_thr): New.
1145 * config/generic/tls.h (gtm_tx, set_gtm_tx, setup_gtm_thr): Removed.
1146 (set_gtm_thr): New.
1147 (GTM::gtm_thread::thread_num): Removed.
1148 (GTM::gtm_thread): Renamed to GTM::gtm_thread_tls.
1149 * libitm_i.h (GTM::gtm_transaction): Renamed to GTM::gtm_thread. More
1150 tx-to-thread renaming.
1151 * beginend.cc: Adapted to tx-to-thread renaming.
1152 (GTM::gtm_thread::~gtm_thread): Extracted from thread_exit_handler().
1153 (GTM::gtm_thread::gtm_thread): Extracted from begin_transaction().
1154 * query.cc (_ITM_getTransactionId, _ITM_inTransaction): Renamed
1155 gtm_transaction to gtm_thread.
1156 (_ITM_getThreadnum): Removed. Not supported anymore.
1157 * testsuite/libitm.c/notx.c (main): Removed _ITM_getThreadnum call.
1158 * libitm.texi: Documented that _ITM_getThreadnum is not supported.
1159 * useraction.cc: Renamed gtm_transaction to gtm_thread. Adapted to
1160 gtm_tx-to-gtm_thr renaming if necessary.
1161 * eh_cpp.cc: Same.
1162 * local.cc: Same.
1163 * retry.cc: Same.
1164 * clone.cc: Same.
1165 * alloc.cc: Same.
1166 * alloc_c.cc: Same.
1167 * alloc_cpp.cc: Same.
1168 * method-serial.cc: Same.
1169 * config/generic/tls.cc: Same.
1170 * config/posix/rwlock.h (gtm_rwlock): Same.
1171 * config/posix/rwlock.cc: Same. Adapted to more tx-to-thread renaming.
1172
11732011-08-12 Torvald Riegel <triegel@redhat.com>
1174
1175 * config/posix/rwlock.cc (gtm_rwlock::read_lock): Changed locking
1176 implementation.
1177 (gtm_rwlock::read_unlock): Same.
1178 (gtm_rwlock::write_lock_generic): New. Generalized from ...
1179 (gtm_rwlock::write_lock, gtm_rwlock::write_upgrade): ... these.
1180 * libitm_i.h (GTM::gtm_transaction): Added shared_state.
1181 * config/posix/rwlock.h (GTM::gtm_rwlock): Removed a_reader and
1182 w_upgrade. Replaced by per-transaction flags (in shared_state).
1183 Added c_confirmed_writers.
1184 (GTM::gtm_rwlock::read_lock, GTM::gtm_rwlock::read_unlock,
1185 GTM::gtm_rwlock::write_upgrade): Add tx parameter.
1186 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Same.
1187 * method-serial.cc (GTM::gtm_transaction::serialirr_mode): Same.
1188 * beginend.cc (GTM::gtm_transaction::begin_transaction,
1189 _ITM_abortTransaction, GTM::gtm_transaction::trycommit): Same.
1190 * libitm.texi: Document locking conventions and implementations in
1191 libitm.
1192
11932011-08-12 Torvald Riegel <triegel@redhat.com>
1194
1195 * libitm_i.h (next_tx): Add list of all threads' transaction.
1196 * beginend.cc (GTM::gtm_transaction::begin_transaction): Register
1197 transaction with list of transactions and ...
1198 (thread_exit_handler): ... deregister here.
1199 * config/alpha/target.h: Add HW_CACHELINE_SIZE setting.
1200 * config/x86/target.h: Same.
1201
12022011-08-12 Torvald Riegel <triegel@redhat.com>
1203
1204 * testsuite/libitm.c++/static_ctor.C: New file.
1205
12062011-08-12 Torvald Riegel <triegel@redhat.com>
1207
1208 * testsuite/libitm.c/reentrant.c: New file.
1209
12102011-08-12 Torvald Riegel <triegel@redhat.com>
1211
1212 * config/generic/tls.h: Remove the free list for transactions and ...
1213 * beginend.cc (GTM::gtm_transaction::operator new): ... allocate ...
1214 (GTM::gtm_transaction::operator delete): ... and release here.
1215 (thread_exit_handler): New. Delete tx when thread terminates.
1216 (thread_exit_init): New.
1217 (GTM::gtm_transaction::begin_transaction): Set up on-exit handler.
1218 * testsuite/libitm.c/txrelease.c: New file.
1219
12202011-08-12 Torvald Riegel <triegel@redhat.com>
1221
1222 * query.cc (_ITM_getThreadnum): Set up gtm_thread if necessary.
1223 * testsuite/libitm.c/notx.c: New file.
1224
12252011-08-12 Torvald Riegel <triegel@redhat.com>
1226
1227 * config/generic/tls.h (gtm_thread): Move local_tid from here ...
1228 * libitm_i.h (local_tid): ... to here.
1229 * beginend.cc (GTM::gtm_transaction::begin_transaction): Same.
1230 (GTM::gtm_transaction::operator new): Set up gtm_thread if necessary.
1231
12322011-08-12 Torvald Riegel <triegel@redhat.com>
1233
1234 * retry.cc (GTM::gtm_transaction::decide_begin_dispatch): Use
1235 serialirr_onwrite_dispatch as new default for now.
1236 * method-serial.cc (serialirr_onwrite_dispatch): New.
1237 (GTM::dispatch_serialirr_onwrite): New.
1238 * libitm_i.h: Same.
1239
12402011-08-12 Torvald Riegel <triegel@redhat.com>
1241
1242 * beginend.cc (GTM::gtm_transaction::rollback): Roll back tx id as well.
1243 * query.cc (_ITM_getTransactionId): There is no active transaction if
1244 the current nesting level is zero.
1245
12462011-07-28 Torvald Riegel <triegel@redhat.com>
1247
1248 * beginend.cc (GTM::gtm_transaction::rollback): Fix nesting level
1249 rollback.
1250
12512011-07-28 Torvald Riegel <triegel@redhat.com>
1252
1253 * retry.cc (GTM::gtm_transaction::decide_begin_dispatch): Get
1254 transaction properties from the caller instead of from the
1255 transaction object.
1256 * libitm_i.h: Same.
1257 * beginend.cc (GTM::gtm_transaction::begin_transaction): Same.
1258
12592011-07-28 Torvald Riegel <triegel@redhat.com>
1260
1261 * local.cc (gtm_transaction::rollback_local): Support closed nesting.
1262 * eh_cpp.cc (GTM::gtm_transaction::revert_cpp_exceptions): Same.
1263 * dispatch.h: Same.
1264 * method-serial.cc: Same.
1265 * beginend.cc (GTM::gtm_transaction::begin_transaction): Change to
1266 flat nesting as default, and closed nesting on demand.
1267 (GTM::gtm_transaction::rollback): Same.
1268 (_ITM_abortTransaction): Same.
1269 (GTM::gtm_transaction::restart): Same.
1270 (GTM::gtm_transaction::trycommit): Same.
1271 (GTM::gtm_transaction::trycommit_and_finalize): Removed.
1272 (choose_code_path): New.
1273 (GTM::gtm_transaction_cp::save): New.
1274 (GTM::gtm_transaction_cp::commit): New.
1275 * query.cc (_ITM_inTransaction): Support flat nesting.
1276 * libitm_i.h (GTM::gtm_transaction_cp): New helper struct for nesting.
1277 (GTM::gtm_transaction): Support flat and closed nesting.
1278 * alloc.cc (commit_allocations_2): New.
1279 (commit_cb_data): New helper struct.
1280 (GTM::gtm_transaction::commit_allocations): Handle nested
1281 commits/rollbacks.
1282 * libitm.texi: Update user action section, add description of nesting.
1283
12842011-07-28 Torvald Riegel <triegel@redhat.com>
1285
1286 * libitm_i.h: Add closed nesting as restart reason.
1287 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Same.
1288
12892011-07-28 Torvald Riegel <triegel@redhat.com>
1290
1291 * useraction.cc: Use vector instead of list to store actions.
1292 Also support partial rollbacks for closed nesting.
1293 * libitm_i.h (GTM::gtm_transaction::user_action): Same.
1294 * beginend.cc: Same.
1295
12962011-07-28 Torvald Riegel <triegel@redhat.com>
1297
1298 * dispatch.h (GTM::abi_dispatch): Add can_run_uninstrumented_code and
1299 closed_nesting flags, as well as a closed nesting alternative.
1300 * method-serial.cc: Same.
1301 (serial_dispatch): Renamed to serialirr_dispatch.
1302 (GTM::dispatch_serialirr): Same.
1303 (serial_dispatch_ul): Renamed to serial_dispatch.
1304 (GTM::dispatch_serial): Same.
1305
13062011-07-28 Torvald Riegel <triegel@redhat.com>
1307
1308 * libitm.h (_ITM_codeProperties): Change pr_hasElse to the ABI's value.
1309
13102011-07-28 Torvald Riegel <triegel@redhat.com>
1311
1312 * aatree.h (aa_tree::remove): New.
1313 (aa_tree::operator new): Add placement new.
1314
13152011-07-02 Torvald Riegel <triegel@redhat.com>
1316
1317 * containers.h: New file.
1318 * util.cc (xmalloc, xrealloc): Accept cacheline-alloc flag.
1319 * libitm_i.h (xmalloc, xrealloc): Moved declarations from here ...
1320 * common.h: ... to here.
1321 (local_undo): Use GTM::vector for gtm_transaction::local_undo.
1322 * local.cc: Same.
1323
13242011-06-30 Torvald Riegel <triegel@redhat.com>
1325
1326 * libitm_i.h (STATE_ABORTING): Remove.
1327 * beginend.cc (_ITM_abortTransaction): Same.
1328 (GTM::gtm_transaction::trycommit_and_finalize): Same.
1329 * libitm.h (_ITM_registerThrownObject, _ITM_tryCommitTransaction): Remove.
1330 (_ITM_rollbackTransaction): Remove.
1331 * beginend.cc: Same.
1332 * libitm.map: Same.
1333 * libitm.texi: Document these ABI changes.
1334
13352011-06-30 Torvald Riegel <triegel@redhat.com>
1336
1337 * libitm.texi: New file.
1338 * Makefile.am: Add libitm.texi.
1339 * Makefile.in: Rebuild.
1340
13412011-06-30 Torvald Riegel <triegel@redhat.com>
1342
1343 * libitm_i.h: Move parts to common.h and dispatch.h.
1344 * common.h: New file.
1345 * dispatch.h: New file, new dispatch class.
1346 Rename GTM::abi_dispatch::lock_type to ls_modifier.
1347 RenameGTM::abi_dispatch::NOLOCK to NONTXNAL.
1348 * beginend.cc (GTM::gtm_transaction::begin_transaction): Delegate mode
1349 decision to retry.cc.
1350 * retry.cc (GTM::gtm_transaction::decide_retry_strategy): Use serial mode
1351 only.
1352 (GTM::gtm_transaction::decide_begin_dispatch): Same.
1353 * method-serial.cc: Adapt to new dispatch. Add serial mode with undo
1354 logging.
1355 * barrier.cc: Use new barriers definitions.
1356 (abi_dispatch::memmove_overlap_check): New.
1357 * config/x86/x86_sse.cc: Same.
1358 * config/x86/x86_avx.cc: Same.
1359 * Makefile.am: Don't build readonly and wbetl methods, memset.cc and
1360 memcpy.cc.
1361 * Makefile.in: Rebuild.
1362 * method-readonly.cc: Remove.
1363 * method-wbetl.cc: Rename GTM::abi_dispatch::lock_type to ls_modifier.
1364 Rename GTM::abi_dispatch::NOLOCK to NONTXNAL.
1365
13662011-06-30 Torvald Riegel <triegel@redhat.com>
1367
1368 * alloc_c.cc (_ITM_dropReferences): Don't support it anymore.
1369 * testsuite/libitm.c++/dropref.C: _ITM_dropReferences is expected to fail.
1370 * testsuite/libitm.c/dropref-2.c: Same.
1371 * testsuite/libitm.c/dropref.c: Same.
1372
13732011-06-30 Torvald Riegel <triegel@redhat.com>
1374
1375 * config/generic/tls.h (gtm_disp): Rename to abi_disp.
1376 * config/generic/tls.h (set_gtm_disp): Rename to set_abi_disp.
1377 * libitm_i.h: Rename gtm_dispatch to abi_dispatch.
1378 * alloc_c.cc: Same.
1379 * barrier.tpl: Same.
1380 * beginend.c: Same.
1381 * config/generic/tls.h: Same.
1382 * config/x86/tls.h: Same.
1383 * libitm_i.h: Same.
1384 * memcpy.cc: Same.
1385 * memset.cc: Same.
1386 * method-readonly.cc: Same.
1387 * method-serial.cc: Same.
1388 * method-wbetl.cc: Same.
1389 * retry.cc: Same.
1390
13912011-03-03 Richard Henderson <rth@redhat.com>
1392
1393 * config/posix/rwlock.cc (write_upgrade): Add missing case.
1394 From Patrik Marlier <patrick.marlier@unine.ch>.
1395
13962011-02-03 Richard Henderson <rth@redhat.com>
1397
1398 * acinclude.m4 (LIBITM_CHECK_SIZE_T_MANGLING): New.
1399 * configure.ac: Use it.
1400 * configure, config.h.in: Rebuild.
1401 * alloc_cpp.cc (_ZnwX): Use MANGLE_SIZE_T in constructing the name.
1402 (_ZnaX, _ZnwXRKSt9nothrow_t, _ZnaXRKSt9nothrow_t, _ZGTtnwX,
1403 _ZGTtnaX, _ZGTtnwXRKSt9nothrow_t, _ZGTtnaXRKSt9nothrow_t): Likewise.
1404 * libitm.map: Use wildcards to match size_t mangling.
1405
14062010-12-14 Richard Henderson <rth@redhat.com>
1407
1408 * beginend.cc (GTM::gtm_transaction::begin_transaction): Allocate
1409 blocks of TIDs per thread.
1410 * config/generic/tls.h (struct gtm_thread): Add local_tid member.
1411 (setup_gtm_thr): Return the thread structure.
1412 * config/x86/tls.h (setup_gtm_thr): Likewise.
1413
14142010-12-14 Richard Henderson <rth@redhat.com>
1415
1416 * clone.cc (table_lock): Remove.
1417 (find_clone): Don't take it.
1418 (ExcludeTransaction): New helper class.
1419 (_ITM_registerTMCloneTable): Use it.
1420 (_ITM_deregisterTMCloneTable): Likewise.
1421
14222010-12-14 Richard Henderson <rth@redhat.com>
1423
1424 * config/x86/tls.h: New file.
1425
14262010-07-15 Richard Henderson <rth@redhat.com>
1427
1428 * Makefile.am (AM_CXXFLAGS): Add -funwind-tables.
1429 * Makefile.in: Rebuild.
1430
14312010-07-13 Aldy Hernandez <aldyh@redhat.com>
1432
1433 * method-wbetl.cc (trydropreference): Fix source line.
1434
14352010-07-13 Aldy Hernandez <aldyh@redhat.com>
1436
1437 * libitm.h: Add comment.
1438 * libitm_i.h (begin_transaction): Add ITM_REGPARM.
1439
14402010-07-07 Aldy Hernandez <aldyh@redhat.com>
1441
1442 * configure.ac: Call LIBITM_CHECK_64BIT_SYNC_BUILTINS.
1443 * beginend.cc (begin_transaction): If 64-bit sync builtins are not
1444 available, use pthread mutexes.
1445 * acinclude.m4 (LIBITM_CHECK_64BIT_SYNC_BUILTINS): New.
1446 * config.h.in: Regenerate.
1447 * configure: Regenerate.
1448
14492010-07-06 Aldy Hernandez <aldyh@redhat.com>
1450
1451 * libitm.h (ITM_PURE): Define.
1452 Declare _ITM_malloc, _ITM_calloc, and _ITM_free.
1453
14542010-06-28 Aldy Hernandez <aldyh@redhat.com>
1455
1456 * method-wbetl.cc (class wbetl_dispatch): Add trydropreference.
1457 (validate): Add comment.
1458 (trydropreference): New.
1459 * method-readonly.cc (class readonly_dispatch): Add
1460 trydropreference.
1461 * alloc_c.cc (_ITM_dropReferences): Remove const attribute.
1462 Call trydropreference().
1463 * libitm.h (_ITM_dropReferences): Remove const attribute.
1464 * method-serial.cc (class serial_dispatch): Add trydropreference.
1465 * libitm_i.h (struct gtm_dispatch): Add trydropreference.
1466
14672010-06-28 Aldy Hernandez <aldyh@redhat.com>
1468
1469 * memcpy.cc (do_memcpy): Comment.
1470
14712010-06-25 Aldy Hernandez <aldyh@redhat.com>
1472
1473 * barrier.tpl: Add comments throughout.
1474
14752010-06-24 Aldy Hernandez <aldyh@redhat.com>
1476
1477 * method-wbetl.cc (struct w_entry): Add comments.
1478 (trycommit): Same.
1479 (rollback): Same.
1480
14812010-06-24 Aldy Hernandez <aldyh@redhat.com>
1482
1483 * alloc_c.cc (_ITM_dropReferences): New.
1484 * libitm.map (_ITM_dropReferences): Add.
1485 * libitm.h (_ITM_dropReferences): Add transaction_pure attribute.
1486 * libitm_i.h (struct gtm_transaction): Declare
1487 drop_references_allocations and drop_references_local.
1488 * local.cc (rollback_local): Ignore memory when applicable.
1489 (drop_references_local): New.
1490
14912010-06-23 Richard Henderson <rth@redhat.com>
1492
1493 * barrier.tpl, beginend.cc, clone.cc, tls.h, memcpy.cc,
1494 memset.cc, method-serial.cc: Revert the 2010-06-16 change.
1495 * config/x86/target.h (struct gtm_jmpbuf): Change CFA type to void*.
1496 * config/alpha/target.h: Likewise.
1497 * config/generic/tls.cc (gtm_mask_stack): Use it.
1498
14992010-06-23 Richard Henderson <rth@redhat.com>
1500
1501 * config/posix/cachepage.cc (gtm_cacheline_page::operator new): Use
1502 a mutex instead of trying a lock-free compare-and-swap on the list.
1503 (gtm_cacheline_page::operator delete): Likewise.
1504
15052010-06-16 Richard Henderson <rth@redhat.com>
1506
1507 * method-wbetl.cc (wbetl_dispatch::trycommit): Discard changes
1508 that overlap the libitm stack.
1509 * barrier.tpl: Mark incoming stack.
1510 * beginend.cc (_ITM_rollbackTransaction, _ITM_abortTransaction,
1511 _ITM_commitTransaction, _ITM_commitTransactionEH): Likewise.
1512 * clone.cc (_ITM_getTMCloneOrIrrevocable): Likewise.
1513 * memcpy.cc, memset.cc: Likewise.
1514 * method-serial.cc (_ITM_changeTransactionMode): Likewise.
1515 * config/generic/tls.h (gtm_thread): Add stack_top member.
1516 (gtm_stack_top, set_gtm_stack_top, struct gtm_stack_marker): New.
1517 * libitm_i.h (gtm_mask_stack): Declare.
1518 * config/generic/tls.cc: New file.
1519 * Makefile.am (libitm_la_SOURCES): Add it.
1520 (AM_CXXFLAGS): Turn off exceptions.
1521 * Makefile.in: Rebuild.
1522
15232010-06-16 Richard Henderson <rth@redhat.com>
1524
1525 * alloc.cc (struct gtm_alloc_action): Move definition ...
1526 * libitm_i.h: ... here.
1527 (class gtm_transaction): Declare new and delete.
1528 * beginend.cc (alloc_tx): Reformulate as operator new.
1529 (free_tx): Reformulate as operator delete.
1530 * config/generic/tls.h (gtm_thread): Change free_tx member to void *.
1531
15322010-06-11 Richard Henderson <rth@redhat.com>
1533
1534 * clone.cc (clone_entry_compare): Fix typo.
1535 From Patrik Marlier <patrick.marlier@unine.ch>.
1536
15372010-05-13 Richard Henderson <rth@redhat.com>
1538
1539 * alloc_c.cc (_ITM_malloc, _ITM_calloc, _ITM_free): Wrap functions
1540 in extern "C".
1541
15422010-05-07 Aldy Hernandez <aldyh@redhat.com>
1543
1544 * libitm_i.h (struct gtm_transaction): Remove
1545 get_allocation_size.
1546 (record_allocation): Remove size parameter.
1547 * libitm.map (_ITM_realloc): Remove.
1548 * alloc_c.cc (_ITM_realloc): Remove.
1549 (_ITM_malloc): Remove size argument to record_allocation.
1550 (_ITM_calloc): Same.
1551 * alloc_cpp.cc (_ZGTtnwm): Same.
1552 (_ZGTtnwmRKSt9nothrow_t): Same.
1553 (_ZGTtnam): Same.
1554 (_ZGTtnamRKSt9nothrow_t): Same.
1555 * alloc.cc (struct gtm_alloc_action): Remove size.
1556 (get_allocation_size): Remove.
1557 (commit_allocations): Add comment.
1558 (record_allocation): Remove size parameter.
1559 (forget_allocation): Remove set of size.
1560
15612010-04-19 Aldy Hernandez <aldyh@redhat.com>
1562
1563 * Makefile.am (abi_version): New.
1564 (AM_CXXFLAGS): Pass abi_version.
1565 * Makefile.in: Regenerate.
1566 * config/x86/unaligned.h: Remove always_inline kludge for vectors.
1567
15682010-04-06 Aldy Hernandez <aldyh@redhat.com>
1569
1570 * clone.cc (_ITM_getTMCloneOrIrrevocable): Rename from
1571 _ITM_getTMCloneOrIrrevokable.
1572 * libitm.h (_ITM_getTMCloneOrIrrevocable): Same.
1573 * libitm.map (_ITM_getTMCloneOrIrrevocable): Same.
1574
15752010-03-26 Aldy Hernandez <aldyh@redhat.com>
1576
1577 * configure.ac: Remove Linux futex support.
1578 * configure.tgt (config_path): Same.
1579 * Makefile.am: Same.
1580 * config/linux: Remove entire directory.
1581 * configure: Rebuild.
1582 * Makefile.in: Rebuild.
1583 * testsuite/Makefile.in: Rebuild.
1584
15852010-03-09 Aldy Hernandez <aldyh@redhat.com>
1586
1587 * retry.cc (decide_retry_strategy): Set state to STATE_SERIAL when
1588 switching to serial mode.
1589 * beginend.cc (trycommit_and_finalize): Unlock serial_lock.
1590
15912010-03-03 Aldy Hernandez <aldyh@redhat.com>
1592
1593 * configure.tgt: Add emacs -*- tags.
1594 * barrier.tpl: Same.
1595
15962010-02-23 Aldy Hernandez <aldyh@redhat.com>
1597
1598 * Makefile.am: Rename serial.cc to method-serial.cc.
1599 * Makefile.in: Regenerate with automake 1.11.1.
1600 * testsuite/Makefile.in: Same.
1601 * aclocal.m4: Regenerate with aclocal 1.11.1.
1602 * method-serial.cc: Rename from serial.cc.
1603 * libitm_i.h (struct gtm_transaction): Update comment on
1604 serialirr_mode.
1605
16062010-02-22 Aldy Hernandez <aldyh@redhat.com>
1607
1608 * libitm_i.h (GTM_longjmp): Add ITM_REGPARM.
1609 * config/linux/rwlock.h (class gtm_rwlock): Add comments.
1610
16112010-02-11 Aldy Hernandez <aldyh@redhat.com>
1612
1613 * configure: Rebuild.
1614
16152009-11-12 Richard Henderson <rth@redhat.com>
1616
1617 * Rewrite everything in C++.
1618
16192009-11-03 Richard Henderson <rth@redhat.com>
1620
1621 * config/x86/x86_sse.c, config/x86/x86_avx.c: New files.
1622 * Makefile.am (libitm_la_SOURCES): Add them.
1623 * configure.ac (ARCH_X86): New conditional.
1624 * Makefile.in, configure: Rebuild.
1625 * configure.tgt: Set up ARCH; do cflags setup at the same time.
1626 Move futex setup into "other system configury" case.
1627 * local.c (rollback_local): Merge into ...
1628 (GTM_rollback_local): ... here.
1629 (GTM_LB): Rename from GTM_alloc_local; do the memcpy here.
1630 (_ITM_LB): Define as an alias to GTM_LB.
1631
16322009-11-03 Richard Henderson <rth@redhat.com>
1633
1634 * method-readonly.c: New file.
1635 * Makefile.am (libitm_la_SOURCES): Add it.
1636 * Makefile.in: Rebuild.
1637 * beginend.c (gtm_stmlock_array, gtm_clock): New.
1638 (GTM_begin_transaction): Use dispatch_readonly for read-only txn.
1639 * libitm_i.h (gtm_stmlock, gtm_version): Move from method-wbetl.c.
1640 (GTM_VERSION_MAX, GTM_VERSION_INVALID, gtm_stmlock_owned_p,
1641 gtm_stmlock_set_owned, gtm_stmlock_get_addr,
1642 gtm_stmlock_get_version, gtm_stmlock_set_version, LOCK_ARRAY_SIZE,
1643 gtm_stmlock_array, gtm_get_stmlock, gtm_clock, RESTART_NOT_READONLY,
1644 gtm_get_clock, gtm_inc_clock): New.
1645 * method-wbetl.c (gtm_version, gtm_stmlock, OWNED_MASK, VERSION_MAX,
1646 LOCK_GET_OWNED, LOCK_SET_ADDR, LOCK_GET_ADDR, LOCK_GET_TIMESTAMP,
1647 LOCK_SET_TIMESTAMP, LOCK_ARRAY_SIZE, LOCK_MASK, LOCK_IDX, GET_LOCK,
1648 locks, gclock, CLOCK, GET_CLOCK, FETCH_AND_INC_CLOCK): Remove and
1649 replace uses with new libitm_i.h symbols.
1650 (dispatch_wbetl): Rename from wbetl_dispatch.
1651 * retry.c (GTM_decide_retry_strategy): If RESTART_NOT_READONLY, move
1652 away from dispatch_readonly; abort if the beginTransaction call
1653 asserted that the transaction was readonly.
1654
16552009-11-03 Richard Henderson <rth@redhat.com>
1656
1657 * memset.c: New file.
1658 * Makefile.am (libitm_la_SOURCES): Add it.
1659 * Makefile.in: Rebuild.
1660 * testsuite/libitm.c/memset-1.c: New.
1661
16622009-11-03 Richard Henderson <rth@redhat.com>
1663
1664 * dispatch.c: Remove file.
1665 * useraction.c (struct gtm_user_action): Move from libitm.h.
1666 * serial.c (GTM_null_read_lock, GTM_null_write_lock): New.
1667 (serial_memset, serial_memmove, serial_memcpy): Remove.
1668 (serial_W*, serial_R*): Remove.
1669 (serial_dispatch): Update to match.
1670 * configure.ac: Move Werror down below configure checks. Don't
1671 check for sys/loadavg.h, do check for malloc.h. Don't check for
1672 getloadavg and clock_gettime; do check for memalign, posix_memalign.
1673 Use GCC_AC_FUNC_MMAP_BLACKLIST
1674 * libitm.h: Split out all internal items to...
1675 * libitm_i.h: ... here. New file.
1676 * copymask.c: New file.
1677 * local.c (struct gtm_local_undo): Move from libitm.h.
1678 (GTM_alloc_local): Rename from alloc_local; export.
1679 * memcpy.c: New file.
1680 * alloc_c.c (_ITM_realloc): Use _ITM_memcpyRnWt directly.
1681 * config/posix/page.c: New file.
1682 * config/posix/target_tls.h: Remove file.
1683 * barrier.c: New file.
1684 * Makefile.am (libitm_la_SOURCES): Add barrier.c, memcpy.c,
1685 copymask.c, page.c.
1686 * alloc.c (struct gtm_alloc_action): Move from libitm.h.
1687 * method-wbetl.c: Rewrite for new cacheline methods.
1688 * Makefile.in, configure, testsuite/Makefile.in, config.h.in: Rebuild.
1689
1690 * config/alpha/sjlj.S: Fix typo.
1691 * config/alpha/target_i.h: Copy functions from alpha/target.h.
1692 * config/alpha/copymask.c: New file.
1693 * config/alpha/target.h (CACHELINE_SIZE): New.
1694 (STRICT_ALIGNMENT, PAGE_SIZE, FIXED_PAGE_SIZE): New.
1695
1696 * config/x86/target_i.h: Copy functions from x86/target.h.
1697 * config/x86/copymask.c: New file.
1698 * config/x86/target.h (_ITM_ALL_TARGET_TYPES): Remove.
1699 (CACHELINE_SIZE, STRICT_ALIGNMENT): New.
1700 (PAGE_SIZE, FIXED_PAGE_SIZE): New.
1701 * config/x86/target_tls.h: Move contents to target_i.h.
1702
1703 * testsuite/libitm.c/clone-1.c: Include libitm.h.
1704 * testsuite/libitm.c/memcpy-1.c: New.
1705
17062009-10-22 Richard Henderson <rth@redhat.com>
1707
1708 * Makefile.am (CCAS, CCASFLAGS, LTCCASCOMPILE): Remove.
1709 (AM_CCASFLAGS): New.
1710 * configure.ac: Add AM_PROG_AS. Use m4_rename_force for
1711 saving/restoring _AC_ARG_VAR_PRECIOUS.
1712 * Makefile.in, aclocal.m4, config.h.in, configure,
1713 testsuite/Makefile.in: Rebuild with automake 1.11; autoconf 2.64.
1714
17152009-10-22 Richard Henderson <rth@redhat.com>
1716
1717 * testsuite/*: Update for new compiler syntax.
1718
17192009-10-21 Richard Henderson <rth@redhat.com>
1720
1721 * libitm.h (_ITM_abortReason): Add outerAbort.
1722
17232009-08-03 Richard Henderson <rth@redhat.com>
1724
1725 * libitm.map (_ITM_commitTransactionEH, _ITM_cxa_allocate_exception,
1726 _ITM_cxa_begin_catch, _ITM_cxa_end_catch, _ITM_cxa_throw): Export.
1727 * method-wbetl.c (struct w_entry): Remove mask.
1728 (wbetl_write, wbetl_load): Return pointer to word containing the data;
1729 adjust all callers.
1730
17312009-07-22 Richard Henderson <rth@redhat.com>
1732
1733 * eh_cpp.c: New file.
1734 * Makefile.am (libitm_la_SOURCES): Add it.
1735 * Makefile.in: Rebuild.
1736 * beginend.c (GTM_rollback_transaction): Undo exception state.
1737 (GTM_trycommit_transaction): Mark inline.
1738 (GTM_trycommit_and_finalize_transaction): Split out from ...
1739 (_ITM_commitTransaction): ... here.
1740 (_ITM_commitTransactionEH): New function.
1741 * libitm.h (struct gtm_transaction): Add cxa_catch_count,
1742 cxa_unthrown, eh_in_flight; reorder.
1743
1744 * testsuite/libitm.c++/c++.exp: New.
1745 * testsuite/libitm.c++/eh-1.C: New.
1746
1747 * aatree.c (aa_free): Remove REGPARM.
1748 * aatree.h: Remove all REGPARM.
1749
17502009-07-18 Richard Henderson <rth@redhat.com>
1751
1752 * aatree.c, aatree.h, alloc.c, alloc_c.c, alloc_cpp.c: New files.
1753 * Makefile.am (libitm_la_SOURCES): Add them.
1754 * Makefile.in: Rebuild.
1755 * beginend.c (GTM_rollback_transaction): Use GTM_commit_allocations.
1756 (GTM_trycommit_transaction): Likewise.
1757 * libitm.h: Include aatree.h
1758 (struct gtm_alloc_action): New.
1759 (struct gtm_transaction): Add alloc_actions.
1760 (GTM_record_allocation, GTM_forget_allocation): Declare.
1761 (GTM_get_allocation_size, GTM_commit_allocations): Declare.
1762 * libitm.map (_ITM_malloc, _ITM_calloc, _ITM_realloc, _ITM_free,
1763 _ZGTtnwm, _ZGTtnam, _ZGTtdlPv, _ZGTtdaPv, _ZGTtnwmRKSt9nothrow_t,
1764 _ZGTtnamRKSt9nothrow_t, _ZGTtdlPvRKSt9nothrow_t,
1765 _ZGTtdaPvRKSt9nothrow_t): Export.
1766
17672009-07-18 Richard Henderson <rth@redhat.com>
1768
1769 * target_tls.h: Move ...
1770 * config/posix/target_tls.h: ... here.
1771
17722009-07-07 Richard Henderson <rth@redhat.com>
1773
1774 * config/x86/target.h (atomic_write_barrier): Use sfence if available.
1775
17762009-07-07 Richard Henderson <rth@redhat.com>
1777
1778 * Update to GPL3.
1779
17802009-07-07 Richard Henderson <rth@redhat.com>
1781
1782 * libitm.h (struct gtm_transaction): Widen id to _ITM_transactionId_t.
1783 * beginend.c (global_tid): Widen to _ITM_transactionId_t.
1784
1785 * configure.tgt: Don't use -ftls-model for x86 linux.
1786 * libitm.h: Include target.h after standard includes.
1787 (_gtm_thr): Rename from gtm_thr.
1788 (setup_gtm_thr, gtm_thr, gtm_tx, set_gtm_tx): New.
1789 (gtm_disp, set_gtm_disp): New.
1790 * beginend.c, dispatch.c, local.c, method-wbetl.c, query.c,
1791 retry.c, serial.c, useraction.c: Use accessor functions throughout.
1792 * config/alpha/target_tls.h, config/x86/target_tls.h: New files.
1793
17942009-07-07 Richard Henderson <rth@redhat.com>
1795
1796 * config/linux/rwlock.c (EZ): New define. Use it throughout.
1797
17982009-07-06 Richard Henderson <rth@redhat.com>
1799
1800 * libitm.h (_ITM_SRCLOCATION_DECL_1, _ITM_SRCLOCATION_DECL_2): Remove.
1801 (_ITM_SRCLOCATION_DEFN_1, _ITM_SRCLOCATION_DEFN_2): Remove.
1802 (_ITM_beginTransaction): Take variadic arguments.
1803 (_ITM_registerThrownObject): Declare.
1804 * beginend.c, serial.c: Update.
1805 * libitm.map: Add _ITM_registerThrownObject.
1806
18072009-01-28 Richard Henderson <rth@redhat.com>
1808
1809 * Makefile.am (libitm_la_SOURCES): Add clone.c.
1810 * Makefile.in: Rebuild.
1811 * beginend.c (_ITM_abortTransaction): Abort if irrevokable.
1812 (GTM_restart_transaction): Fix uninstrumented code check.
1813 * retry.c (GTM_decide_retry_strategy): Add serial check.
1814 * serial.c (GTM_serialmode): Add irrevokable variable. Don't
1815 automatically go irrevokable when in serial mode.
1816 * clone.c: New file.
1817 * libitm.h, libitm.map: Update.
1818
18192009-01-27 Richard Henderson <rth@redhat.com>
1820
1821 * Makefile.am (LTCCASCOMPILE): Define.
1822 (libitm_la_SOURCES): Add methid-wbetl.c.
1823 * testsuite/Makefile.am: New
1824 * configure.ac: Add testsuite/Makefile.
1825 * Makefile.in, testsuite/Makefile.in, configure: Regenerate.
1826 * beginend.c (GTM_begin_transaction): Install wbetl_dispatch.
1827 (_ITM_abortTransaction): Finalize implementation method; pass
1828 transaction properties to longjmp.
1829 (GTM_restart_transaction): Split out from ...
1830 (_ITM_commitTransaction): ... here.
1831 * config/linux/x86/futex_bits.h (cpu_relax, atomic_write_barrier):
1832 Move to config/x86/target.h.
1833 * config/linux/alpha/futex_bits.h: New.
1834 * config/x86/sjlj.S (GTM_longjmp): Fix 64-bit input register.
1835 * config/x86/target.h: Disable target types for 32-bit.
1836 * config/alpha/sjlj.S, config/alpha/target.h: New.
1837 * libitm.h (struct gtm_dispatch): Add init, fini.
1838 (enum restart_reason): New.
1839 (struct gtm_transaction): Add method and restarts.
1840 * retry.c (GTM_decide_retry_strategy): Implement.
1841 * serial.c (serial_init, serial_fini): New.
1842 (GTM_serialmode): Finialize outgoing method.
1843 * method-wbetl.c: New.
1844
18452008-12-09 Richard Henderson <rth@redhat.com>
1846
1847 * config/x86/target.h (_ITM_ALL_TARGET_TYPES, _ITM_TYPE_ATTR): New.
1848 * configure.tgt (i386-*, x86_64-*): Don't force SSE.
1849 * dispatch.c (_ITM_##R##T, _ITM_##W##T): Use _ITM_TYPE_ATTR.
1850 * libitm.h (_ITM_ALL_TARGET_TYPES, _ITM_TYPE_ATTR): Provide default.
1851 (_ITM_TYPE_M64, _ITM_TYPE_M128, _ITM_TYPE_M256): Move to x86 header.
1852 (_ITM_ALL_TYPES): Use _ITM_ALL_TARGET_TYPES.
1853 * local.c (_ITM_L##T): Use _ITM_TYPE_ATTR.
1854 * serial.c (serial_R##T, serial_W##T): Likewise.
1855
18562008-11-21 Richard Henderson <rth@redhat.com>
1857
1858 * Initial commit.