]> git.ipfire.org Git - thirdparty/gcc.git/blob - libmudflap/ChangeLog
backport: Support GNU/kOpenSolaris.
[thirdparty/gcc.git] / libmudflap / ChangeLog
1 2009-03-01 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2
3 * configure: Regenerate.
4
5 2009-02-03 Jakub Jelinek <jakub@redhat.com>
6
7 * mf-runtime.c (__mf_usage): Update copyright notice dates.
8
9 2009-01-23 Jie Zhang <jie.zhang@analog.com>
10
11 * mf-impl.h (__mf_get_state, __mf_set_state): Don't use
12 __thread when TLS support is emulated.
13 * mf-hooks3.c (__mf_get_state, __mf_set_state): Likewise.
14 * mf-runtime.c (__mf_state_1): Likewise.
15 * configure.ac: Use GCC_CHECK_EMUTLS.
16 * configure: Regenerate.
17 * config.h.in: Regenerate.
18
19 2008-12-18 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
20
21 * configure: Regenerate.
22
23 2008-11-26 Janis Johnson <janis187@us.ibm.com>
24
25 PR testsuite/28870
26 * testsuite/lib/mfdg.exp (dg-test): Use new timeout support.
27 (dg-timeout): Remove.
28 (standard-wait): Remove.
29 * testsuite/lib/libmudflap.exp: Include new timeout library files.
30 (libmudflap_target_compile): Set timeout value from new proc.
31
32 2008-11-10 Jakub Jelinek <jakub@redhat.com>
33
34 PR middle-end/35314
35 * testsuite/libmudflap.c/pass67-frag.c: New test.
36
37 2008-10-09 Jakub Jelinek <jakub@redhat.com>
38
39 PR c++/37568
40 * testsuite/libmudflap.c++/pass66-frag.cxx: New test.
41
42 2008-09-26 Peter O'Gorman <pogma@thewrittenword.com>
43 Steve Ellcey <sje@cup.hp.com>
44
45 * configure: Regenerate for new libtool.
46 * Makefile.in: Ditto.
47 * testsuite/Makefile.in: Ditto.
48
49 2008-09-15 Jakub Jelinek <jakub@redhat.com>
50
51 PR libmudflap/36397
52 * testsuite/libmudflap.c/pass64-frag.c: New test.
53
54 2008-06-17 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
55
56 * Makefile.in: Regenerate.
57 * config.h.in: Regenerate.
58 * configure: Regenerate.
59 * testsuite/Makefile.in: Regenerate.
60
61 2008-04-18 Paolo Bonzini <bonzini@gnu.org>
62
63 PR bootstrap/35457
64 * aclocal.m4: Regenerate.
65 * configure: Regenerate.
66
67 2008-03-20 Volker Reichelt <v.reichelt@netcologne.de>
68
69 * testsuite/libmudflap.c/pass63-frag.c: New test.
70
71 2008-03-16 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
72
73 * aclocal.m4: Regenerate.
74 * configure: Likewise.
75 * Makefile.in: Likewise.
76 * testsuite/Makefile.in: Likewise.
77
78 2008-03-02 Jakub Jelinek <jakub@redhat.com>
79
80 * mf-runtime.c (__mf_usage): Update copyright notice dates.
81
82 2008-02-21 Uros Bizjak <ubizjak@gmail.com>
83
84 * testsuite/libmudflap.c/fail8-frag.c: Adjust scan pattern for
85 mudflap dead object.
86 * testsuite/libmudflap.c/fail9-frag.c: Ditto.
87
88 2008-01-24 David Edelsohn <edelsohn@gnu.org>
89
90 * configure: Regenerate.
91
92 2008-01-05 Jakub Jelinek <jakub@redhat.com>
93
94 PR tree-optimization/34618
95 * testsuite/libmudflap.c/pass62-frag.c: New test.
96
97 2008-01-03 Jakub Jelinek <jakub@redhat.com>
98
99 PR c++/34619
100 * testsuite/libmudflap.c++/pass61-frag.cxx: New test.
101
102 2008-01-01 Volker Reichelt <v.reichelt@netcologne.de>
103
104 PR libmudflap/26442
105 * testsuite/libmudflap.c++/pass60-frag.cxx: New test.
106
107 2007-10-15 Maciej W. Rozycki <macro@linux-mips.org>
108
109 * configure: Regenerate following changes to ../config/tls.m4.
110
111 2007-07-26 Tom Tromey <tromey@redhat.com>
112
113 * Makefile.in: Rebuilt.
114 * Makefile.am (clean-local): Removed.
115 (pth/mf-runtime.lo, pth/mf-heuristics.lo, pth/mf-hooks1.lo,
116 pth/mf-hooks2.lo, pth/mf-hooks3.lo): Likewise.
117 (libmudflapth_la_SOURCES): List sources.
118 (libmudflapth_la_LIBADD): Clear.
119 (libmudflapth_la_CFLAGS): New variable.
120
121 2007-07-05 H.J. Lu <hongjiu.lu@intel.com>
122
123 * aclocal.m4: Regenerated.
124
125 2007-06-02 Paolo Bonzini <bonzini@gnu.org>
126
127 * configure: Regenerate.
128
129 2007-05-31 Frank Ch. Eigler <fche@redhat.com>
130
131 From Andi Kleen <ak@suse.de>:
132 * mf-runtime.c (options): Rename structure for compatibility with
133 glibc getopt_long.
134
135 2007-05-23 Steve Ellcey <sje@cup.hp.com>
136
137 * Makefile.in: Regenerate.
138 * configure: Regenerate.
139 * aclocal.m4: Regenerate.
140 * testsuite/Makefile.in: Regenerate.
141
142 2007-03-14 Uros Bizjak <ubizjak@gmail.com>
143
144 * testsuite/libmudflap.cth/pass59-frag.c (main): Fix casting of arg.
145
146 2007-03-01 Brooks Moses <brooks.moses@codesourcery.com>
147
148 * Makefile.am: Add dummy install-pdf target.
149 * Makefile.in: Regenerate
150
151 2007-02-07 Jakub Jelinek <jakub@redhat.com>
152
153 PR libgomp/28468
154 * configure: Regenerate.
155
156 2006-12-04 Eric Botcazou <ebotcazou@libertysurf.fr>
157
158 * configure: Regenerate.
159
160 2006-11-13 Daniel Jacobowitz <dan@codesourcery.com>
161
162 * configure: Regenerated.
163
164 2006-11-10 Frank Ch. Eigler <fche@redhat.com>
165
166 PR libmudflap/28578
167 * mf-hooks1.c (__mf_0fn_malloc): Make the bootstrap buffers
168 static but not function scope static.
169 (free): Skip deallocation attempts for objects placed into
170 bootstrap buffers.
171 * testsuite/libmudflap.cth/pass59-frag.c: New test.
172
173 2006-11-06 Frank Ch. Eigler <fche@redhat.com>
174
175 From Herman ten Brugge <hermantenbrugge@home.nl>:
176 * mf-runtime.c (__mf_uncache_object): Optimize the code so that
177 small and large objects are handled a lot faster.
178
179 2006-11-06 Frank Ch. Eigler <fche@redhat.com>
180
181 * configure.ac (__libc_freeres): Look for it.
182 * mf-impl.h (call_libc_freeres): New configuration flag.
183 * mf-runtime.c (__mf_set_default_options): Set it by default.
184 (__mfu_report): Call it if needed.
185 (__mfu_unregister): Remove "unaccessed registered object" warning.
186 * configure, config.h.in: Regenerated.
187
188 2006-09-18 Tom Tromey <tromey@redhat.com>
189
190 * configure: Rebuilt.
191
192 2006-06-21 Frank Ch. Eigler <fche@redhat.com>
193
194 PR 21274
195 mf-runtime.h installation based on ssp patch for PR 26473 from
196 Mark Mitchell <mark@codesourcery.com>.
197 * configure.ac (ACX_NONCANONICAL_TARGET): Use it.
198 * Makefile.am (target_noncanonical): Define.
199 (libsubincludedir): New variable.
200 (nobase_libsubinclude_HEADERS): Add mf-runtime.h.
201 (include_HEADERS): Remove.
202 * configure, aclocal.m4, config.h.in: Regenerated.
203 * Makefile.in, testsuite/Makefile.in: Likewise.
204 * mf-runtime.h: Add #ifndef protection for conflicting _REENTRANT
205 and _THREAD_SAFE redefinition values.
206
207 2006-05-23 Carlos O'Donell <carlos@codesourcery.com>
208
209 * Makefile.am: Add install-html target. Add install-html to .PHONY
210 * Makefile.in: Regenerate.
211
212 2006-04-19 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
213
214 PR mudflap/26789
215 * testsuite/libmudflap.c++/error1-frag.cxx: New test.
216
217 PR mudflap/26790
218 * testsuite/libmudflap.c++/error2-frag.cxx: New test.
219
220 2006-04-10 Matthias Klose <doko@debian.org>
221
222 * testsuite/lib/libmudflap.exp (libmudflap-init): Recognize multilib
223 directory names containing underscores.
224
225 2005-11-22 Janis Johnson <janis187@us.ibm.com>
226
227 * testsuite/lib/libmudflap.exp (libmudflap-init): Remove -static from
228 MUDFLAP_FLAGS if static library not supported.
229 * testsuite/libmudflap.c/cfrags.exp (MUDFLAP_FLAGS): new.
230 * testsuite/libmudflap.c/externs.exp: Ditto.
231 * testsuite/libmudflap.c++/ctors.exp: Ditto.
232 * testsuite/libmudflap.c++/c++frags.exp: Ditto.
233 * testsuite/libmudflap.cth/cthfrags.exp: Ditto.
234
235 2005-10-04 James E Wilson <wilson@specifix.com>
236
237 * configure.ac (mudflap_cv_entry_point): Use quadrigraphs to declare
238 $name as array of characters with unknown bound. Also store into the
239 array.
240 * configure: Regenerate.
241
242 2005-09-30 James E. Wilson <wilson@specifix.com>
243
244 * configure.ac (pthread.h): Use AC_CHECK_HEADERS instead of
245 AC_CHECK_HEADER.
246 (target_thread_file): New. Set from sed'ed gcc output.
247 (posix_threads): New. Set from target_thread_file. Use instead of
248 ac_have_pthread_h.
249 (pthread_create_version): Move initialization before code using it.
250 * configure: Regenerate.
251
252 * mf-heuristics.c (_end, ENTRY_POINT): Make them arrays with unknown
253 bounds.
254
255 2005-09-29 James E. Wilson <wilson@specifix.com>
256
257 * mf-hooks1.c (__mf_0fn_mmap, mmap, __mf_0fn_munmap, munmap): Protect
258 with HAVE_MMAP ifdef.
259
260 2005-09-23 Frank Ch. Eigler <fche@elastic.org>
261
262 PR 23084.
263 * mf-hooks2.c (accept): Tolerate NULL sockaddr* parameter.
264
265 2005-09-23 Frank Ch. Eigler <fche@elastic.org>
266
267 * testsuite/libmudflap.c++/pass58-frag.cxx: New test for heisenbug 19319.
268
269 2005-09-23 Tom Tromey <tromey@redhat.com>
270
271 * aclocal.m4, configure: Rebuilt.
272 * configure.ac: Use GCC_CHECK_TLS.
273 * acinclude.m4 (LIBMUDFLAP_CHECK_TLS, LIBMUDFLAP_ENABLE): Moved
274 to ../config.
275
276 2005-08-22 Jim Wilson <wilson@specifix.com>
277
278 * mf-hooks2.c (MF_REGISTER_fopen): Define to __MF_TYPE_STATIC when
279 __FreeBSD__ is defined.
280
281 2005-08-17 Jim Wilson <wilson@specifix.com>
282
283 * mf-hooks1.c (malloc, calloc, realloc, free,
284 __mf_wrap_alloca_indirect): Call BEGIN_MALLOC_PROTECT before calling
285 the real routines, and END_MALLOC_PROTECT afterwards.
286 * mf-impl.h (enum __mf_state_enum): Expand comment. Add in_malloc.
287 (BEGIN_PROTECT): Handle in_malloc state.
288 (BEGIN_MALLOC_PROTECT, END_MALLOC_PROTECT): New.
289 * testsuite/libmudflap.c/hook2-allocstuff.c: New.
290
291 2005-08-17 Kelley Cook <kcook@gcc.gnu.org>
292
293 * All files: Update FSF address.
294
295 2005-08-15 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
296
297 * mf-hooks3.c (main_seen_p): Remove.
298 (__mf_get_state): Remove attempt to recognize the main thread.
299
300 2005-08-15 Maciej W. Rozycki <macro@linux-mips.org>
301
302 * configure.ac: Test for the name of the symbol used for the entry
303 point; define ENTRY_POINT to the result.
304 * configure: Regenerate.
305 * config.h.in: Regenerate.
306 * mf-heuristics.c: Replace _start with ENTRY_POINT throughout.
307
308 2005-08-14 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
309
310 * mf-runtime.c (__mf_state_1): Initialize to reentrant.
311 (__mf_init): Set thread state active.
312 * mf-hooks3.c (__mf_pthread_spawner): Always set thread
313 state active.
314 (pthread_create wrapper): Always use thread spawner.
315
316 * testsuite/libmudflap.cth/pass37-frag.c: Increase timeout.
317 * testsuite/libmudflap.cth/pass39-frag.c: Likewise.
318
319 2005-07-16 Richard Henderson <rth@redhat.com>
320
321 * acinclude.m4: New file.
322 * configure.ac: Invoke LIBMUDFLAP_CHECK_TLS.
323 * configure, config.h.in, Makefile.in, testsuite/Makefile.in: Rebuild.
324 * mf-hooks1.c (__mf_0fn_malloc): Move body from ...
325 (__mf_0fn_calloc): ... here.
326 * mf-hooks3.c (struct pthread_info): Remove.
327 (__mf_pthread_info, __mf_pthread_info_idx): Remove.
328 (LIBMUDFLAPTH_THREADS_MAX): Set to 1021.
329 (struct mf_thread_data): New.
330 (mf_thread_data, mf_thread_data_lock): New.
331 (__mf_allocate_blank_threadinfo): Remove.
332 (__mf_find_threadinfo): Rewrite and simplify. Only use if TLS is
333 not available.
334 (__mf_state_perthread): Remove.
335 (__mf_get_state, __mf_set_state): New.
336 (__mf_pthread_cleanup): Use &errno, rather than saved pointer.
337 Update mf_thread_data killing procedure.
338 (__mf_pthread_spawner): Similarly.
339 (__mf_0fn_pthread_create): Only use wrapper if necessary. Remove
340 code to allocate thread stack space.
341 (__mf_0fn_pthread_join, pthread_join): Remove.
342 (__mf_0fn_pthread_exit, pthread_exit): Remove.
343 * mf-impl.h (dyn_pthread_join, dyn_pthread_exit): Remove.
344 (__mf_state_1): Rename from __mf_state; use TLS when available.
345 (__mf_get_state, __mf_set_state): New. Update all users.
346 * mf-runtime.c (begin_recursion_protect1): New.
347 (BEGIN_RECURSION_PROTECT): Use it.
348 (__mf_state_1): Rename from __mf_state; use TLS when available.
349 (threads_active_p): Remove.
350 (__mf_usage): Compute it directly.
351
352 2005-06-19 Ulrich Weigand <uweigand@de.ibm.com>
353
354 * testsuite/libmudflap.c/externs-1.c (main): Add return statement.
355
356 2005-06-15 Frank Ch. Eigler <fche@redhat.com>
357
358 Fix for uncaching bug reported by Herman ten Brugge.
359 * mf-runtime.c (__mf_uncache_object): Search whole cache.
360 * testsuite/libmudflap.c/fail40-frag.c: New test.
361
362 2005-05-23 Alfred M. Szmidt <ams@gnu.org>
363
364 PR libmudflap/21724
365 * Makefile.am (AM_MAKEFLAGS): Pass includedir.
366 * Makefile.in: Amend.
367
368 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
369
370 PR mudflap/21023
371 * testsuite/libmudflap.c/externs.exp, externs-{1,2}.c: New test files.
372 * testsuite/libmudflap.c/cfrags.exp: Bypass new sources.
373
374 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
375
376 PR libmudflap/21094
377 * testsuite/libmudflap.c++/*.exp: Assert build tree g++.
378
379 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
380
381 PR mudflap/22064
382 * mf-impl.h (mudflap_mode, violation_mode): Make these ordinary
383 unsigned vars with #defines instead of enums.
384
385 2005-05-09 Mike Stump <mrs@apple.com>
386
387 * configure: Regenerate.
388
389 2005-04-12 Mike Stump <mrs@apple.com>
390
391 * configure: Regenerate.
392
393 2005-04-12 Frank Ch. Eigler <fche@redhat.com>
394
395 PR mudflap/19266
396 * testsuite/libmudflap.c++/c++frags.exp: Also test -O permutation.
397 * testsuite/libmudflap.c++/pass57-frag.cxx: New test.
398
399 2005-04-04 Alan Modra <amodra@bigpond.net.au>
400
401 * mf-runtime.c (__mfu_unregister): Warning fix for char unsigned.
402
403 2005-03-31 Mike Stump <mrs@apple.com>
404
405 * mf-runtime.h: Add libmudflap copyright clause.
406
407 2005-03-21 Mike Stump <mrs@apple.com>
408
409 * mf-heuristics.c: Fix whitespace at end of line.
410 * mf-hooks1.c: Likewise.
411 * mf-hooks2.c: Likewise.
412 * mf-hooks3.c: Likewise.
413 * mf-impl.h: Likewise.
414 * mf-runtime.c: Likewise.
415 * mf-runtime.h: Likewise.
416
417 2005-03-21 Zack Weinberg <zack@codesourcery.com>
418
419 * configure.ac: Do not invoke TL_AC_GCC_VERSION.
420 In all substitutions, expand gcc_version in Makefile.
421 * aclocal.m4, configure: Regenerate.
422 * Makefile.am: Set gcc_version.
423 * Makefile.in, testsuite/Makefile.in: Regenerate.
424
425 2005-03-17 Frank Ch. Eigler <fche@redhat.com>
426
427 * mf-runtime.c (__mfu_check): Respect ignore_reads configuration.
428 * testsuite/libmudflap.c/{pass56,fail39}-frag.c: New tests.
429
430 2005-02-13 Frank Ch. Eigler <fche@redhat.com>
431
432 PR mudflap/19319
433 * testsuite/libmudflap.c++/pass55-frag.c: New test.
434
435 2005-01-05 Richard Henderson <rth@redhat.com>
436
437 * testsuite/libmudflap.c/pass32-frag.c: Fix typo.
438
439 2005-01-02 Greg McGary <greg@mcgary.org>
440
441 * mf-impl.h (uintptr_t): Get typedef via stdint.h or define explicitly.
442 * mf-runtime.h: New file, replaces mf-runtime.h.in.
443 * configure.ac (AC_CONFIG_FILES): mf-runtime.h is no longer generated.
444 * Makefile.in: Ditto.
445 * testsuite/lib/libmudflap.exp: Add -I${srcdir}/.. to get mf-runtime.h
446 * testsuite/libmudflap.c/pass32-frag.c: s/uintptr_t/__mf_uintptr_t/
447 * testsuite/libmudflap.c/fail36-frag.c: New test.
448 * testsuite/libmudflap.c/fail37-frag.c: New test.
449 * testsuite/libmudflap.c/fail38-frag.c: New test.
450
451 2004-12-08 Kelley Cook <kcook@gcc.gnu.org>
452
453 * Makefile.am: Add ../config to ACLOCAL_AMFLAGS.
454 * aclocal.m4, Makefile.in, testsuite/Makefile.in: Regenerate.
455
456 2004-12-02 Richard Sandiford <rsandifo@redhat.com>
457
458 * configure.ac: Use TL_AC_GCC_VERSION to set gcc_version.
459 * aclocal.m4: Include ../config/gcc-version.m4.
460 * configure, Makefile.in, testsuite/Makefile.in: Regenerate.
461
462 2004-11-29 Kelley Cook <kcook@gcc.gnu.org>
463
464 * Makefile.am: Define ACLOCAL_AMFLAGS.
465 * acinclude.m4: Remove.
466 * stamp-h.in: Remove superfluous stamp file.
467 * aclocal.m4, configure, Makefile.in: Regenerate.
468 * testsuite/Makefile.in: Likewise.
469
470 2004-11-24 Kelley Cook <kcook@gcc.gnu.org>
471
472 * Makefile.am: Revert previous.
473 * acinclude.m4: Restore.
474 * aclocal.m4, configure, Makefile.in: Regenerate.
475 * testsuite/Makefile.in: Likewise.
476
477 2004-11-24 Kelley Cook <kcook@gcc.gnu.org>
478
479 * Makefile.am: Define ACLOCAL_AMFLAGS.
480 * acinclude.m4: Remove.
481 * aclocal.m4, configure, Makefile.in: Regenerate.
482 * testsuite/Makefile.in: Likewise.
483
484 2004-11-23 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
485
486 * testsuite/lib/libmudflap.exp: Use new procs in target-libpath.exp.
487
488 2004-11-23 Kelley Cook <kcook@gcc.gnu.org>
489
490 * Makefile.in, configure, aclocal.m4: Regenerate with automake 1.9.3.
491 * testsuite/Makefile.in: Likewise.
492
493 2004-11-01 Andreas Schwab <schwab@suse.de>
494
495 * configure.ac: (target_alias): Default to $host_alias, not
496 $target.
497 * configure: Regenerated.
498
499 2004-10-28 Frank Ch. Eigler <fche@redhat.com>
500
501 * testsuite/libmudflap.c/fail35-,pass53-,pass54-frag.c: New tests.
502 * testsuite/libmudflap.c/pass35-frag.c: Correct embedded warning
503 message.
504
505 2004-10-25 Eric Botcazou <ebotcazou@libertysurf.fr>
506
507 PR other/18138
508 * testsuite/lib/libmudflap.exp: Accept more than one multilib libgcc.
509
510 2004-10-12 Frank Ch. Eigler <fche@redhat.com>
511
512 * configure.ac: Check for more headers, functions.
513 * mf-hooks2.c (mkbuffer, unmkbuffer): New helper functions for
514 tracking overridden FILE buffers.
515 (fopen, setvbuf): New/revised hook functions for buffer overriding.
516 (setbuf,setlinebuf,fdopen,freopen,fopen64,freopen64,fclose): Ditto.
517 (fflush): Accept given NULL stream (means "all streams").
518 * mf-runtime.h.in:
519 * mf-runtime.c (__mfu_check): Accept accesses that span adjacent
520 HEAP/GUESS objects.
521 (LOOKUP_CACHE_SIZE_MAX): Raise to 64K entries tentatively.
522 (__mf_adapt_cache): Use them all.
523 * testsuite/libmudflap.c/pass35-frag.c: Update warning message.
524 * testsuite/libmudflap.c++/ctors.exp: Ditto.
525 * testsuite/libmudflap.c/{pass51,pass52}-frag.c: New tests.
526 * configure, config.h.in: Regenerated.
527
528 2004-10-05 Frank Ch. Eigler <fche@redhat.com>
529
530 * configure.ac: Checking for sys/socket.h once is enough.
531 * configure: Regenerated.
532
533 2004-10-04 Frank Ch. Eigler <fche@redhat.com>
534
535 * configure.ac: Look for more headers & functions.
536 * mf-hooks2.c (getmntent, inet_ntoa, getproto*): New wrapper functions.
537 * mf-runtime.h.in: Add new "#pragma redefine_extname"s for them.
538 * mf-runtime.c (options): Clean up integer signedness warnings.
539 (main): Add a declaration to fix a warning.
540 * mf-hooks3.c (pthread_exit): Add not-reached exit() to wrapper.
541 * configure, config.h.in: Regenerated.
542
543 2004-10-02 Frank Ch. Eigler <fche@redhat.com>
544
545 * testsuite/libmudflap.c/pass50-frag.c, fail33-frag.c, fail34-frag.c:
546 New tests for proper base/limit checking for aggregates.
547
548 2004-09-15 Joseph S. Myers <jsm@polyomino.org.uk>
549
550 * testsuite/libmudflap.c/pass35-frag.c: Update expected message.
551
552 2004-09-07 Frank Ch. Eigler <fche@redhat.com>
553
554 * configure.ac: Look for pwd.h, grp.h, netdb.h headers and functions.
555 * mf-hooks2.c (strerror): Unregister previous string returned by
556 previous strerror.
557 (getlogin,cuserid,getpwnam,getpwuid,getgrnam,getgrgid): New wrappers.
558 (getservent,getservbyname,getservbyport,gai_strerror): Ditto.
559 * mf-runtime.h.in: Add redefine_extname pragmas for them all.
560 * mf-runtime.c (__mf_describe_object): Clarify object life status.
561 * testsuite/libmudflap.c/pass48-frag.c, pass49-frag.c, fail32-frag.c:
562 New tests.
563 * configure, config.h.in: Regenerated.
564
565 2004-08-03 Dale Johannesen <dalej@apple.com>
566
567 * mf-runtime.c: Conditionalize POSIX_SOURCE for Darwin.
568
569 2004-08-03 Frank Ch. Eigler <fche@redhat.com>
570
571 * mf-runtime.c (compare_uintptr_t): Remove function. Inline
572 simplified contents in all former callers.
573
574 2004-07-27 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
575
576 * mf-runtime.c (__mf_fini): Set mudflap_mode to mode_nop in
577 the statically linked case.
578
579 2004-07-27 Frank Ch. Eigler <fche@redhat.com>
580
581 * splay-tree.[ch]: Remove. Merge contents into ...
582 * mf-runtime.c: ... here, renaming symbols and making all functions
583 static. Remove unused min/max functions.
584 * Makefile.am: Forget about splay-tree.[ch].
585 * Makefile.in, testsuite/Makefile.in: Regenerated.
586
587 2004-07-21 Frank Ch. Eigler <fche@redhat.com>
588
589 * mf-runtime.c (__mfu_check): Remove mistaken mode-nop handling.
590 (__mfu_usage): Include (C) 2004.
591 * mf-hooks3.c (__mf_find_threadinfo): Don't call tracing functions
592 here. Include a comment explaining why.
593
594 2004-07-20 Frank Ch. Eigler <fche@redhat.com>
595
596 * mf-impl.h (__mf_options): Add ignore_reads and timestamps fields.
597 * mf-runtime.c (options): Give them a name.
598 (__mf_set_default_options): Set them.
599 (__mf_insert_new_object, __mfu_unregister): Optionalize timestamps.
600 (__mf_violation): Warning cleanup.
601 * mf-impl.h (MF_VALIDATE_EXTENT): Support ignore_reads option.
602 * splay-tree.c (splay_tree_delete_helper): Remove obsolete decl.
603
604 2004-07-15 Frank Ch. Eigler <fche@redhat.com>
605
606 g++/15861
607 * mf-runtime.c (__mf_init): Make it non-static. Tolerate
608 repeated invocation.
609
610 2004-07-09 Frank Ch. Eigler <fche@redhat.com>
611
612 Test case for g++/15861
613 * testsuite/libmudflap.c++/ctors-[12].cxx: New test case halves.
614 * testsuite/libmudflap.c++/ctors.exp: Driver.
615 * testsuite/libmudflap.c++/c++frags.exp: Elide redundant default.
616 Look only for *frag* test cases.
617
618 2004-07-08 Frank Ch. Eigler <fche@redhat.com>
619
620 ANSI C conversion, libmudflap specialization, recursion limiting.
621 * splay-tree.h (splay_tree_{de,}allocate_fn): Remove allocation_data
622 argument and indirection function pointers, update callers.
623 (splay_tree_s): Add statistics and recursion control fields
624 num_keys, max_depth, depth, rebalance_p.
625 * splay-tree.c (splay_tree_splay_helper): Track recursion depth.
626 Back out of search if it exceeds limit.
627 (splay_tree_splay): Manage recursion limiting with rebalancing as
628 needed.
629 (splay_tree_new): More initialization.
630 (splay_tree_rebalance): New function.
631 (splay_tree_foreach): Rewrite using nonrecursive logic.
632 (splay_tree_xmalloc_allocate, splay_tree_xmalloc_deallocate):
633 Remove. Point indirect calls to mf-runtime.c's routines.
634 (splay_tree_compare_ints, splay_tree_compare_pointers): Remove unused
635 functions.
636 (splay_tree_delete, splay_tree_delete_helper): Ditto.
637 * testsuite/heap-scalestress.c: New test based on one from
638 Eyal Lebedinsky <eyal@eyal.emu.id.au>:
639
640 2004-07-05 Matthias Klose <doko@debian.org>
641
642 * libtool-version: New.
643 * Makefile.am (libmudflap_la_LDFLAGS, libmudflapth_la_LDFLAGS):
644 Use -version-info for soname.
645 * Makefile.in: Regenerate.
646 * configure.ac: Remove libtool_VERSION macro
647 * configure: Regenerate
648
649 2004-07-05 Zack Weinberg <zack@codesourcery.com>
650
651 * mf-runtime.h.in: Wrap declarations of struct __mf_cache,
652 __mf_lookup_cache, __mf_lc_mask, or __mf_lc_shift in
653 #ifndef _MUDFLAP.
654
655 2004-06-29 Frank Ch. Eigler <fche@redhat.com>
656
657 Splay tree implementation fork.
658 * splay-tree.c, splay-tree.h: Copied & modified from libiberty.
659 Use hard-coded comparison function for uintptr_t. Remove key/value
660 deallocation logic. Cache last splayed key for consecutive lookups.
661 * Makefile.am, Makefile.in: Use them, don't link to them.
662 * mf-runtime.c (__mf_object_tree): Adapt to simpler splay_tree_new.
663 (__mf_find_objects2): Flip successor/predecessor search sequence.
664 * ansidecl.h, libiberty.h: Removed dummy files.
665
666 2004-06-29 Nick Clifton <nickc@redhat.com>
667
668 * configure.ac (AC_CHECK_HEADERS): Add dirent.h
669 * configure: Regenerate.
670 * mf-hooks2.c: Surround uses of dirent.h with #ifdef
671 HAVE_DIRENT_H.
672 Remove spurious inclusion of <strings.h>.
673
674 2004-06-29 Nick Clifton <nickc@redhat.com>
675
676 * mf-runtime.c (pthread_join): Only apply the weak pragma if the
677 function actually exists.
678
679 2004-06-25 Frank Ch. Eigler <fche@redhat.com>
680
681 * ansidecl.h, libiberty.h: New dummy files for building splay-tree.
682 * config.h.in: Regenerated.
683
684 2004-06-24 Frank Ch. Eigler <fche@redhat.com>
685
686 Adopt splay trees for object database.
687 * Makefile.am: Copy splay-tree.* from libiberty.
688 * Makefile.in, testsuite/Makefile.in: Regenerated.
689 * mf-runtime.h.in (__mf_unregister): Add third parameter (type).
690 * mf-hooks[123].c (*): Add new third parameter to mf_unregister.
691 * mf-impl.h (BEGIN_PROTECT): Remove some trace text.
692 * mf-runtime.c: Rewrite code dealing with object database to use
693 libiberty splay trees. Remove tree liveness aging option.
694 * testsuite/libmudflap.c/fail18-frag.c: Add volatile flag.
695
696 2004-06-15 Paolo Bonzini <bonzini@gnu.org>
697
698 * configure.ac: New name of configure.in. Update
699 AC_INIT, AC_CONFIG_SRCDIR, AC_CONFIG_HEADERS, AC_CONFIG_FILES,
700 AC_OUTPUT, AM_INIT_AUTOMAKE to the preferred style for
701 Autoconf 2.5x and Automake 1.7 or later.
702 * configure.in: Remove.
703 * configure: Regenerate.
704
705 * Makefile.am: Remove useless multilib rules.
706 * Makefile.in: Regenerate.
707
708 2004-06-15 Paolo Bonzini <bonzini@gnu.org>
709
710 * .cvsignore: New file.
711
712 2004-06-10 Stephen Crowley <stephen.crowley@sbcglobal.net>
713
714 PR libmudflap/13505
715 * mf-hooks2.c (semctl): Add cygwin porting hack.
716
717 2004-06-09 Frank Ch. Eigler <fche@redhat.com>
718
719 ctype support.
720 * configure.in: Look for ctype header and glibc implementation.
721 * mf-hooks2.c (__ctype_{b,toupper,tolower}_loc): Sample ctype
722 array hooks for glibc 2.3.
723 * mf-runtime.h.in: Wrap them.
724 * mf-runtime.c (__mf_init): Leave marker regarding other ctype
725 implementations.
726 * testsuite/libmudflap.c/pass47-frag.c: New test.
727 * configure, config.h.in: Regenerated.
728
729 2004-06-04 Frank Ch. Eigler <fche@redhat.com>
730
731 Portability improvements, e.g., libmudflap/15293.
732 * configure.in: Look for glibc extension functions. Look for
733 support of -f{function,data}-sections. Look for more headers.
734 Create testsuite/mfconfig.exp. Correct more "test x.." thinkos.
735 * Makefile.am: Use $(SECTION_FLAGS). Collapse piecemeal-compiled
736 mf-hooks* into usual single object per source.
737 * mf-hooks*.c: Remove all #if WRAP_foo conditionals.
738 * mf-hooks2.c: #include a bunch more system headers. Define strnlen
739 if system doesn't provide one.
740 * mf-hooks3.c (struct pthread_info): Add stack_*_alloc fields.
741 (pthread_create): Use it to properly GC dead thread stacks.
742 * mf-runtime.c (__mf_violation): Correct snprintf type warning.
743 * testsuite/Makefile.am: Stop generating site.exp.
744 * testsuite/mfconfig.exp.in: New file.
745 * testsuite/config/default.exp: Load new mfconfig.exp.
746 * testsuite/lib/libmudflap.exp (libmudflap-init): Add extra libraries.
747 (prune_gcc_output): Add glibc static linking warnings.
748 * testsuite/libmudflap.*/*frags.exp: Enumerate needed -lmudflap* libs.
749 * testsuite/libmudflap.c/pass46-frag.c: Ditto.
750 * configure, Makefile, aclocal.m4, config.h.in, testsuite/Makefile.in:
751 Regenerated with autoconf 2.57 and automake 1.7.
752
753 2004-06-04 Per Bothner <per@bothner.com>
754
755 * configure.in (LIBMUDFLAPTH): Fix thinko.
756
757 * configure.in: Check for more headers.
758 * mf-hooks2.c: Conditionalize on HAVE_SYS_SOCKET_H etc.
759
760 * mf-runtime.c: In two places conditionalize on SIUSR1 rather than
761 HAVE_SIGNAL as mingw has signal.h but not SIUSR1.
762
763 2004-06-01 Andreas Jaeger <aj@suse.de>
764
765 * configure.in: Handle multilibs, support
766 --enable-version-specific-runtime-libs.
767 * Makefile.am (lib_LTLIBRARIES): Rename to ...
768 (toolexeclib_LTLIBRARIES): this for multilib support.
769 * Makefile.in: Regenerated.
770 * configure: Regenerated.
771 * aclocal.m4: Regenerated.
772 * config.h.in: Regenerated.
773 * testsuite/Makefile.in: Regenerated.
774
775 2004-06-01 Andreas Jaeger <aj@suse.de>
776
777 * testsuite/lib/libmudflap.exp (libmudflap-init): Handle
778 multilibs, using multilib directory instead of hardcoded path.
779 Set LD_RUN_PATH.
780
781 2004-05-21 Frank Ch. Eigler <fche@redhat.com>
782
783 * Makefile.am (AM_MAKEFLAGS): Pass RUNTESTFLAGS.
784 * Makefile.in: Ditto.
785
786 2004-05-18 Kaz Kojima <kkojima@gcc.gnu.org>
787
788 * acinclude.m4 (lt_cv_deplibs_check_method): Use pass_all on sh*.
789 * aclocal.m4, configure: Rebuilt.
790
791 2004-05-17 Frank Ch. Eigler <fche@redhat.com>
792
793 * lib/libmudflap.exp (libmudflap-init): For C++ test cases only,
794 import some build settings from libstdc++-v3 testsuite_flags.
795 * .../cfrags.exp, .../c++frags.exp, .../cthfrags.exp: Corresponding
796 changes to pass test language.
797
798 * mf-runtime.c (__mfu_check): Poison the cache with antidote for
799 quicker mode-nop handling.
800
801 2004-03-25 Frank Ch. Eigler <fche@redhat.com>
802
803 * mf-impl.h: Added libgcc license header.
804
805 2004-03-20 Frank Ch. Eigler <fche@redhat.com>
806
807 * mf-hooks[123].c, mf-runtime.c, mf-heuristics.c:
808 Added libgcc license header.
809 * mf-hooks3.c (__mf_0fn_pthread_create): Correct arg constness.
810 (pthread_create): Simplify stack allocation syntax.
811
812 2004-03-08 Loren J. Rittle <ljrittle@acm.org>
813
814 * mf-hooks2.c: Support FreeBSD.
815 (WRAP_gets): Avoid gets().
816 * testsuite/libmudflap.c/pass-stratcliff.c: Do not
817 test unimplemented mem/str calls on FreeBSD.
818 * testsuite/libmudflap.c/pass21-frag.c: Do not include
819 <alloca.h> on FreeBSD.
820
821 2004-01-30 Frank Ch. Eigler <fche@redhat.com>
822
823 * testsuite/libmudflap.c/pass36-frag.c: Add missing free() call.
824 * testsuite/libmudflap.c/pass46-frag.c: New test for -fmudflapir.
825 * testsuite/libmudflap.cth/cthfrags.exp: Add -DSTATIC to compiler
826 flags for static linking permutation.
827 * testsuite/libmudflap.cth/pass40-frag.c: When -DSTATIC, avoid
828 some pthreads code that croaks on linux glibc tls.
829
830 2004-01-27 Frank Ch. Eigler <fche@redhat.com>
831
832 * testsuite/libmudflap.c/fail31-frag.c, pass45-frag.c: New tests.
833
834 2004-01-15 Frank Ch. Eigler <fche@redhat.com>
835
836 * testsuite/libmudflap.c/pass44-frag.c: New test.
837
838 2004-01-12 Frank Ch. Eigler <fche@redhat.com>
839
840 * testsuite/libmudflap.c/fail{28,29,30}-frag.c: New tests.
841
842 2004-01-08 Frank Ch. Eigler <fche@redhat.com>
843
844 * testsuite/libmudflap.c/pass43-frag.c: Added missing program rc.
845
846 2003-12-11 Frank Ch. Eigler <fche@redhat.com>
847
848 * testsuite/libmudflap.c/pass42-frag.c, pass43-frag.c: New tests.
849
850 2003-12-08 Andrew Pinski <pinskia@physics.uc.edu>
851
852 PR libmudflap/12670
853 * configure.in: Add check for see if
854 socklen_t typedef is in sys/socket.h.
855 * mf-hooks1.c: Add define if socklen_t
856 is not typedef.
857 * mf-hooks2.c: Likewise.
858 * mf-hooks3.c: Likewise.
859 * config.h.in: Regen.
860 * configure: Regen.
861
862 2003-12-08 Frank Ch. Eigler <fche@redhat.com>
863
864 * mf-runtime.c (__mf_watch_or_not): Tweak tracing message.
865 * testsuite/libmudflap.c/fail21-frag.c: Defeat aliasing
866 optimizations.
867 * testsuite/libmudflap.c/pass25-frag.c: Ditto.
868 * testsuite/libmudflap.c/pass26-frag.c: Tolerate non-overlapping
869 (unoptimized) allocation of stack space.
870
871 2003-12-07 Richard Henderson <rth@redhat.com>
872
873 * testsuite/libmudflap.c/fail23-frag.c (main): Adjust addend to 11.
874 * testsuite/libmudflap.c/fail27-frag.c (foo): Mark noinline.
875
876 2003-12-06 Andrew Pinski <apinski@apple.com>
877
878 partial PR libmudflap/12670
879 * mf-hooks1.c: Respect Darwin checks. Conditionalize POSIX_SOURCE.
880 * mf-hooks2.c: Likewise.
881 * mf-hooks3.c: Likewise.
882
883 2003-11-19 Frank Ch. Eigler <fche@redhat.com>
884
885 libstdc++/11696
886 * mf-runtime.h.in: Switch to #pragma redefine_extname for
887 symbols interposed at compile time.
888 * testsuite/libmudflap.c++/pass41-frag.cxx: New test.
889
890 libmudflap/12939
891 * mf-hooks2.c (semctl): Tolerate FreeBSD.
892
893 * configure.in: Reorganize check for <pthread.h>.
894 * configure: Regenerated.
895
896 2003-11-04 David Edelsohn <edelsohn@gnu.org>
897
898 * mf-runtime.c (_ALL_SOURCE): Define for AIX.
899 (_LARGE_FILE_API): Define for AIX.
900 * mf-hooks[123]: Same.
901 (_XOPEN_SOURCE_EXTENDED): Define to 1 for AIX.
902
903 2003-10-21 David Edelsohn <edelsohn@gnu.org>
904
905 * mf-runtime.c (_XOPEN_SOURCE_EXTENDED): Define to 1 for AIX.
906
907 2003-07-29 Frank Ch. Eigler <fche@redhat.com>
908
909 2003-07-29 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
910
911 * configure.in: Update check for union semun.
912
913 2003-07-29 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
914
915 PR other/11673
916 * mf-hooks2.c [WRAP_semctl]: Fix check for HAVE_UNION_SEMUN.
917
918 2003-07-29 Frank Ch. Eigler <fche@redhat.com>
919
920 PR other/11673
921 * configure.in: Add checks for 64-bit LFS functions, struct semun
922 definition, for BSD compatibility.
923 * mf-hooks1.c: Respect BSD checks. Conditionalize POSIX_SOURCE.
924 * mf-hooks2.c: Ditto. Include <strings.h> for bcmp* decls.
925 * mf-hooks3.c: Ditto.
926 (pthread_create): Try MAP_ANON on platforms without the MAP_ANONYMOUS
927 mmap flag.
928 * configure, config.h.in: Regenerated.
929
930 2003-07-23 Frank Ch. Eigler <fche@redhat.com>
931
932 Multithreading fixes:
933 * mf-runtime.c (__mf_object): Store allocating/deallocating
934 thread id.
935 (options): Support new "-thread-stack" option.
936 Rename "-heur-argv-environ" option to "-heur-stdlib".
937 Disable "-lc-mask" and "-lc-shift" options.
938 (__mf_dynamic): Add function pointers for pthread_join/_exit.
939 (__assert_fail): New self-contained function for glibc.
940 * mf-hooks3.c: Essentially rewritten, particularly related to
941 use of __mf_pthread_info array.
942 (pthread_join, _exit): New hook functions.
943 * mf-impl.h (BEGIN_PROTECT): Handle starting_p case.
944 * testsuite/libmudflap.cth/pass40-frag.c: New test.
945
946 Warning cleanups:
947 * mf-heuristics.c: Add type casts for tracing, sub calls.
948 * mf-impl.h (BEGIN_PROTECT): Redefine to omit result type.
949 Update all callers to declare explicit result holder.
950 (END_PROTECT): Removed.
951 * testsuite/*/*frags.exp: Clean up default MUDFLAP_OPTIONS.
952
953 2003-07-15 Diego Novillo <dnovillo@redhat.com>
954
955 * testsuite/libmudflap.c/fail21-frag.c: Add volatile modifiers.
956 * testsuite/libmudflap.c/fail15-frag.c: Likewise.
957 * testsuite/libmudflap.c/fail13-frag.c: Likewise.
958
959 2003-07-04 Frank Ch. Eigler <fche@redhat.com>
960
961 * mf-hooks1.c, 2.c, 3.c: New file, splits up content from old ...
962 * mf-hooks: Removed.
963 * mf-impl.h (MF_VALIDATE_EXTENT, BEGIN_PROTECT, END_PROTECT):
964 Move these macros from old mf-hooks.c here.
965 * Makefile.am: Adapt to split-up hook sources for faster builds.
966 * Makefile.in: Regenerated.
967
968 * mf-heuristics.c: Remove #if-0 block.
969
970 * mf-impl.h (__mf_state): Reorganize declaration and implementation.
971 (__mf_starting_p): New state only for use while dlsym bootstrapping.
972 (CALL_REAL, __mf_init): Corresponding changes.
973 (TRACE, VERBOSE_TRACE): Include thread id and "mf:" prefix. Update
974 all callers to remove redundant "mf:" prefix.
975 * mf-runtime.h.in: #define a few reentrancy macros for libmudflapth.
976 * mf-hooks3.c: Rewrite chunks to support per-thread __mf_state value.
977 (__mf_pthread_info): Become a hash table.
978
979 * testsuite/lib/mfdg.exp: Support new "dg-timeout" and
980 "dg-repetitions" directives to control test case execution.
981 * testsuite/libmudflap.cth/pass37-frag.c: Add timeout and repeat
982 options.
983 * testsuite/libmudflap.cth/pass39-frag.c: Ditto for this new test.
984
985 2003-06-25 Frank Ch. Eigler <fche@redhat.com>
986
987 * mf-hooks.c (alloca): Separate into stub.
988 (__mf_wrap_alloca_indirect): New function. Use CALL_REAL
989 malloc/free for alloca blocks.
990 (pthread_create): Tolerate failing pthread_attr_get* calls.
991 * mf-runtime.c (__mf_fini): Call __mf_wrap_alloca_indirect.
992 * mf-impl.h (CALL_WRAP): Remove macro.
993 * testsuite/libmudflap.c/pass21-frag.c: Include <alloca.h>.
994 * testsuite/libmudflap.c/pass23-frag.c: Include more struct
995 padding for ia64 BIT_FIELD_REF constructs.
996
997 2003-06-19 Frank Ch. Eigler <fche@redhat.com>
998
999 * mf-hooks.c (struct pthread_info): Add "thread_errno" field.
1000 (__mf_pthread_spawner, __mf_pthread_cleanup): Use it with GUESS
1001 libmudflap object type.
1002 * mf-runtime.c (__mfu_unregister): Correct cemetary logic to avoid
1003 crashes on unregistering STATIC objects.
1004
1005 2003-06-17 Frank Ch. Eigler <fche@redhat.com>
1006
1007 Based on patch from Eyal Lebedinsky <eyal@eyal.emu.id.au>:
1008 * mf-hooks.c (__mf_pthread_spawner): Register thread errno.
1009 (time, strerror, fopen, fopen64, fclose, fread): New hooks.
1010 (fwrite, fgetc, fgets, getc, gets, ungetc, fputc): New hooks.
1011 (fputs, putc, puts, clearerr, feof, ferror, fileno): New hooks.
1012 (printf, fprintf, sprintf, snprintf, vprintf, vfprintf): New hooks.
1013 (vsprintf, vsnprintf, access, remove, fflush, fseek): New hooks.
1014 (fseeko64, ftell, ftello64, rewind, fgetpos, fsetpos): New hooks.
1015 (stat, stat64, fstat, lstat, mkfifo, setvbuf, setbuf): New hooks.
1016 (setvbuf, opendir, closedir, readdir, recv, recvfrom): New hooks.
1017 (recvmsg, send, sendto, sendmsg, setsockopt, getsockopt): New hooks.
1018 (accept, bind, connect, gethostname, sethostname): New hooks.
1019 (gethostbyname, wait, waitpid, popen, pclose, execve): New hooks.
1020 (execv, execvp, system, dlopen, dlclose, dlerror, dlsym): New hooks.
1021 (semop, semctl, shmctl, shmat, shmdt): New hooks.
1022 * mf-runtime.h.in: Corresponding changes.
1023 * mf-runtime.c (__mf_ini): Register stdio objects. Use STATIC type.
1024 (opts) Rename heur_argv_environ to heur_std_data.
1025 (__mf_wrap_main): Use STATIC type for argv/environ strings.
1026 * Makefile.am: Corresponding changes.
1027 * Makefile.in: Regenerated.
1028
1029 2003-06-11 Frank Ch. Eigler <fche@redhat.com>
1030
1031 * mf-heuristics.c (__mf_heuristic_check): Disable stack_bounds
1032 heuristic for threaded case, and for non-x86-linux targets.
1033 * mf-hooks.c (__mf_0fn_calloc): Provide a working dummy implementation
1034 for use during pre-main() program startup.
1035 (__mf_0fn_*): Make these functions non-static.
1036 * mf-impl.h (DECLARE, CALL_REAL): Support calls to 0fn backup hook
1037 functions.
1038 * mf-runtime.c (__mf_state): Set initial state to "starting".
1039 (__mf_resolve_single_dynamic): Tolerate repeated calls for same symbol.
1040 (__wrap_main): New function to register argv[] and environ[] strings.
1041 (__mf_ini): Call it.
1042 (*): In all trace functions, use "%p" as formatter for uintptr_t.
1043
1044 * testsuite/libmudflap.c/pass38-frag.c: New test case.
1045 * testsuite/libmudflap.cth/pass37-frag.c: Improved test.
1046
1047 * acinclude.m4: Add comments with aoliva's concerns about x86_64
1048 pass_all.
1049 * aclocal.m4, configure: Regenerated.
1050
1051 2003-06-04 Frank Ch. Eigler <fche@redhat.com>
1052
1053 * acinclude.m4: Correct typo in AC_MSG_CHECKING.
1054 * aclocal.m4, configure: Regenerated.
1055
1056 2003-06-03 Frank Ch. Eigler <fche@redhat.com>
1057
1058 * acinclude.m4: Force "pass_all" deplibs_check_method for libtool
1059 for x86_64 target. Disable caching for this value.
1060 * aclocal.m4, configure: Regenerated.
1061
1062 2003-06-02 Frank Ch. Eigler <fche@redhat.com>
1063
1064 * testsuite/libmudflap.c/pass38-frag.c: Deleted. -fwritable-strings
1065 is about to become deprecated, and its present handling bugs are
1066 unworthy of fixing.
1067
1068 2003-05-30 Frank Ch. Eigler <fche@redhat.com>
1069
1070 * testsuite/libmudflap.c/pass38-frag.c: New test for
1071 -fwritable-strings.
1072
1073 2003-05-23 Frank Ch. Eigler <fche@redhat.com>
1074
1075 * mf-runtime.c (__mf_sigusr1_handle): Call unlocked variant of
1076 __mf_report, asserting reentrant calling context.
1077
1078 2003-05-23 Frank Ch. Eigler <fche@redhat.com>
1079
1080 * mf-hooks.c (realloc): Correct reentrancy logic.
1081 * testsuite/libmudflap.c/hook-allocstuff.c: New test case.
1082
1083 2003-05-20 Frank Ch. Eigler <fche@redhat.com>
1084
1085 * mf-hooks.c (LIBMUDFLAPTH_THREADS_MAX): New macro, replaces
1086 PTHREAD_THREADS_MAX. Update users.
1087 * mf-runtime.c (__mf_usage): Print [active] instead of [default]
1088 for active options.
1089 * testsuite/Makefile.am (all-local): Prime dejagnu site.exp file
1090 with libmudflapth presence indicator.
1091 * testsuite/Makefile.in: Regenerated.
1092
1093 2003-05-16 Frank Ch. Eigler <fche@redhat.com>
1094
1095 * Makefile.am (AM_CFLAGS): Remove "-ansi".
1096 * configure.in: Remove silly no-pthreads => no-shared logic.
1097 * Makefile.in, configure: Regenerated.
1098 * mf-heuristics.c (__mf_heuristic_check): Remove reentrancy hacks.
1099 * mf-hooks.c (BEGIN_PROTECT, END_PROTECT): Reorganize reentrancy
1100 code. Count reentrancy events.
1101 (all hook functions): Don't directly manipulate __mf_state variable.
1102 Add TRACE calls to hook functions without them.
1103 * mf-impl.h (LOCKTH): Try to count lock contention events.
1104 (VERBOSE_TRACE, TRACE): Remove reentrancy hacks.
1105 * mf-runtime.c (BEGIN_RECURSION_PROTECT, END_RECURSION_PROTECT):
1106 Reorganize reentrancy code.
1107 (external __mf_ entry points): Use RECURSION_PROTECT mechanism to
1108 identify reentrancy with mutex holding times.
1109 (internal __mfu_ entry points): Remove internal reentrancy code.
1110 (__mf_init): Use ordinary locked calls.
1111 (__mfu_report): Print the two new counts.
1112 * testsuite/lib/libmudflap.exp: Filter out junk ld/pthreads messages.
1113 * testsuite/libmudfap.cth/cthfrags.exp: New test driver.
1114 * testsuite/libmudflap.cth/pass37-frag.c: New pthreads test.
1115 * testsuite/libmudfap.cth/cfrags.exp: Adapt to new libmudflap
1116 option defaults.
1117
1118 2003-05-09 Frank Ch. Eigler <fche@redhat.com>
1119
1120 * configure.in: Add pthread support, plus glibc and porting hacks.
1121 * Makefile.am (LIBMUDFLAPTH): New conditional, to build -lmudflapth
1122 from objects built into ./pth/.
1123 * mf-runtime.c (__mfu_watch,register,...): Fork new unlocked
1124 functions for internal entry points. Update callers to pick
1125 locked vs. unlocked variants.
1126 (__mf_resolve_single_dynamic): Extend to support symbol versioning
1127 info coming in from a static data structure.
1128 (*): Reorder miscellaneous declarations to group data vs functions.
1129 (__mf_set_default_options): Simplify.
1130 (__mf_usage): Mention threading status of host executable.
1131 * mf-impl.h: Move max/min decls here. Reorganize __mf_dynamic
1132 decls to match above.
1133 (LOCKTH, UNLOCKTH): New macros for Big Libmudflap Lock management.
1134 * mf-heuristics.c: Choose between locked/unlocked calls. Add
1135 some lock/unlock markers. Remove some unused code.
1136 * mf-hooks: Ditto.
1137 (pthread_create): New hook function.
1138 (__mf_pthread_cleanup, _spawner): New helper functions.
1139 * configure. aclocal.m4, config.h.in, Makefile.in: Regenerated.
1140
1141 2003-05-02 Frank Ch. Eigler <fche@redhat.com>
1142
1143 * testsuite/libmudflap.c/fail27-frag.c: Add more volatile flags.
1144
1145 2002-04-28 Frank Ch. Eigler <fche@redhat.com>
1146
1147 * Makefile.am (HOOKOBJS): Add *time related hooks.
1148 * configure.in: Look for pthreads.h header.
1149 * mf-hooks.c (asctime, ctime, gmtime, localtime): New wrappers.
1150 * mf-runtime.c: Begin sketching some pthreads support.
1151 (__mf_usage): Check for -lpthread presence.
1152 (__mf_unregister): Confirm matching unregistration base.
1153 (__mf_find_objects_rec): Reduce unnecessary recursion.
1154 * mf-runtime.h.in: Add "nothrow" attribute to functions. Add
1155 #defines for new hook functions.
1156 * mf-impl.h: Corresponding changes.
1157 * config.h.in, configure, Makefile.in: Regenerated.
1158
1159 2002-04-27 Diego Novillo <dnovillo@redhat.com>
1160
1161 * testsuite/libmudflap.c/fail1-frag.c: Add volatile
1162 modifiers to prevent being optimized away.
1163 * testsuite/libmudflap.c/fail10-frag.c: Likewise.
1164 * testsuite/libmudflap.c/fail13-frag.c: Likewise.
1165 * testsuite/libmudflap.c/fail14-frag.c: Likewise.
1166 * testsuite/libmudflap.c/fail15-frag.c: Likewise.
1167 * testsuite/libmudflap.c/fail2-frag.c: Likewise.
1168 * testsuite/libmudflap.c/fail20-frag.c: Likewise.
1169 * testsuite/libmudflap.c/fail3-frag.c: Likewise.
1170
1171 2003-04-15 Frank Ch. Eigler <fche@redhat.com>
1172
1173 * Makefile.am (libmudflap_la_LIBADD): Remove -ldl.
1174 * configure.in: Look for uintptr_t and -ldl on target.
1175 * mf-runtime.h.in: Adjust uintptr_t declaration logic.
1176 * Makefile.in, aclocal.m4, configure, config.h.in: Regenerated.
1177 * testsuite/Makefile.in: Regenerated.
1178 * mf-runtime.c (__mf_sigusr1_respond): Tweak declaration and calls
1179 for better C compliance.
1180
1181 2003-04-15 Frank Ch. Eigler <fche@redhat.com>
1182
1183 * mf-hooks.c (MF_VALIDATE_EXTENT): Remove unnecessary reentrancy
1184 prevention code.
1185 * mf-runtime.c (__mf_set_default_options): Turn off
1186 check-initialization.
1187 (__mf_describe_object): Shorten description.
1188 * testsuite/libmudflap.c/fail25-frag.c: Turn on check-initialization.
1189
1190 2003-04-07 Frank Ch. Eigler <fche@redhat.com>
1191
1192 * mf-hooks.c (__mf_0fn_mmap): Correct return value, as per <rth>.
1193
1194 2003-04-02 Frank Ch. Eigler <fche@redhat.com>
1195
1196 * mf-hooks.c (BEGIN_PROTECT): Handle startup-time reentrant
1197 calls specially.
1198 (__mf_0fn_malloc ... _munmap): New dummy backup calls.
1199 * mf-impl.h (CALL_BACKUP): New macros.
1200 * mf-runtime.c (__mf_init): Tweak __mf_state during startup.
1201
1202 2003-03-31 Frank Ch. Eigler <fche@redhat.com>
1203
1204 * Makefile.am (AM_CFLAGS): Remove optimization flags.
1205 (HOOKOBJS): Remove dlopen hook.
1206 (libmudflap_la_LIBADD): Add -ldl.
1207 * mf-hooks.c (dlopen): Remove hook.
1208 * mf-impl.h (__mf_dynamic): Ditto.
1209 * mf-runtime.c (__mf_resolve_dynamics): Ditto.
1210 * Makefile.in: Regenerated.
1211
1212 2003-03-28 Frank Ch. Eigler <fche@redhat.com>
1213
1214 * configure.in: Check for target gettimeofday, signal, some headers.
1215 * mf-impl.h (__mf_opts): Add new "sigusr1_report" field. Comment
1216 out inop multi_threaded field.
1217 * mf-runtime.c (options): Handle new "-sigusr1-report" option.
1218 (__mf_set_options): Correct handling of "-help".
1219 (__mf_sigusr1_respond): New function to manage SIGUSR1 response.
1220 (__mf_check, __mf_register, __mf_unregister): Call it.
1221 (__mf_insert_new_object, __mf_unregister): Respect HAVE_GETTIMEOFDAY.
1222 (__mf_report_leaks): Make callable
1223 (__mf_tree_analyze): Traverse in-order. Accumulate address bit
1224 distribution statistics.
1225 (__mf_adapt_cache): Rewrite shift guessing logic based on address
1226 bit distributions.
1227 * config.h.in, configure: Regenerated.
1228 * testsuite/libmudflap.c/fail27-frag.c: New test.
1229 * testsuite/libmudflap.c/pass36-frag.c: New test.
1230
1231 2003-03-11 Frank Ch. Eigler <fche@redhat.com>
1232
1233 * mf-runtime.h.in: Tweak.
1234 * Makefile.am, configure.in: Tweak mf-runtime.h generation some more.
1235 Don't use intermediate files nor AC_OUTPUT-time postprocessing.
1236 * Makefile.in, testsuite/Makefile.in, configure: Regenerated.
1237
1238 2003-03-10 Frank Ch. Eigler <fche@redhat.com>
1239
1240 * configure.in: Tweak generation of mf-runtime.h some more. It
1241 needs to work from both config.status and configure.
1242 * configure: Regenerated.
1243
1244 2003-03-10 Frank Ch. Eigler <fche@redhat.com>
1245
1246 * Makefile.am: Reorganize hook file building. Add auto dependencies.
1247 * configure.in: Tweak generation of mf-runtime.h.
1248 * mf-runtime.h.in: Add new __MF_TYPE_HEAP_I.
1249 * mf-hooks.c (*): Adapt to initialized-heap object type.
1250 * mf-impl.h: Tweak cemetary boundaries.
1251 * mf-runtime.c (__mf_check): Adapt to new initialized-heap object
1252 type.
1253 (__mf_insert_new_object, __mf_register, __mf_unregister): Ditto.
1254 (__mf_describe_object, __mf_report_leaks, __mf_violation): Ditto.
1255 * testsuite/lib/libmudflap.exp (includes): Include build tree.
1256 * testsuite/libmudflap.c/pass{26,5}: Further adapt to initialization
1257 checking.
1258 * testsuite/.../fail{25,26}-frag.c: New tests.
1259 * testsuite/.../pass{32,33,34,35}-frag.c: New tests.
1260 * Makefile.in, configure: Regenerated.
1261
1262 2003-03-05 Frank Ch. Eigler <fche@redhat.com>
1263
1264 * mf-runtime.c (__mf_set_default_options): Turn on initialization
1265 checking by default.
1266 (__mf_insert_new_object): As a temporary hack, assume that new
1267 objects registered on the stack start out initialized.
1268 * testsuite/libmudflap.c/fail9,pass23,pass[6789]-*: Initialize
1269 heap objects by hand.
1270
1271 2003-03-05 Frank Ch. Eigler <fche@redhat.com>
1272
1273 Switch to macro-style hooks for str*/mem*/b* functions.
1274 * mf-runtime.h.in (__MF_TYPE_*): Moved some internal values out.
1275 (mem*, str*, b*): Added macro-style hooks for _MUDFLAP case.
1276 * mf-runtime.c: #include config.h to enable glibc backtraces again.
1277 (__mf_set_default_options): Turn off heur_proc_map.
1278 (*): Adapt to to macro-style hook functions.
1279 (__mf_object_dead_head, __mf_object_cemetary): Correct bounds.
1280 (__mf_check, __mf_register, __mf_unregister): Tweak tracing message.
1281 (__mf_violation): Handle __MF_VIOL_WATCH.
1282 * mf-impl.h (__MF_TYPE_*): Moved these internal values here.
1283 (__mf_dynamic): Removed mem*/str*/b* functions.
1284 (TRACE, VERBOSE_TRACE): Add reentrancy locking.
1285 (WRAPPER2): New macro for macro-style hooks.
1286 * mf-hooks.c: Convert mem*/str*/b* functions to simpler
1287 macro-style hooks.
1288 (BEGIN_PROTECT): Tweak tracing vs reentrancy-lock ordering.
1289 * mf-heuristics.c: Adapt to macro-style hook functions.
1290 Correct some comments.
1291 * testsuite/lib/mfdg.exp (dg-test): Simplify result string for
1292 output pattern tests.
1293 * testsuite/libmudflap.c/fail[89]-frag.c: Elaborate output test.
1294 * testsuite/libmudflap.c++/c++frags.exp: Enable non-static tests.
1295
1296 2003-02-28 Frank Ch. Eigler <fche@redhat.com>
1297
1298 * testsuite/libmudflap.c/fail23-frag.c, pass30-frag.c: New tests
1299 for global array registration.
1300 * testsuite/libmudflap.c++/fail24-frag.cxx, pass31-frag.cxx: Ditto.
1301 * testsuite/libmudflap.c++/c++frags.exp: Tweak -static multilib hack.
1302
1303 2003-02-27 Frank Ch. Eigler <fche@redhat.com>
1304
1305 * Makefile.am: Add gross make bug workarounds. Tweaked
1306 SUBDIRS and AM_CFLAGS.
1307 * Makefile.in: Regenerated.
1308
1309 2003-02-26 Frank Ch. Eigler <fche@redhat.com>
1310
1311 Switch to dejagnu.
1312 * configure.in (AC_PROG_CXX): Don't look for C++ any more.
1313 * Makefile.am (TESTS): Remove simple automake testing.
1314 * configure, Makefile.in: Regenerated.
1315 (SUBDIRS): Include new testsuite/ directory.
1316 * tests/*: Removed all files; moved bulk under:
1317 * testsuite/*: New subdirectory tree.
1318 * testsuite/libmudflap.c/cfrags.exp: New file, C test driver.
1319 * testsuite/libmudflap.c++/c++frags.exp: New file, C++ test driver.
1320 * testsuite/lib/libmudflap.exp: New file, derived from libstdc++.
1321 * testsuite/lib/mfdg.exp: New file, derived from dejagnu.
1322 * testsuite/config/default.exp: New file.
1323 * testsuite/Makefile.am, Makefile.in: New files.
1324
1325 2003-01-29 Frank Ch. Eigler <fche@redhat.com>
1326
1327 * Makefile.am (TESTS_ENVIRONMENT): Remove redundant "-mode-check".
1328 (TESTS): Add fail22 and pass29 tests.
1329 * mf-runtime.h.in: Change API to take void*/size_t region parameters.
1330 Add new access-type parameter for __mf_check. Move __MF_VIOL* out.
1331 * mf-impl.h: Corresponding changes. Update CLAMP* macros for void*
1332 values. Move __MF_VIOL* here.
1333 * mf-runtime.c (*): Adapt to void*/size_t API in mf-runtime.h.
1334 (check_initialization): New field in __mf_opts. Default off.
1335 (read_count,write_count): New fields in __mf_object.
1336 (__mf_check): Implement basic initialization checking.
1337 (__mf_insert_new_object): Assume STATIC|GUESS regions are initialized.
1338 (__mf_describe_object): Print new fields.
1339 (__mf_violation): Identify check/read vs. check/write in messages.
1340 * test/pass29-frag.c, test/fail22-frag.c: Basic tests for new
1341 "-check-initialized" mudflap option.
1342 * test/pass25-frag.c, test/fail21-frag.c: Adapt to API changes.
1343 * mf-hooks.c (MF_VALIDATE_EXTENT): Add new access-type parameter.
1344 Drop __FILE__/__LINE__ hack. Update callers.
1345 (*): Adapt to new mf-runtime.h API.
1346 * Makefile.in: regenerated.
1347
1348 2003-01-24 Frank Ch. Eigler <fche@redhat.com>
1349
1350 * configure.in: Build mf-runtime.h a more proper way.
1351 * mf-hooks.c (strdup, strndup): Correct reentrancy logic.
1352 * mf-runtime.c (verbose_violations): Turn on by default.
1353 * mf-runtime.h.in: Remove some miscellaneous stuff ...
1354 * mf-impl.h: ... and move it here.
1355 * configure: Regenerated.
1356
1357 2003-01-22 Frank Ch. Eigler <fche@redhat.com>
1358
1359 * configure.in: Look for C++ compiler.
1360 * test/*-frag.c, mf-driver.c: Reformatted with GNU indent and
1361 fixed type warnings when built with C++.
1362 * test/pass27-frag.cxx, pass28-frag.cxx: New C++ tests.
1363 * Makefile.am (TESTS): Run them.
1364 (*) Add new rules for building and running C++ tests.
1365 (TESTFLAGS): Set new default to avoid libstdc++-v3 shlib issues.
1366 * mf-runtime.h.in: Protect with extern "C".
1367 * Makefile, configure: Regenerated.
1368
1369 2003-01-06 Frank Ch. Eigler <fche@redhat.com>
1370
1371 Portability improvements.
1372 * configure.in: Look for glibc backtrace headers/functions.
1373 * mf-hooks.c: Don't include <execinfo.h> any more.
1374 * mf-runtime.c (__mf_set_options): Call more stdlib functions
1375 via CALL_REAL.
1376 (__mf_backtrace): Provide alternate baby implementation in
1377 absence of glibc.
1378 * test/mf-driver.c: Portability tweaks.
1379 * acinclude.m4: New file, containing top level libtool.m4.
1380 * aclocal.m4, configure, Makefile.in, config.h.in: Regenerated.
1381
1382 2002-12-19 Frank Ch. Eigler <fche@redhat.com>
1383
1384 * mf-runtime.h.in (HAVE_UINTPTR_T): Define unconditionally.
1385
1386 2002-11-08 Frank Ch. Eigler <fche@redhat.com>
1387
1388 * mf-runtime.c (options): Add new "wipe-heap", "wipe-stack"
1389 options.
1390 (__mf_unregister): Implement stack/heap object wiping.
1391 (__mf_set_options): Renamed from __mf_process_opts.
1392 (__mf_uncache_object): Change arg type, correct callers.
1393 * mf-impl.h: Corresponding changes.
1394 * mf-hooks.c (realloc): Save/restore heap-wiping flag.
1395 * mf-runtime.h.in (__mf_set_options): Extend public API.
1396 * test/pass26-frag.c: New test for stack wiping.
1397 * Makefile.am (TESTS): Run it.
1398 * Makefile.in: Regenerated.
1399
1400 2002-11-07 Frank Ch. Eigler <fche@redhat.com>
1401
1402 * mf-runtime.h.in (__mf_watch, __mf_unwatch): Extend public API.
1403 * mf-runtime.c (__mf_object_t): Add watching_p field.
1404 (__mf_watch_or_not): New function to implement
1405 object watch flagging.
1406 (__mf_watch, __mf_unwatch): New wrappers for above.
1407 (__mf_check, __mf_describe_object): Handle objects with watching_p.
1408 (__mf_count_violation): Enlarge array.
1409 (__mf_uncache_object): Renamed from __mf_remove_old_object. Don't
1410 unlink object. Clear cache properly.
1411 (__mf_unregister): Unlink object explicitly before uncaching.
1412 * test/fail21-frag.c, pass25-frag.c: New tests.
1413 * Makefile.in, aclocal.m4: Regenerated.
1414
1415 2002-11-05 Frank Ch. Eigler <fche@redhat.com>
1416
1417 * test/fail20-frag.c: New test for NULL pointer dereferencing.
1418 * Makefile.am (TESTS): Add it.
1419 * test/pass-stratcliff.c: Add decls of stpcpy.
1420 * configure.in: Test for <stdint.h>. Generate mf-runtime.h in
1421 build tree from config.h and new file mf-runtime.h.in.
1422 * mf-runtime.h.in: Renamed from mf-runtime.h. Tweak uintptr_t decl.
1423 * Makefile.in, configure, config.h.in: Regenerated.
1424 * mf-hooks.c: Add #undef for wrapped glibc str*/mem* macros.
1425 * mf-runtime.c (options, __mf_set_default_options): Support new
1426 default "abbreviate" option.
1427 (__mf_object.description_epoch): New field.
1428 (__mf_describe_object): Conditionally abbreviate objects already
1429 displayed in current epoch. Accept NULL input to increment epoch.
1430 (__mf_fini, __mf_ini): Reset description epoch.
1431 (__mf_register, __mf_unregister, __mf_adapt_cache, __mf_init): Ensure
1432 that NULL pointer slot in lookup cache is invalidated. Register a
1433 NOACCESS region around NULL.
1434 * mf-impl.h: Corresponding changes.
1435
1436 2002-10-16 Frank Ch. Eigler <fche@redhat.com>
1437
1438 * test/fail19-frag.c, pass24-frag.c, pass-stratcliff.c: New tests.
1439 * Makefile.am: Run them. Install mf-runtime.h.
1440 * Makefile.in: Regenerated.
1441 * mf-hooks.c: Add some markers for more missing functions.
1442 * mf-runtime.c (__mf_adapt_cache): Experiment with a utilization-based
1443 statistic to tune tune cache size (mask).
1444
1445 2002-10-01 Frank Ch. Eigler <fche@redhat.com>
1446
1447 * test/pass23-frag.c: New test for bit_field_ref expressions.
1448 * Makefile.am, Makefile.in: Add new test.
1449 * mf-hooks.c (mmap, munmap): Rewrite to track individual pages.
1450 (MF_VALIDATE_EXTENT): Accept zero-size mem/str operations.
1451 * mf-runtime.c (__mf_init): Register errno global.
1452 (__mf_find_object): Removed function.
1453 (__mf_check): Rewrite logic to support accesses across some
1454 contiguous but distinctly registered objects.
1455 (__mf_remove_old_object): Tolerate cache entries that span
1456 contiguous objects.
1457
1458 2002-09-30 Frank Ch. Eigler <fche@redhat.com>
1459
1460 * test/pass21-frag.c, pass22-frag.c: New tests: alloca, bitfields.
1461 * Makefile.am, Makefile.in: Run new tests.
1462 * mf-hooks.c (alloca): Correct stack direction logic.
1463
1464 2002-09-26 Frank Ch. Eigler <fche@redhat.com>
1465
1466 * mf-impl.h (adapt_cache): New option.
1467 * mf-runtime.c (__mf_set_default_options): Set its default value.
1468 Tweak the tree_aging parameter down.
1469 (__mf_check): Maintain separate counter for cache-adaptation.
1470 (__mf_tree_analyze): New function to collect object tree stats.
1471 (__mf_adapt_cache): New function to automate cache parameters.
1472
1473 2002-09-24 Frank Ch. Eigler <fche@redhat.com>
1474
1475 * mf-heuristics.c (__init_misc, __mf_heuristic_check): Add
1476 hypothetical #if-0'd argv/envp region registration.
1477 * mf-runtime.c (__mf_init): Add kludged form of above.
1478 (*) Add "heur_argv_environ" flag, default on, to govern this.
1479 * mf-impl.h: Corresponding changes.
1480
1481 2002-09-20 Frank Ch. Eigler <fche@redhat.com>
1482
1483 * test/fail18-frag.c: New test file for NOACCESS regions.
1484 * Makefile.am (TESTS): Add new test.
1485 * Makefile.in: Regenerated.
1486
1487 * mf-heuristics.c (__mf_heuristics_check): Correct deja_vu logic.
1488 * mf-impl.h (tree_aging): Add new mudflap_option, default 1000000.
1489 (optimize_object_tree): Remove unused mudflap_option.
1490 * mf-runtime.h (__MF_TYPE_NOACCESS): New region type. Add printing
1491 support throughout. Use .._MAX_CEM for cemetary upper bound.
1492 * mf-runtime.c (__mf_init): Register __mf_* globals as NOACCESS
1493 regions.
1494 (__mf_object): Add new liveness field for use by tree aging.
1495 (__mf_check): Trigger tree aging when needed.
1496 (__mf_age_tree): New function to decay liveness field.
1497 (__mf_find_objects_rec): Use liveness field to rotate tree.
1498 (__mf_insert_new_object): Only provide backtrace for HEAP objects.
1499 (__mf_unregister): Ditto.
1500 (__mf_register): Tweak duplicate-static message.
1501 (__mf_violation: Tweak nearby-object counter printing.
1502
1503 2002-09-16 Frank Ch. Eigler <fche@redhat.com>
1504
1505 * test/pass20-frag.c: New test file.
1506 * Makefile.am (TESTS): Reorganize. Add pass20 test.
1507 * Makefile.in: Regenerated.
1508
1509 * mf-impl.h (TRACE_IN, TRACE_OUT): Remove macros. Update callers.
1510 * mf-hooks.c (BEGIN_PROTECT): Add hook tracing here.
1511 * mf-heuristic.c (__mf_heuristic_check): Track seen /proc/self/map
1512 entries to avoid repeat registration.
1513 * mf-runtime.c (__mf_object_cemetary): Don't bother bury GUESS regions.
1514 (__mf_register, __mf_unregister): Rewrite GUESS handling logic.
1515
1516 2002-09-09 Frank Ch. Eigler <fche@redhat.com>
1517
1518 * Makefile.am: Create test sources with #include, not cat>>.
1519 * Makefile.in: Regenerated.
1520 * test/buildtest.sh: Removed.
1521 * test/driver.c (abort_handler, main): Be quiet.
1522
1523 2002-09-06 Frank Ch. Eigler <fche@redhat.com>
1524
1525 * test/pass18-frag.c, pass19-frag.c: New tests.
1526 * Makefile.am (check): Run them. Rebuild test programs each time.
1527 * Makefile.in: Regenerated.
1528
1529 2002-09-06 Frank Ch. Eigler <fche@redhat.com>
1530
1531 * mf-runtime.c (__mf_register): Correct SEGV-inducing error in
1532 overlapping object search.
1533 (__mf_violation): Likewise for nearby objects.
1534 Improve nearby-object listing.
1535
1536 cleanup:
1537 * mf-runtime.c, mf-hooks.c: Remove "{{{"/"}}}" folding marks.
1538 * mf-heuristics.c (__mf_heuristic_check): Tweak message.
1539
1540 2002-09-03 Frank Ch. Eigler <fche@redhat.com>
1541
1542 alloca support:
1543 * Makefile.am (AM_CFLAGS): New definition of needed settings.
1544 (HOOKOBJS): Add alloca-hook.o.
1545 * mf-hooks.c (alloca): New function to implement alloca in libiberty
1546 style.
1547 * mf-runtime.c (__mf_report): Call alloca(0) to flush remaining blocks.
1548 (__mf_backtrace): Reimplement without using alloca.
1549 * Makefile.in: Regenerated.
1550
1551 cleanup:
1552 * mf-hooks.c: Use VERBOSE_TRACE throughout instead of fprintf(stderr).
1553 Correct signedness bugs in length-tracking variables.
1554 * mf-impl.h: Make options unsigned.
1555 (CALL_WRAP): New macro to parallel CALL_REAL().
1556 (DECLARE): Remove erroneous ";" at end.
1557 * mf-runtime.c, mf-hooks.c, mf-heuristics.c: Replace remaining %p
1558 formatting specs with %08lx. Correct several compiler warnings.
1559
1560 2002-08-28 Frank Ch. Eigler <fche@redhat.com>
1561
1562 * mf-runtime.c (__mf_violation): Try harder to locate nearby objects.
1563
1564 2002-08-27 Frank Ch. Eigler <fche@redhat.com>
1565
1566 libmudflap hook breakup:
1567 * Makefile.am (TESTS_ENVIRONMENT): Add ../../gcc to LD_LIBRARY_PATH
1568 for libgcc_s.
1569 (TESTS): Make dependent on libmudflap.
1570 (HOOKOBJS): Break up mf-hooks.o into many little hook objects,
1571 compiled from segments of mf-hooks.c.
1572 * mf-hooks.c: Corresponding changes: wrap each function in
1573 #ifdef/#endif.
1574 * Makefile.in: Regenerated.
1575
1576 Heuristics reorganization:
1577 * mf-heuristics.c (__mf_register_ro_sections, __mf_init_heuristics):
1578 Remove these functions. Update callers.
1579 (__mf_heuristic_check): Incorporate all the various heuristics.
1580 Encode cacheability/retry judgement into trinary return value.
1581 Separate start-end logic into a separate fallback heuristic. Only
1582 register relevant /proc/self/map segments.
1583 * mf-impl.h: Corresponding changes.
1584 * mf-runtime.c (__mf_check): Reorganize heuristics fallback logic.
1585 (__mf_init): Don't call __mf_init_heuristics.
1586
1587 Tracing cleanup:
1588 * mf-heuristics.c, mf-runtime.c: Use new MUDFLAP_OPTION
1589 "-verbose-trace" to emit all tracing messages other than those of
1590 basic public api. Eliminate some duplicate/excessive messages.
1591 * mf-runtime.h: Corresponding changes.
1592
1593 2002-08-27 Graydon Hoare <graydon@redhat.com>
1594
1595 * mf-impl.h (WRAPPER): Change to create linker aliases for __wrap
1596 and __real when compiled with -DPIC.
1597 * mf-hooks.c (WRAPPER): Change all uses of WRAPPER macro slightly.
1598 * Makefile.am (AUTOMAKE_OPTIONS): Fix LD_LIBRARY_PATH for tests.
1599 * Makefile.in: Regenerate.
1600
1601 2002-08-26 Graydon Hoare <graydon@redhat.com>
1602
1603 * mf-impl.h: New file, private implementation header.
1604 * mf-runtime.h: Reorganize a bit.
1605 (CLAMPSZ): Fix arithmetic.
1606 (__MF_CACHE_MISS_P): Fix arithmetic.
1607 * mf-runtime.c: Reorganize a bit.
1608 (__mf_dynamic): New structure.
1609 (resolve_single_dynamic): New function.
1610 (__mf_resolve_dynamics): New function.
1611 (__mf_init): Initialize dynamic wrappers.
1612 * mf-hooks.c: Macro-ize __real calls.
1613 Clamp various bits of arithmetic.
1614 Add explicit __mf_check call contexts.
1615 * Makefile.am: Add dependencies on mf-impl.h
1616 * Makefile.in: Regenerate.
1617 * configure.in: Comment out shared override.
1618 * configure: Regenerate.
1619
1620 2002-08-22 Graydon Hoare <graydon@redhat.com>
1621
1622 * mf-runtime.c (__mf_process_opts): Sanity-check free_queue_length.
1623 (__mf_check): Re-inialize and check heuristics before violation.
1624 (__mf_register): Permit updating pure-guess regions.
1625 * mf-hooks.c (__wrap_free): Correct some free queue logic.
1626 (__wrap_dlopen): New wrapper function.
1627 (__wrap_mmap): New wrapper function.
1628 (__wrap_munmap): New wrapper function.
1629 * mf-heuristics.c (__mf_register_ro_sections): Register *all* regions
1630 which are not stack addresses.
1631 (is_stack_address): New function.
1632 (__mf_init_heuristics): Save and restore state, always initialize with
1633 "starting" state.
1634
1635 2002-08-21 Frank Ch. Eigler <fche@redhat.com>
1636
1637 * mf-hooks.c (MF_VALIDATE_EXTENT): Rewrite to correct off-by-one
1638 error. Pass location string.
1639 (wrap_strcpy, wrap_strncpy): Remove extra %s in trace strings.
1640 * mf-runtime.c (options): Add lc-mask, lc-shift options.
1641 (__mf_process_opts): Apply some sanity checking for lc-mask.
1642 (__mf_check, __mf_violation): Take new location-string argument.
1643 Update callers to pass NULL if necessary.
1644 (__mf_backtrace): New smart backtracer function. Calls replace
1645 several ad-hoc blocks elsewhere.
1646 (__mf_describe_object): Remove bad reentrancy test. Improve
1647 tracing message.
1648 * mf-runtime.h: Corresponding changes. Public/private markup.
1649 (__MF_CACHE_MISS_P): New macro.
1650
1651 2002-08-20 Graydon Hoare <graydon@redhat.com>
1652
1653 * mf-runtime.h: New option: stack_bound (heuristic).
1654 Move some macros out of implementation files.
1655 * mf-runtime.c: New option string: -stack-bound.
1656 Unify recursion protection with hooks.
1657 Add more logging.
1658 (__mf_check): Call __mf_heuristic_check.
1659 (__mf_process_opts): Fix "no-" processing.
1660 * mf-heuristics.c (__mf_heuristic_check): New function.
1661 * mf-hooks.c: Much off-by-one fixing, recursion protection.
1662
1663 2002-08-20 Frank Ch. Eigler <fche@redhat.com>
1664
1665 Option parsing improvements, region splitting bug fixes:
1666 * mf-heuristics.c (__mf_register_ro_sections): Add warned casts.
1667 * mf-runtime.h (heur_proc_map): New libmudflap option.
1668 * mf-runtime.c (__mf_set_default_options): Set it.
1669 (__mf_usage): Print default values/status.
1670 (__mf_process_opts): Support general "no-" option string prefix.
1671 (__mf_init): Print __mf_usage on unknown-option error.
1672 (__mf_register): Print trace message up front.
1673 Correct region splitting logic for case where a subregion disappears.
1674 Correct memory leak.
1675 (__mf_violation): Make even basic message conditional on option.
1676
1677 Build cleanup:
1678 * Makefile.am (TESTS_ENVIRONMENT): Add -no-heur-proc-map.
1679 (clean-local): New target.
1680 (test/*x rules): Add -g CFLAGS.
1681 (CFLAGS): Add -freorder-blocks.
1682 (MFCONFIG_CFLAGS, INCLUDE): Remove unneeded settings.
1683 * Makefile.in: Regenerated.
1684 * Makefile, mf-config.h: Removed files.
1685
1686 2002-08-16 Graydon Hoare <graydon@redhat.com>
1687
1688 * mf-runtime.c (__mf_insert_new_object): Factor out of
1689 __mf_register.
1690 (__mf_remove_old_object): Factor out of __mf_unregister.
1691 (__mf_register): Handle guessed regions, splitting
1692 guesses when new registrations arrive.
1693 (__mf_unregister): Do not unregister guesses.
1694 * mf-runtime.h: Move convenience macros around,
1695 declare new option fields. Add __MF_TYPE_GUESS.
1696 * mf-hooks.c (__wrap_*alloc): Use crumple zones.
1697 (__wrap_free): Call __real_free for deferred frees.
1698 * Makefile.am: Add more tests, fix dependency.
1699 * Makefile.in: Regenerate.
1700 * test/pass[13..17]-frag.c: New testcases.
1701 * test/fail[13..17]-frag.c: New testcases.
1702
1703 2002-08-15 Graydon Hoare <graydon@redhat.com>
1704
1705 * mf-heuristics.c: New file.
1706 * mf-runtime.c (options): Add -trace-calls option.
1707 (__mf_init): Call __mf_init_heuristics.
1708
1709 2002-08-14 Graydon Hoare <graydon@redhat.com>
1710
1711 * Makefile.am (TESTS): Add testsuite support.
1712 * Makefile.in: Regenerate.
1713 * test/mf-driver.c: New file.
1714 * test/buildtest.sh: New file.
1715 * test/passNN-frag.c: New testcases.
1716 * test/failNN-frag.c: New testcases.
1717
1718 2002-08-14 Graydon Hoare <graydon@redhat.com>
1719
1720 * mf-hooks.c: Change __real_strlen() to __real_strlen()+1 when
1721 verifying non-size-limited string extents.
1722
1723 2002-08-14 Frank Ch. Eigler <fche@redhat.com>
1724
1725 * mf-hooks.c: Make __wrap string* functions use __real_str[n]len
1726 instead of plain str[n]len for internal checks.
1727 * mf-runtime.c (__mf_violation): Print optional stack traceback.
1728
1729 2002-08-14 Frank Ch. Eigler <fche@redhat.com>
1730
1731 * mf-hooks.c: Remove #if-0 around hooks that are now ld-wrapped.
1732
1733 2002-08-13 Graydon Hoare <graydon@redhat.com>
1734
1735 * mf-runtime.c: Rework configuration to operate on
1736 environment variable options rather than #defines
1737 (__mf_violation): Add simple fork-a-gdb violaiton mode.
1738 (__mf_init): Set static __mf_active_p flag on startup,
1739 to inhibit mudflap wrap-based checking during crt0.s.
1740 * mf-runtime.h: Declare options structure.
1741 * mf-hooks.c: New wrappings for mem*, b*, str*
1742 libc functions (temporarily #if 0-ed out).
1743
1744 2002-08-12 Frank Ch. Eigler <fche@redhat.com>
1745
1746 * Makefile.am, configure.in: New files.
1747 * Makefile.in, Makefile, configure, config.h.in: New generated files.
1748 * stamp-h.in, aclocal.m4: Ditto.
1749
1750 2002-08-08 Frank Ch. Eigler <fche@redhat.com>
1751
1752 * Makefile: New file.
1753 * mf-config.h: New file: runtime configuration.
1754 * mf-hooks.c: New file: interposed libc functions.
1755 * mf-runtime.c: New file: bulk of runtime.
1756 * mf-runtime.h: New file: public functions.