1 2013-05-31 Release Manager
5 2013-03-22 Release Manager
9 2013-03-14 Jakub Jelinek <jakub@redhat.com>
11 PR tree-optimization/53265
12 * testsuite/libmudflap.c/fail37-frag.c: Add optimization barrier.
14 2013-02-03 Richard Sandiford <rdsandiford@googlemail.com>
16 Update copyright years.
18 2013-01-03 Jakub Jelinek <jakub@redhat.com>
20 * mf-runtime.c (__mf_usage): Update copyright notice dates.
22 2012-12-15 Alexandre Oliva <aoliva@redhat.com>
24 * mf-hooks1.c (free): Return on NULL before any logging.
26 2012-09-14 David Edelsohn <dje.gcc@gmail.com>
28 * configure: Regenerated.
30 2012-07-13 Richard Guenther <rguenther@suse.de>
32 * testsuite/libmudflap.c++/ctors.exp: Explicitely specify -O0.
33 * testsuite/libmudflap.c++/c++frags.exp: Likewise.
34 * testsuite/libmudflap.cth/cthfrags.exp: Likewise.
35 * testsuite/libmudflap.c/cfrags.exp: Likewise.
36 * testsuite/libmudflap.c/externs.exp: Likewise.
38 2012-07-13 Richard Guenther <rguenther@suse.de>
40 * testsuite/libmudflap.c/fail11-frag.c: Adjust to not look like memset.
41 * testsuite/libmudflap.c/fail12-frag.c: Likewise.
43 2012-05-29 Joseph Myers <joseph@codesourcery.com>
45 * mf-impl.h: Fix typo.
47 2012-05-16 H.J. Lu <hongjiu.lu@intel.com>
49 * configure: Regenerated.
51 2012-04-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
54 * testsuite/lib/libmudflap.exp: Handle caret.
56 2012-01-19 Jakub Jelinek <jakub@redhat.com>
59 * testsuite/libmudflap.c/fail68-frag.c: New test.
61 2012-01-01 Jakub Jelinek <jakub@redhat.com>
63 * mf-runtime.c (__mf_usage): Update copyright notice dates.
65 2011-11-21 Andreas Tobler <andreast@fgznet.ch>
67 * configure: Regenerate.
69 2011-07-31 Tom de Vries <tom@codesourcery.com>
72 * testsuite/libmudflap.c/fail31-frag.c: Adapt testcase to prevent
75 2011-07-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
78 2011-07-15 Jakub Jelinek <jakub@redhat.com>
81 PR tree-optimization/49309
82 * testsuite/libmudflap.c++/pass68-frag.cxx: New test.
84 2011-07-15 Jakub Jelinek <jakub@redhat.com>
87 PR tree-optimization/49309
88 * testsuite/libmudflap.c++/pass68-frag.cxx: New test.
90 2011-07-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
92 * configure.ac: Don't create pth.
93 Check for library containing sched_yield.
94 * configure: Regenerate.
95 * config.h.in: Regenerate.
97 * testsuite/lib/libmudflap.exp (libmudflap-init): Use
98 mfconfig_libs in -static check.
100 2011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
103 * mf-runtime.c (__wrap_main) [__sun__ && __svr4__]: Don't register
104 stdin, stdout, stderr.
105 Register __ctype, __ctype_mask.
107 * configure.ac: Check for mmap64.
108 Check for rawmemchr, stpcpy, mempcpy.
109 * configure: Regenerate.
110 * config.h.in: Regenerate.
111 * mf-hooks1.c [HAVE_MMAP64] (__mf_0fn_mmap64): New function.
112 (mmap64): New wrapper function.
113 * mf-impl.h (__mf_dynamic_index) [HAVE_MMAP64]: Add dyn_mmap64.
114 * mf-runtime.c (__mf_dynamic) [HAVE_MMAP64]: Handle mmap64.
116 * mf-hooks2.c [HAVE_GETMNTENT && HAVE_SYS_MNTTAB_H]: Implement
119 * mf-hooks3.c (_REENTRANT): Define.
121 * testsuite/libmudflap.c/heap-scalestress.c (SCALE): Reduce to 10000.
123 * testsuite/libmudflap.c/pass-stratcliff.c: Include ../config.h.
125 Use HAVE_RAWMEMCHR, HAVE_STPCPY, HAVE_MEMPCPY as guards.
127 * testsuite/libmudflap.c/pass47-frag.c: Expect __ctype warning on
130 2011-07-01 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
133 * testsuite/lib/libmudflap.exp (load_gcc_lib): Load
135 * testsuite/libmudflap.cth/cthfrags.exp: Only pass
136 --noinhibit-exec to GNU ld.
138 2011-06-27 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
141 * configure.ac: Check for sys/mnttab.h.
142 Check for library containing connect.
143 * configure: Regenerate.
144 * config.h.in: Regenerate.
145 * mf-hooks2.c [HAVE_SYS_MNTTAB_H]: Include <sys/mnttab.h>.
146 * testsuite/libmudflap.c/pass-stratcliff.c (main) [__sun__ &&
147 __svr4__]: Disable rawmemchr, stpcpy, mempcpy tests.
149 2011-02-13 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
151 * configure: Regenerate.
153 2011-01-03 Jakub Jelinek <jakub@redhat.com>
155 * mf-runtime.c (__mf_usage): Update copyright notice dates.
157 2010-10-31 Jason Merrill <jason@redhat.com>
160 * testsuite/libmudflap.cth/pass40-frag.c: Increase timeout to 30.
162 2010-08-20 Uros Bizjak <ubizjak@gmail.com>
164 * testsuite/libmudflap.c++/pass41-frag.cxx (dg-prune-output):
167 2010-06-09 Iain Sandoe <iains@gcc.gnu.org>
170 * configure: Regenerate.
172 2010-05-16 Uros Bizjak <ubizjak@gmail.com>
174 * testsuite/libmudflap.c/pass46-frag.c (dg-options): Remove -Wall.
176 2010-05-15 Uros Bizjak <ubizjak@gmail.com>
178 * testsuite/lib/mfdg.exp (additional_prunes): New global.
179 (dg-test): Clear additional_prunes before test is run.
180 (dg-prune-output): New procedure.
181 * testsuite/lib/libmudflap.exp (libmudflap-dg-test): Do not call
183 (libmudflap-dg-prune): New procedure.
184 * testsuite/libmudflap.c++/pass57-frag.cxx (dg-prune-output):
187 2010-05-04 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
190 * configure.ac (AM_INIT_AUTOMAKE): Add no-dist.
191 * Makefile.in: Regenerate.
192 * testsuite/Makefile.in: Regenerate.
194 2010-04-02 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
196 * Makefile.in: Regenerate.
197 * aclocal.m4: Regenerate.
198 * testsuite/Makefile.in: Regenerate.
200 2010-03-15 David S. Miller <davem@davemloft.net>
202 * testsuite/libmudflap.c/pass54-frag.c: Add explicit return from
205 2010-01-09 Jakub Jelinek <jakub@redhat.com>
207 * mf-runtime.c (__mf_usage): Update copyright notice dates.
209 2009-12-05 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
211 * Makefile.in: Regenerate.
212 * configure: Regenerate.
213 * testsuite/Makefile.in: Regenerate.
215 2009-09-22 Frank Ch. Eigler <fche@redhat.com>
218 * mf-runtime.c (__mf_init): Ignore $MUDFLAP_OPTIONS if
219 running setuid or setgid.
221 2009-09-01 Loren J. Rittle <ljrittle@acm.org>
223 * mf-runtime.c (__mf_init): Support FreeBSD.
224 Prime mutex which calls calloc upon first lock to avoid deadlock.
225 * mf-hooks1.c (__mf_0fn_mmap): Support FreeBSD.
226 Ignore red zone allocation request for initial thread's stack.
228 2009-09-01 Loren J. Rittle <ljrittle@acm.org>
229 Andreas Schwab <schwab@linux-m68k.org>
231 * testsuite/libmudflap.c/pass51-frag.c (MAP_FAILED): Define,
232 if not in system header; use it. On FreeBSD, must pass fd==-1
233 with MAP_ANON flag. Correct mmap error check.
234 * testsuite/libmudflap.c/fail40-frag.c: Ditto.
236 2009-08-24 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
238 * configure.ac (AC_PREREQ): Bump to 2.64.
240 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
242 * Makefile.am (install-html, install-pdf): Remove.
243 * Makefile.in: Regenerate.
245 * Makefile.in: Regenerate.
246 * aclocal.m4: Regenerate.
247 * config.h.in: Regenerate.
248 * configure: Regenerate.
249 * testsuite/Makefile.in: Regenerate.
251 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
253 * configure.ac (_AC_ARG_VAR_PRECIOUS): Use m4_rename_force.
255 2009-07-16 Joseph Myers <joseph@codesourcery.com>
257 * configure: Regenerate.
259 2009-07-11 Richard Sandiford <rdsandiford@googlemail.com>
264 * testsuite/lib/libmudflap.exp: Revert 2009-06-30 commit.
266 2009-07-01 Richard Guenther <rguenther@suse.de>
268 PR tree-optimization/19831
269 * testsuite/libmudflap.c/fail11-frag.c: Make allocated memory
271 * testsuite/libmudflap.c/fail12-frag.c: Likewise.
272 * testsuite/libmudflap.c/fail16-frag.c: Likewise.
273 * testsuite/libmudflap.c/fail31-frag.c: Likewise.
275 2009-06-30 Richard Sandiford <r.sandiford@uk.ibm.com>
277 * testsuite/lib/libmudflap.exp (libmudflap-init): Don't add "."
278 to ld_library_path. Use add_path. Add just find_libgcc_s to
279 ld_library_path, not every libgcc multilib directory.
281 2009-04-09 Nick Clifton <nickc@redhat.com>
283 * mf-hooks1.c: Change copyright header to refer to version 3
284 of the GNU General Public License with version 3.1 of the GCC
285 Runtime Library Exception and to point readers at the COPYING3
286 and COPYING3.RUNTIME files and the FSF's license web page.
287 * mf-heuristics.c: Likewise.
288 * mf-hooks2.c: Likewise.
289 * mf-hooks3.c: Likewise.
290 * mf-impl.h: Likewise.
291 * mf-runtime.c: Likewise.
292 * mf-runtime.h: Likewise.
294 2009-04-09 Jakub Jelinek <jakub@redhat.com>
296 * testsuite/lib/mfdg.exp: Change copyright header to refer to
297 version 3 of the GNU General Public License and to point readers
298 at the COPYING3 file and the FSF's license web page.
299 * testsuite/lib/libmudflap.exp: Likewise.
301 2009-03-31 Ben Elliston <bje@au.ibm.com>
304 * testsuite/libmudflap.c/fail27-frag.c: Match `mudflap dead
305 object', not `mudflap object'.
307 2009-03-01 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
309 * configure: Regenerate.
311 2009-02-03 Jakub Jelinek <jakub@redhat.com>
313 * mf-runtime.c (__mf_usage): Update copyright notice dates.
315 2009-01-23 Jie Zhang <jie.zhang@analog.com>
317 * mf-impl.h (__mf_get_state, __mf_set_state): Don't use
318 __thread when TLS support is emulated.
319 * mf-hooks3.c (__mf_get_state, __mf_set_state): Likewise.
320 * mf-runtime.c (__mf_state_1): Likewise.
321 * configure.ac: Use GCC_CHECK_EMUTLS.
322 * configure: Regenerate.
323 * config.h.in: Regenerate.
325 2008-12-18 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
327 * configure: Regenerate.
329 2008-11-26 Janis Johnson <janis187@us.ibm.com>
332 * testsuite/lib/mfdg.exp (dg-test): Use new timeout support.
333 (dg-timeout): Remove.
334 (standard-wait): Remove.
335 * testsuite/lib/libmudflap.exp: Include new timeout library files.
336 (libmudflap_target_compile): Set timeout value from new proc.
338 2008-11-10 Jakub Jelinek <jakub@redhat.com>
341 * testsuite/libmudflap.c/pass67-frag.c: New test.
343 2008-10-09 Jakub Jelinek <jakub@redhat.com>
346 * testsuite/libmudflap.c++/pass66-frag.cxx: New test.
348 2008-09-26 Peter O'Gorman <pogma@thewrittenword.com>
349 Steve Ellcey <sje@cup.hp.com>
351 * configure: Regenerate for new libtool.
352 * Makefile.in: Ditto.
353 * testsuite/Makefile.in: Ditto.
355 2008-09-15 Jakub Jelinek <jakub@redhat.com>
358 * testsuite/libmudflap.c/pass64-frag.c: New test.
360 2008-06-17 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
362 * Makefile.in: Regenerate.
363 * config.h.in: Regenerate.
364 * configure: Regenerate.
365 * testsuite/Makefile.in: Regenerate.
367 2008-04-18 Paolo Bonzini <bonzini@gnu.org>
370 * aclocal.m4: Regenerate.
371 * configure: Regenerate.
373 2008-03-20 Volker Reichelt <v.reichelt@netcologne.de>
375 * testsuite/libmudflap.c/pass63-frag.c: New test.
377 2008-03-16 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
379 * aclocal.m4: Regenerate.
380 * configure: Likewise.
381 * Makefile.in: Likewise.
382 * testsuite/Makefile.in: Likewise.
384 2008-03-02 Jakub Jelinek <jakub@redhat.com>
386 * mf-runtime.c (__mf_usage): Update copyright notice dates.
388 2008-02-21 Uros Bizjak <ubizjak@gmail.com>
390 * testsuite/libmudflap.c/fail8-frag.c: Adjust scan pattern for
392 * testsuite/libmudflap.c/fail9-frag.c: Ditto.
394 2008-01-24 David Edelsohn <edelsohn@gnu.org>
396 * configure: Regenerate.
398 2008-01-05 Jakub Jelinek <jakub@redhat.com>
400 PR tree-optimization/34618
401 * testsuite/libmudflap.c/pass62-frag.c: New test.
403 2008-01-03 Jakub Jelinek <jakub@redhat.com>
406 * testsuite/libmudflap.c++/pass61-frag.cxx: New test.
408 2008-01-01 Volker Reichelt <v.reichelt@netcologne.de>
411 * testsuite/libmudflap.c++/pass60-frag.cxx: New test.
413 2007-10-15 Maciej W. Rozycki <macro@linux-mips.org>
415 * configure: Regenerate following changes to ../config/tls.m4.
417 2007-07-26 Tom Tromey <tromey@redhat.com>
419 * Makefile.in: Rebuilt.
420 * Makefile.am (clean-local): Removed.
421 (pth/mf-runtime.lo, pth/mf-heuristics.lo, pth/mf-hooks1.lo,
422 pth/mf-hooks2.lo, pth/mf-hooks3.lo): Likewise.
423 (libmudflapth_la_SOURCES): List sources.
424 (libmudflapth_la_LIBADD): Clear.
425 (libmudflapth_la_CFLAGS): New variable.
427 2007-07-05 H.J. Lu <hongjiu.lu@intel.com>
429 * aclocal.m4: Regenerated.
431 2007-06-02 Paolo Bonzini <bonzini@gnu.org>
433 * configure: Regenerate.
435 2007-05-31 Frank Ch. Eigler <fche@redhat.com>
437 From Andi Kleen <ak@suse.de>:
438 * mf-runtime.c (options): Rename structure for compatibility with
441 2007-05-23 Steve Ellcey <sje@cup.hp.com>
443 * Makefile.in: Regenerate.
444 * configure: Regenerate.
445 * aclocal.m4: Regenerate.
446 * testsuite/Makefile.in: Regenerate.
448 2007-03-14 Uros Bizjak <ubizjak@gmail.com>
450 * testsuite/libmudflap.cth/pass59-frag.c (main): Fix casting of arg.
452 2007-03-01 Brooks Moses <brooks.moses@codesourcery.com>
454 * Makefile.am: Add dummy install-pdf target.
455 * Makefile.in: Regenerate
457 2007-02-07 Jakub Jelinek <jakub@redhat.com>
460 * configure: Regenerate.
462 2006-12-04 Eric Botcazou <ebotcazou@libertysurf.fr>
464 * configure: Regenerate.
466 2006-11-13 Daniel Jacobowitz <dan@codesourcery.com>
468 * configure: Regenerated.
470 2006-11-10 Frank Ch. Eigler <fche@redhat.com>
473 * mf-hooks1.c (__mf_0fn_malloc): Make the bootstrap buffers
474 static but not function scope static.
475 (free): Skip deallocation attempts for objects placed into
477 * testsuite/libmudflap.cth/pass59-frag.c: New test.
479 2006-11-06 Frank Ch. Eigler <fche@redhat.com>
481 From Herman ten Brugge <hermantenbrugge@home.nl>:
482 * mf-runtime.c (__mf_uncache_object): Optimize the code so that
483 small and large objects are handled a lot faster.
485 2006-11-06 Frank Ch. Eigler <fche@redhat.com>
487 * configure.ac (__libc_freeres): Look for it.
488 * mf-impl.h (call_libc_freeres): New configuration flag.
489 * mf-runtime.c (__mf_set_default_options): Set it by default.
490 (__mfu_report): Call it if needed.
491 (__mfu_unregister): Remove "unaccessed registered object" warning.
492 * configure, config.h.in: Regenerated.
494 2006-09-18 Tom Tromey <tromey@redhat.com>
496 * configure: Rebuilt.
498 2006-06-21 Frank Ch. Eigler <fche@redhat.com>
501 mf-runtime.h installation based on ssp patch for PR 26473 from
502 Mark Mitchell <mark@codesourcery.com>.
503 * configure.ac (ACX_NONCANONICAL_TARGET): Use it.
504 * Makefile.am (target_noncanonical): Define.
505 (libsubincludedir): New variable.
506 (nobase_libsubinclude_HEADERS): Add mf-runtime.h.
507 (include_HEADERS): Remove.
508 * configure, aclocal.m4, config.h.in: Regenerated.
509 * Makefile.in, testsuite/Makefile.in: Likewise.
510 * mf-runtime.h: Add #ifndef protection for conflicting _REENTRANT
511 and _THREAD_SAFE redefinition values.
513 2006-05-23 Carlos O'Donell <carlos@codesourcery.com>
515 * Makefile.am: Add install-html target. Add install-html to .PHONY
516 * Makefile.in: Regenerate.
518 2006-04-19 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
521 * testsuite/libmudflap.c++/error1-frag.cxx: New test.
524 * testsuite/libmudflap.c++/error2-frag.cxx: New test.
526 2006-04-10 Matthias Klose <doko@debian.org>
528 * testsuite/lib/libmudflap.exp (libmudflap-init): Recognize multilib
529 directory names containing underscores.
531 2005-11-22 Janis Johnson <janis187@us.ibm.com>
533 * testsuite/lib/libmudflap.exp (libmudflap-init): Remove -static from
534 MUDFLAP_FLAGS if static library not supported.
535 * testsuite/libmudflap.c/cfrags.exp (MUDFLAP_FLAGS): new.
536 * testsuite/libmudflap.c/externs.exp: Ditto.
537 * testsuite/libmudflap.c++/ctors.exp: Ditto.
538 * testsuite/libmudflap.c++/c++frags.exp: Ditto.
539 * testsuite/libmudflap.cth/cthfrags.exp: Ditto.
541 2005-10-04 James E Wilson <wilson@specifix.com>
543 * configure.ac (mudflap_cv_entry_point): Use quadrigraphs to declare
544 $name as array of characters with unknown bound. Also store into the
546 * configure: Regenerate.
548 2005-09-30 James E. Wilson <wilson@specifix.com>
550 * configure.ac (pthread.h): Use AC_CHECK_HEADERS instead of
552 (target_thread_file): New. Set from sed'ed gcc output.
553 (posix_threads): New. Set from target_thread_file. Use instead of
555 (pthread_create_version): Move initialization before code using it.
556 * configure: Regenerate.
558 * mf-heuristics.c (_end, ENTRY_POINT): Make them arrays with unknown
561 2005-09-29 James E. Wilson <wilson@specifix.com>
563 * mf-hooks1.c (__mf_0fn_mmap, mmap, __mf_0fn_munmap, munmap): Protect
564 with HAVE_MMAP ifdef.
566 2005-09-23 Frank Ch. Eigler <fche@elastic.org>
569 * mf-hooks2.c (accept): Tolerate NULL sockaddr* parameter.
571 2005-09-23 Frank Ch. Eigler <fche@elastic.org>
573 * testsuite/libmudflap.c++/pass58-frag.cxx: New test for heisenbug 19319.
575 2005-09-23 Tom Tromey <tromey@redhat.com>
577 * aclocal.m4, configure: Rebuilt.
578 * configure.ac: Use GCC_CHECK_TLS.
579 * acinclude.m4 (LIBMUDFLAP_CHECK_TLS, LIBMUDFLAP_ENABLE): Moved
582 2005-08-22 Jim Wilson <wilson@specifix.com>
584 * mf-hooks2.c (MF_REGISTER_fopen): Define to __MF_TYPE_STATIC when
585 __FreeBSD__ is defined.
587 2005-08-17 Jim Wilson <wilson@specifix.com>
589 * mf-hooks1.c (malloc, calloc, realloc, free,
590 __mf_wrap_alloca_indirect): Call BEGIN_MALLOC_PROTECT before calling
591 the real routines, and END_MALLOC_PROTECT afterwards.
592 * mf-impl.h (enum __mf_state_enum): Expand comment. Add in_malloc.
593 (BEGIN_PROTECT): Handle in_malloc state.
594 (BEGIN_MALLOC_PROTECT, END_MALLOC_PROTECT): New.
595 * testsuite/libmudflap.c/hook2-allocstuff.c: New.
597 2005-08-17 Kelley Cook <kcook@gcc.gnu.org>
599 * All files: Update FSF address.
601 2005-08-15 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
603 * mf-hooks3.c (main_seen_p): Remove.
604 (__mf_get_state): Remove attempt to recognize the main thread.
606 2005-08-15 Maciej W. Rozycki <macro@linux-mips.org>
608 * configure.ac: Test for the name of the symbol used for the entry
609 point; define ENTRY_POINT to the result.
610 * configure: Regenerate.
611 * config.h.in: Regenerate.
612 * mf-heuristics.c: Replace _start with ENTRY_POINT throughout.
614 2005-08-14 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
616 * mf-runtime.c (__mf_state_1): Initialize to reentrant.
617 (__mf_init): Set thread state active.
618 * mf-hooks3.c (__mf_pthread_spawner): Always set thread
620 (pthread_create wrapper): Always use thread spawner.
622 * testsuite/libmudflap.cth/pass37-frag.c: Increase timeout.
623 * testsuite/libmudflap.cth/pass39-frag.c: Likewise.
625 2005-07-16 Richard Henderson <rth@redhat.com>
627 * acinclude.m4: New file.
628 * configure.ac: Invoke LIBMUDFLAP_CHECK_TLS.
629 * configure, config.h.in, Makefile.in, testsuite/Makefile.in: Rebuild.
630 * mf-hooks1.c (__mf_0fn_malloc): Move body from ...
631 (__mf_0fn_calloc): ... here.
632 * mf-hooks3.c (struct pthread_info): Remove.
633 (__mf_pthread_info, __mf_pthread_info_idx): Remove.
634 (LIBMUDFLAPTH_THREADS_MAX): Set to 1021.
635 (struct mf_thread_data): New.
636 (mf_thread_data, mf_thread_data_lock): New.
637 (__mf_allocate_blank_threadinfo): Remove.
638 (__mf_find_threadinfo): Rewrite and simplify. Only use if TLS is
640 (__mf_state_perthread): Remove.
641 (__mf_get_state, __mf_set_state): New.
642 (__mf_pthread_cleanup): Use &errno, rather than saved pointer.
643 Update mf_thread_data killing procedure.
644 (__mf_pthread_spawner): Similarly.
645 (__mf_0fn_pthread_create): Only use wrapper if necessary. Remove
646 code to allocate thread stack space.
647 (__mf_0fn_pthread_join, pthread_join): Remove.
648 (__mf_0fn_pthread_exit, pthread_exit): Remove.
649 * mf-impl.h (dyn_pthread_join, dyn_pthread_exit): Remove.
650 (__mf_state_1): Rename from __mf_state; use TLS when available.
651 (__mf_get_state, __mf_set_state): New. Update all users.
652 * mf-runtime.c (begin_recursion_protect1): New.
653 (BEGIN_RECURSION_PROTECT): Use it.
654 (__mf_state_1): Rename from __mf_state; use TLS when available.
655 (threads_active_p): Remove.
656 (__mf_usage): Compute it directly.
658 2005-06-19 Ulrich Weigand <uweigand@de.ibm.com>
660 * testsuite/libmudflap.c/externs-1.c (main): Add return statement.
662 2005-06-15 Frank Ch. Eigler <fche@redhat.com>
664 Fix for uncaching bug reported by Herman ten Brugge.
665 * mf-runtime.c (__mf_uncache_object): Search whole cache.
666 * testsuite/libmudflap.c/fail40-frag.c: New test.
668 2005-05-23 Alfred M. Szmidt <ams@gnu.org>
671 * Makefile.am (AM_MAKEFLAGS): Pass includedir.
672 * Makefile.in: Amend.
674 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
677 * testsuite/libmudflap.c/externs.exp, externs-{1,2}.c: New test files.
678 * testsuite/libmudflap.c/cfrags.exp: Bypass new sources.
680 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
683 * testsuite/libmudflap.c++/*.exp: Assert build tree g++.
685 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
688 * mf-impl.h (mudflap_mode, violation_mode): Make these ordinary
689 unsigned vars with #defines instead of enums.
691 2005-05-09 Mike Stump <mrs@apple.com>
693 * configure: Regenerate.
695 2005-04-12 Mike Stump <mrs@apple.com>
697 * configure: Regenerate.
699 2005-04-12 Frank Ch. Eigler <fche@redhat.com>
702 * testsuite/libmudflap.c++/c++frags.exp: Also test -O permutation.
703 * testsuite/libmudflap.c++/pass57-frag.cxx: New test.
705 2005-04-04 Alan Modra <amodra@bigpond.net.au>
707 * mf-runtime.c (__mfu_unregister): Warning fix for char unsigned.
709 2005-03-31 Mike Stump <mrs@apple.com>
711 * mf-runtime.h: Add libmudflap copyright clause.
713 2005-03-21 Mike Stump <mrs@apple.com>
715 * mf-heuristics.c: Fix whitespace at end of line.
716 * mf-hooks1.c: Likewise.
717 * mf-hooks2.c: Likewise.
718 * mf-hooks3.c: Likewise.
719 * mf-impl.h: Likewise.
720 * mf-runtime.c: Likewise.
721 * mf-runtime.h: Likewise.
723 2005-03-21 Zack Weinberg <zack@codesourcery.com>
725 * configure.ac: Do not invoke TL_AC_GCC_VERSION.
726 In all substitutions, expand gcc_version in Makefile.
727 * aclocal.m4, configure: Regenerate.
728 * Makefile.am: Set gcc_version.
729 * Makefile.in, testsuite/Makefile.in: Regenerate.
731 2005-03-17 Frank Ch. Eigler <fche@redhat.com>
733 * mf-runtime.c (__mfu_check): Respect ignore_reads configuration.
734 * testsuite/libmudflap.c/{pass56,fail39}-frag.c: New tests.
736 2005-02-13 Frank Ch. Eigler <fche@redhat.com>
739 * testsuite/libmudflap.c++/pass55-frag.c: New test.
741 2005-01-05 Richard Henderson <rth@redhat.com>
743 * testsuite/libmudflap.c/pass32-frag.c: Fix typo.
745 2005-01-02 Greg McGary <greg@mcgary.org>
747 * mf-impl.h (uintptr_t): Get typedef via stdint.h or define explicitly.
748 * mf-runtime.h: New file, replaces mf-runtime.h.in.
749 * configure.ac (AC_CONFIG_FILES): mf-runtime.h is no longer generated.
750 * Makefile.in: Ditto.
751 * testsuite/lib/libmudflap.exp: Add -I${srcdir}/.. to get mf-runtime.h
752 * testsuite/libmudflap.c/pass32-frag.c: s/uintptr_t/__mf_uintptr_t/
753 * testsuite/libmudflap.c/fail36-frag.c: New test.
754 * testsuite/libmudflap.c/fail37-frag.c: New test.
755 * testsuite/libmudflap.c/fail38-frag.c: New test.
757 2004-12-08 Kelley Cook <kcook@gcc.gnu.org>
759 * Makefile.am: Add ../config to ACLOCAL_AMFLAGS.
760 * aclocal.m4, Makefile.in, testsuite/Makefile.in: Regenerate.
762 2004-12-02 Richard Sandiford <rsandifo@redhat.com>
764 * configure.ac: Use TL_AC_GCC_VERSION to set gcc_version.
765 * aclocal.m4: Include ../config/gcc-version.m4.
766 * configure, Makefile.in, testsuite/Makefile.in: Regenerate.
768 2004-11-29 Kelley Cook <kcook@gcc.gnu.org>
770 * Makefile.am: Define ACLOCAL_AMFLAGS.
771 * acinclude.m4: Remove.
772 * stamp-h.in: Remove superfluous stamp file.
773 * aclocal.m4, configure, Makefile.in: Regenerate.
774 * testsuite/Makefile.in: Likewise.
776 2004-11-24 Kelley Cook <kcook@gcc.gnu.org>
778 * Makefile.am: Revert previous.
779 * acinclude.m4: Restore.
780 * aclocal.m4, configure, Makefile.in: Regenerate.
781 * testsuite/Makefile.in: Likewise.
783 2004-11-24 Kelley Cook <kcook@gcc.gnu.org>
785 * Makefile.am: Define ACLOCAL_AMFLAGS.
786 * acinclude.m4: Remove.
787 * aclocal.m4, configure, Makefile.in: Regenerate.
788 * testsuite/Makefile.in: Likewise.
790 2004-11-23 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
792 * testsuite/lib/libmudflap.exp: Use new procs in target-libpath.exp.
794 2004-11-23 Kelley Cook <kcook@gcc.gnu.org>
796 * Makefile.in, configure, aclocal.m4: Regenerate with automake 1.9.3.
797 * testsuite/Makefile.in: Likewise.
799 2004-11-01 Andreas Schwab <schwab@suse.de>
801 * configure.ac: (target_alias): Default to $host_alias, not
803 * configure: Regenerated.
805 2004-10-28 Frank Ch. Eigler <fche@redhat.com>
807 * testsuite/libmudflap.c/fail35-,pass53-,pass54-frag.c: New tests.
808 * testsuite/libmudflap.c/pass35-frag.c: Correct embedded warning
811 2004-10-25 Eric Botcazou <ebotcazou@libertysurf.fr>
814 * testsuite/lib/libmudflap.exp: Accept more than one multilib libgcc.
816 2004-10-12 Frank Ch. Eigler <fche@redhat.com>
818 * configure.ac: Check for more headers, functions.
819 * mf-hooks2.c (mkbuffer, unmkbuffer): New helper functions for
820 tracking overridden FILE buffers.
821 (fopen, setvbuf): New/revised hook functions for buffer overriding.
822 (setbuf,setlinebuf,fdopen,freopen,fopen64,freopen64,fclose): Ditto.
823 (fflush): Accept given NULL stream (means "all streams").
825 * mf-runtime.c (__mfu_check): Accept accesses that span adjacent
827 (LOOKUP_CACHE_SIZE_MAX): Raise to 64K entries tentatively.
828 (__mf_adapt_cache): Use them all.
829 * testsuite/libmudflap.c/pass35-frag.c: Update warning message.
830 * testsuite/libmudflap.c++/ctors.exp: Ditto.
831 * testsuite/libmudflap.c/{pass51,pass52}-frag.c: New tests.
832 * configure, config.h.in: Regenerated.
834 2004-10-05 Frank Ch. Eigler <fche@redhat.com>
836 * configure.ac: Checking for sys/socket.h once is enough.
837 * configure: Regenerated.
839 2004-10-04 Frank Ch. Eigler <fche@redhat.com>
841 * configure.ac: Look for more headers & functions.
842 * mf-hooks2.c (getmntent, inet_ntoa, getproto*): New wrapper functions.
843 * mf-runtime.h.in: Add new "#pragma redefine_extname"s for them.
844 * mf-runtime.c (options): Clean up integer signedness warnings.
845 (main): Add a declaration to fix a warning.
846 * mf-hooks3.c (pthread_exit): Add not-reached exit() to wrapper.
847 * configure, config.h.in: Regenerated.
849 2004-10-02 Frank Ch. Eigler <fche@redhat.com>
851 * testsuite/libmudflap.c/pass50-frag.c, fail33-frag.c, fail34-frag.c:
852 New tests for proper base/limit checking for aggregates.
854 2004-09-15 Joseph S. Myers <jsm@polyomino.org.uk>
856 * testsuite/libmudflap.c/pass35-frag.c: Update expected message.
858 2004-09-07 Frank Ch. Eigler <fche@redhat.com>
860 * configure.ac: Look for pwd.h, grp.h, netdb.h headers and functions.
861 * mf-hooks2.c (strerror): Unregister previous string returned by
863 (getlogin,cuserid,getpwnam,getpwuid,getgrnam,getgrgid): New wrappers.
864 (getservent,getservbyname,getservbyport,gai_strerror): Ditto.
865 * mf-runtime.h.in: Add redefine_extname pragmas for them all.
866 * mf-runtime.c (__mf_describe_object): Clarify object life status.
867 * testsuite/libmudflap.c/pass48-frag.c, pass49-frag.c, fail32-frag.c:
869 * configure, config.h.in: Regenerated.
871 2004-08-03 Dale Johannesen <dalej@apple.com>
873 * mf-runtime.c: Conditionalize POSIX_SOURCE for Darwin.
875 2004-08-03 Frank Ch. Eigler <fche@redhat.com>
877 * mf-runtime.c (compare_uintptr_t): Remove function. Inline
878 simplified contents in all former callers.
880 2004-07-27 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
882 * mf-runtime.c (__mf_fini): Set mudflap_mode to mode_nop in
883 the statically linked case.
885 2004-07-27 Frank Ch. Eigler <fche@redhat.com>
887 * splay-tree.[ch]: Remove. Merge contents into ...
888 * mf-runtime.c: ... here, renaming symbols and making all functions
889 static. Remove unused min/max functions.
890 * Makefile.am: Forget about splay-tree.[ch].
891 * Makefile.in, testsuite/Makefile.in: Regenerated.
893 2004-07-21 Frank Ch. Eigler <fche@redhat.com>
895 * mf-runtime.c (__mfu_check): Remove mistaken mode-nop handling.
896 (__mfu_usage): Include (C) 2004.
897 * mf-hooks3.c (__mf_find_threadinfo): Don't call tracing functions
898 here. Include a comment explaining why.
900 2004-07-20 Frank Ch. Eigler <fche@redhat.com>
902 * mf-impl.h (__mf_options): Add ignore_reads and timestamps fields.
903 * mf-runtime.c (options): Give them a name.
904 (__mf_set_default_options): Set them.
905 (__mf_insert_new_object, __mfu_unregister): Optionalize timestamps.
906 (__mf_violation): Warning cleanup.
907 * mf-impl.h (MF_VALIDATE_EXTENT): Support ignore_reads option.
908 * splay-tree.c (splay_tree_delete_helper): Remove obsolete decl.
910 2004-07-15 Frank Ch. Eigler <fche@redhat.com>
913 * mf-runtime.c (__mf_init): Make it non-static. Tolerate
916 2004-07-09 Frank Ch. Eigler <fche@redhat.com>
918 Test case for g++/15861
919 * testsuite/libmudflap.c++/ctors-[12].cxx: New test case halves.
920 * testsuite/libmudflap.c++/ctors.exp: Driver.
921 * testsuite/libmudflap.c++/c++frags.exp: Elide redundant default.
922 Look only for *frag* test cases.
924 2004-07-08 Frank Ch. Eigler <fche@redhat.com>
926 ANSI C conversion, libmudflap specialization, recursion limiting.
927 * splay-tree.h (splay_tree_{de,}allocate_fn): Remove allocation_data
928 argument and indirection function pointers, update callers.
929 (splay_tree_s): Add statistics and recursion control fields
930 num_keys, max_depth, depth, rebalance_p.
931 * splay-tree.c (splay_tree_splay_helper): Track recursion depth.
932 Back out of search if it exceeds limit.
933 (splay_tree_splay): Manage recursion limiting with rebalancing as
935 (splay_tree_new): More initialization.
936 (splay_tree_rebalance): New function.
937 (splay_tree_foreach): Rewrite using nonrecursive logic.
938 (splay_tree_xmalloc_allocate, splay_tree_xmalloc_deallocate):
939 Remove. Point indirect calls to mf-runtime.c's routines.
940 (splay_tree_compare_ints, splay_tree_compare_pointers): Remove unused
942 (splay_tree_delete, splay_tree_delete_helper): Ditto.
943 * testsuite/heap-scalestress.c: New test based on one from
944 Eyal Lebedinsky <eyal@eyal.emu.id.au>:
946 2004-07-05 Matthias Klose <doko@debian.org>
948 * libtool-version: New.
949 * Makefile.am (libmudflap_la_LDFLAGS, libmudflapth_la_LDFLAGS):
950 Use -version-info for soname.
951 * Makefile.in: Regenerate.
952 * configure.ac: Remove libtool_VERSION macro
953 * configure: Regenerate
955 2004-07-05 Zack Weinberg <zack@codesourcery.com>
957 * mf-runtime.h.in: Wrap declarations of struct __mf_cache,
958 __mf_lookup_cache, __mf_lc_mask, or __mf_lc_shift in
961 2004-06-29 Frank Ch. Eigler <fche@redhat.com>
963 Splay tree implementation fork.
964 * splay-tree.c, splay-tree.h: Copied & modified from libiberty.
965 Use hard-coded comparison function for uintptr_t. Remove key/value
966 deallocation logic. Cache last splayed key for consecutive lookups.
967 * Makefile.am, Makefile.in: Use them, don't link to them.
968 * mf-runtime.c (__mf_object_tree): Adapt to simpler splay_tree_new.
969 (__mf_find_objects2): Flip successor/predecessor search sequence.
970 * ansidecl.h, libiberty.h: Removed dummy files.
972 2004-06-29 Nick Clifton <nickc@redhat.com>
974 * configure.ac (AC_CHECK_HEADERS): Add dirent.h
975 * configure: Regenerate.
976 * mf-hooks2.c: Surround uses of dirent.h with #ifdef
978 Remove spurious inclusion of <strings.h>.
980 2004-06-29 Nick Clifton <nickc@redhat.com>
982 * mf-runtime.c (pthread_join): Only apply the weak pragma if the
983 function actually exists.
985 2004-06-25 Frank Ch. Eigler <fche@redhat.com>
987 * ansidecl.h, libiberty.h: New dummy files for building splay-tree.
988 * config.h.in: Regenerated.
990 2004-06-24 Frank Ch. Eigler <fche@redhat.com>
992 Adopt splay trees for object database.
993 * Makefile.am: Copy splay-tree.* from libiberty.
994 * Makefile.in, testsuite/Makefile.in: Regenerated.
995 * mf-runtime.h.in (__mf_unregister): Add third parameter (type).
996 * mf-hooks[123].c (*): Add new third parameter to mf_unregister.
997 * mf-impl.h (BEGIN_PROTECT): Remove some trace text.
998 * mf-runtime.c: Rewrite code dealing with object database to use
999 libiberty splay trees. Remove tree liveness aging option.
1000 * testsuite/libmudflap.c/fail18-frag.c: Add volatile flag.
1002 2004-06-15 Paolo Bonzini <bonzini@gnu.org>
1004 * configure.ac: New name of configure.in. Update
1005 AC_INIT, AC_CONFIG_SRCDIR, AC_CONFIG_HEADERS, AC_CONFIG_FILES,
1006 AC_OUTPUT, AM_INIT_AUTOMAKE to the preferred style for
1007 Autoconf 2.5x and Automake 1.7 or later.
1008 * configure.in: Remove.
1009 * configure: Regenerate.
1011 * Makefile.am: Remove useless multilib rules.
1012 * Makefile.in: Regenerate.
1014 2004-06-15 Paolo Bonzini <bonzini@gnu.org>
1016 * .cvsignore: New file.
1018 2004-06-10 Stephen Crowley <stephen.crowley@sbcglobal.net>
1021 * mf-hooks2.c (semctl): Add cygwin porting hack.
1023 2004-06-09 Frank Ch. Eigler <fche@redhat.com>
1026 * configure.in: Look for ctype header and glibc implementation.
1027 * mf-hooks2.c (__ctype_{b,toupper,tolower}_loc): Sample ctype
1028 array hooks for glibc 2.3.
1029 * mf-runtime.h.in: Wrap them.
1030 * mf-runtime.c (__mf_init): Leave marker regarding other ctype
1032 * testsuite/libmudflap.c/pass47-frag.c: New test.
1033 * configure, config.h.in: Regenerated.
1035 2004-06-04 Frank Ch. Eigler <fche@redhat.com>
1037 Portability improvements, e.g., libmudflap/15293.
1038 * configure.in: Look for glibc extension functions. Look for
1039 support of -f{function,data}-sections. Look for more headers.
1040 Create testsuite/mfconfig.exp. Correct more "test x.." thinkos.
1041 * Makefile.am: Use $(SECTION_FLAGS). Collapse piecemeal-compiled
1042 mf-hooks* into usual single object per source.
1043 * mf-hooks*.c: Remove all #if WRAP_foo conditionals.
1044 * mf-hooks2.c: #include a bunch more system headers. Define strnlen
1045 if system doesn't provide one.
1046 * mf-hooks3.c (struct pthread_info): Add stack_*_alloc fields.
1047 (pthread_create): Use it to properly GC dead thread stacks.
1048 * mf-runtime.c (__mf_violation): Correct snprintf type warning.
1049 * testsuite/Makefile.am: Stop generating site.exp.
1050 * testsuite/mfconfig.exp.in: New file.
1051 * testsuite/config/default.exp: Load new mfconfig.exp.
1052 * testsuite/lib/libmudflap.exp (libmudflap-init): Add extra libraries.
1053 (prune_gcc_output): Add glibc static linking warnings.
1054 * testsuite/libmudflap.*/*frags.exp: Enumerate needed -lmudflap* libs.
1055 * testsuite/libmudflap.c/pass46-frag.c: Ditto.
1056 * configure, Makefile, aclocal.m4, config.h.in, testsuite/Makefile.in:
1057 Regenerated with autoconf 2.57 and automake 1.7.
1059 2004-06-04 Per Bothner <per@bothner.com>
1061 * configure.in (LIBMUDFLAPTH): Fix thinko.
1063 * configure.in: Check for more headers.
1064 * mf-hooks2.c: Conditionalize on HAVE_SYS_SOCKET_H etc.
1066 * mf-runtime.c: In two places conditionalize on SIUSR1 rather than
1067 HAVE_SIGNAL as mingw has signal.h but not SIUSR1.
1069 2004-06-01 Andreas Jaeger <aj@suse.de>
1071 * configure.in: Handle multilibs, support
1072 --enable-version-specific-runtime-libs.
1073 * Makefile.am (lib_LTLIBRARIES): Rename to ...
1074 (toolexeclib_LTLIBRARIES): this for multilib support.
1075 * Makefile.in: Regenerated.
1076 * configure: Regenerated.
1077 * aclocal.m4: Regenerated.
1078 * config.h.in: Regenerated.
1079 * testsuite/Makefile.in: Regenerated.
1081 2004-06-01 Andreas Jaeger <aj@suse.de>
1083 * testsuite/lib/libmudflap.exp (libmudflap-init): Handle
1084 multilibs, using multilib directory instead of hardcoded path.
1087 2004-05-21 Frank Ch. Eigler <fche@redhat.com>
1089 * Makefile.am (AM_MAKEFLAGS): Pass RUNTESTFLAGS.
1090 * Makefile.in: Ditto.
1092 2004-05-18 Kaz Kojima <kkojima@gcc.gnu.org>
1094 * acinclude.m4 (lt_cv_deplibs_check_method): Use pass_all on sh*.
1095 * aclocal.m4, configure: Rebuilt.
1097 2004-05-17 Frank Ch. Eigler <fche@redhat.com>
1099 * lib/libmudflap.exp (libmudflap-init): For C++ test cases only,
1100 import some build settings from libstdc++-v3 testsuite_flags.
1101 * .../cfrags.exp, .../c++frags.exp, .../cthfrags.exp: Corresponding
1102 changes to pass test language.
1104 * mf-runtime.c (__mfu_check): Poison the cache with antidote for
1105 quicker mode-nop handling.
1107 2004-03-25 Frank Ch. Eigler <fche@redhat.com>
1109 * mf-impl.h: Added libgcc license header.
1111 2004-03-20 Frank Ch. Eigler <fche@redhat.com>
1113 * mf-hooks[123].c, mf-runtime.c, mf-heuristics.c:
1114 Added libgcc license header.
1115 * mf-hooks3.c (__mf_0fn_pthread_create): Correct arg constness.
1116 (pthread_create): Simplify stack allocation syntax.
1118 2004-03-08 Loren J. Rittle <ljrittle@acm.org>
1120 * mf-hooks2.c: Support FreeBSD.
1121 (WRAP_gets): Avoid gets().
1122 * testsuite/libmudflap.c/pass-stratcliff.c: Do not
1123 test unimplemented mem/str calls on FreeBSD.
1124 * testsuite/libmudflap.c/pass21-frag.c: Do not include
1125 <alloca.h> on FreeBSD.
1127 2004-01-30 Frank Ch. Eigler <fche@redhat.com>
1129 * testsuite/libmudflap.c/pass36-frag.c: Add missing free() call.
1130 * testsuite/libmudflap.c/pass46-frag.c: New test for -fmudflapir.
1131 * testsuite/libmudflap.cth/cthfrags.exp: Add -DSTATIC to compiler
1132 flags for static linking permutation.
1133 * testsuite/libmudflap.cth/pass40-frag.c: When -DSTATIC, avoid
1134 some pthreads code that croaks on linux glibc tls.
1136 2004-01-27 Frank Ch. Eigler <fche@redhat.com>
1138 * testsuite/libmudflap.c/fail31-frag.c, pass45-frag.c: New tests.
1140 2004-01-15 Frank Ch. Eigler <fche@redhat.com>
1142 * testsuite/libmudflap.c/pass44-frag.c: New test.
1144 2004-01-12 Frank Ch. Eigler <fche@redhat.com>
1146 * testsuite/libmudflap.c/fail{28,29,30}-frag.c: New tests.
1148 2004-01-08 Frank Ch. Eigler <fche@redhat.com>
1150 * testsuite/libmudflap.c/pass43-frag.c: Added missing program rc.
1152 2003-12-11 Frank Ch. Eigler <fche@redhat.com>
1154 * testsuite/libmudflap.c/pass42-frag.c, pass43-frag.c: New tests.
1156 2003-12-08 Andrew Pinski <pinskia@physics.uc.edu>
1159 * configure.in: Add check for see if
1160 socklen_t typedef is in sys/socket.h.
1161 * mf-hooks1.c: Add define if socklen_t
1163 * mf-hooks2.c: Likewise.
1164 * mf-hooks3.c: Likewise.
1165 * config.h.in: Regen.
1168 2003-12-08 Frank Ch. Eigler <fche@redhat.com>
1170 * mf-runtime.c (__mf_watch_or_not): Tweak tracing message.
1171 * testsuite/libmudflap.c/fail21-frag.c: Defeat aliasing
1173 * testsuite/libmudflap.c/pass25-frag.c: Ditto.
1174 * testsuite/libmudflap.c/pass26-frag.c: Tolerate non-overlapping
1175 (unoptimized) allocation of stack space.
1177 2003-12-07 Richard Henderson <rth@redhat.com>
1179 * testsuite/libmudflap.c/fail23-frag.c (main): Adjust addend to 11.
1180 * testsuite/libmudflap.c/fail27-frag.c (foo): Mark noinline.
1182 2003-12-06 Andrew Pinski <apinski@apple.com>
1184 partial PR libmudflap/12670
1185 * mf-hooks1.c: Respect Darwin checks. Conditionalize POSIX_SOURCE.
1186 * mf-hooks2.c: Likewise.
1187 * mf-hooks3.c: Likewise.
1189 2003-11-19 Frank Ch. Eigler <fche@redhat.com>
1192 * mf-runtime.h.in: Switch to #pragma redefine_extname for
1193 symbols interposed at compile time.
1194 * testsuite/libmudflap.c++/pass41-frag.cxx: New test.
1197 * mf-hooks2.c (semctl): Tolerate FreeBSD.
1199 * configure.in: Reorganize check for <pthread.h>.
1200 * configure: Regenerated.
1202 2003-11-04 David Edelsohn <edelsohn@gnu.org>
1204 * mf-runtime.c (_ALL_SOURCE): Define for AIX.
1205 (_LARGE_FILE_API): Define for AIX.
1206 * mf-hooks[123]: Same.
1207 (_XOPEN_SOURCE_EXTENDED): Define to 1 for AIX.
1209 2003-10-21 David Edelsohn <edelsohn@gnu.org>
1211 * mf-runtime.c (_XOPEN_SOURCE_EXTENDED): Define to 1 for AIX.
1213 2003-07-29 Frank Ch. Eigler <fche@redhat.com>
1215 2003-07-29 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
1217 * configure.in: Update check for union semun.
1219 2003-07-29 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
1222 * mf-hooks2.c [WRAP_semctl]: Fix check for HAVE_UNION_SEMUN.
1224 2003-07-29 Frank Ch. Eigler <fche@redhat.com>
1227 * configure.in: Add checks for 64-bit LFS functions, struct semun
1228 definition, for BSD compatibility.
1229 * mf-hooks1.c: Respect BSD checks. Conditionalize POSIX_SOURCE.
1230 * mf-hooks2.c: Ditto. Include <strings.h> for bcmp* decls.
1231 * mf-hooks3.c: Ditto.
1232 (pthread_create): Try MAP_ANON on platforms without the MAP_ANONYMOUS
1234 * configure, config.h.in: Regenerated.
1236 2003-07-23 Frank Ch. Eigler <fche@redhat.com>
1238 Multithreading fixes:
1239 * mf-runtime.c (__mf_object): Store allocating/deallocating
1241 (options): Support new "-thread-stack" option.
1242 Rename "-heur-argv-environ" option to "-heur-stdlib".
1243 Disable "-lc-mask" and "-lc-shift" options.
1244 (__mf_dynamic): Add function pointers for pthread_join/_exit.
1245 (__assert_fail): New self-contained function for glibc.
1246 * mf-hooks3.c: Essentially rewritten, particularly related to
1247 use of __mf_pthread_info array.
1248 (pthread_join, _exit): New hook functions.
1249 * mf-impl.h (BEGIN_PROTECT): Handle starting_p case.
1250 * testsuite/libmudflap.cth/pass40-frag.c: New test.
1253 * mf-heuristics.c: Add type casts for tracing, sub calls.
1254 * mf-impl.h (BEGIN_PROTECT): Redefine to omit result type.
1255 Update all callers to declare explicit result holder.
1256 (END_PROTECT): Removed.
1257 * testsuite/*/*frags.exp: Clean up default MUDFLAP_OPTIONS.
1259 2003-07-15 Diego Novillo <dnovillo@redhat.com>
1261 * testsuite/libmudflap.c/fail21-frag.c: Add volatile modifiers.
1262 * testsuite/libmudflap.c/fail15-frag.c: Likewise.
1263 * testsuite/libmudflap.c/fail13-frag.c: Likewise.
1265 2003-07-04 Frank Ch. Eigler <fche@redhat.com>
1267 * mf-hooks1.c, 2.c, 3.c: New file, splits up content from old ...
1268 * mf-hooks: Removed.
1269 * mf-impl.h (MF_VALIDATE_EXTENT, BEGIN_PROTECT, END_PROTECT):
1270 Move these macros from old mf-hooks.c here.
1271 * Makefile.am: Adapt to split-up hook sources for faster builds.
1272 * Makefile.in: Regenerated.
1274 * mf-heuristics.c: Remove #if-0 block.
1276 * mf-impl.h (__mf_state): Reorganize declaration and implementation.
1277 (__mf_starting_p): New state only for use while dlsym bootstrapping.
1278 (CALL_REAL, __mf_init): Corresponding changes.
1279 (TRACE, VERBOSE_TRACE): Include thread id and "mf:" prefix. Update
1280 all callers to remove redundant "mf:" prefix.
1281 * mf-runtime.h.in: #define a few reentrancy macros for libmudflapth.
1282 * mf-hooks3.c: Rewrite chunks to support per-thread __mf_state value.
1283 (__mf_pthread_info): Become a hash table.
1285 * testsuite/lib/mfdg.exp: Support new "dg-timeout" and
1286 "dg-repetitions" directives to control test case execution.
1287 * testsuite/libmudflap.cth/pass37-frag.c: Add timeout and repeat
1289 * testsuite/libmudflap.cth/pass39-frag.c: Ditto for this new test.
1291 2003-06-25 Frank Ch. Eigler <fche@redhat.com>
1293 * mf-hooks.c (alloca): Separate into stub.
1294 (__mf_wrap_alloca_indirect): New function. Use CALL_REAL
1295 malloc/free for alloca blocks.
1296 (pthread_create): Tolerate failing pthread_attr_get* calls.
1297 * mf-runtime.c (__mf_fini): Call __mf_wrap_alloca_indirect.
1298 * mf-impl.h (CALL_WRAP): Remove macro.
1299 * testsuite/libmudflap.c/pass21-frag.c: Include <alloca.h>.
1300 * testsuite/libmudflap.c/pass23-frag.c: Include more struct
1301 padding for ia64 BIT_FIELD_REF constructs.
1303 2003-06-19 Frank Ch. Eigler <fche@redhat.com>
1305 * mf-hooks.c (struct pthread_info): Add "thread_errno" field.
1306 (__mf_pthread_spawner, __mf_pthread_cleanup): Use it with GUESS
1307 libmudflap object type.
1308 * mf-runtime.c (__mfu_unregister): Correct cemetary logic to avoid
1309 crashes on unregistering STATIC objects.
1311 2003-06-17 Frank Ch. Eigler <fche@redhat.com>
1313 Based on patch from Eyal Lebedinsky <eyal@eyal.emu.id.au>:
1314 * mf-hooks.c (__mf_pthread_spawner): Register thread errno.
1315 (time, strerror, fopen, fopen64, fclose, fread): New hooks.
1316 (fwrite, fgetc, fgets, getc, gets, ungetc, fputc): New hooks.
1317 (fputs, putc, puts, clearerr, feof, ferror, fileno): New hooks.
1318 (printf, fprintf, sprintf, snprintf, vprintf, vfprintf): New hooks.
1319 (vsprintf, vsnprintf, access, remove, fflush, fseek): New hooks.
1320 (fseeko64, ftell, ftello64, rewind, fgetpos, fsetpos): New hooks.
1321 (stat, stat64, fstat, lstat, mkfifo, setvbuf, setbuf): New hooks.
1322 (setvbuf, opendir, closedir, readdir, recv, recvfrom): New hooks.
1323 (recvmsg, send, sendto, sendmsg, setsockopt, getsockopt): New hooks.
1324 (accept, bind, connect, gethostname, sethostname): New hooks.
1325 (gethostbyname, wait, waitpid, popen, pclose, execve): New hooks.
1326 (execv, execvp, system, dlopen, dlclose, dlerror, dlsym): New hooks.
1327 (semop, semctl, shmctl, shmat, shmdt): New hooks.
1328 * mf-runtime.h.in: Corresponding changes.
1329 * mf-runtime.c (__mf_ini): Register stdio objects. Use STATIC type.
1330 (opts) Rename heur_argv_environ to heur_std_data.
1331 (__mf_wrap_main): Use STATIC type for argv/environ strings.
1332 * Makefile.am: Corresponding changes.
1333 * Makefile.in: Regenerated.
1335 2003-06-11 Frank Ch. Eigler <fche@redhat.com>
1337 * mf-heuristics.c (__mf_heuristic_check): Disable stack_bounds
1338 heuristic for threaded case, and for non-x86-linux targets.
1339 * mf-hooks.c (__mf_0fn_calloc): Provide a working dummy implementation
1340 for use during pre-main() program startup.
1341 (__mf_0fn_*): Make these functions non-static.
1342 * mf-impl.h (DECLARE, CALL_REAL): Support calls to 0fn backup hook
1344 * mf-runtime.c (__mf_state): Set initial state to "starting".
1345 (__mf_resolve_single_dynamic): Tolerate repeated calls for same symbol.
1346 (__wrap_main): New function to register argv[] and environ[] strings.
1347 (__mf_ini): Call it.
1348 (*): In all trace functions, use "%p" as formatter for uintptr_t.
1350 * testsuite/libmudflap.c/pass38-frag.c: New test case.
1351 * testsuite/libmudflap.cth/pass37-frag.c: Improved test.
1353 * acinclude.m4: Add comments with aoliva's concerns about x86_64
1355 * aclocal.m4, configure: Regenerated.
1357 2003-06-04 Frank Ch. Eigler <fche@redhat.com>
1359 * acinclude.m4: Correct typo in AC_MSG_CHECKING.
1360 * aclocal.m4, configure: Regenerated.
1362 2003-06-03 Frank Ch. Eigler <fche@redhat.com>
1364 * acinclude.m4: Force "pass_all" deplibs_check_method for libtool
1365 for x86_64 target. Disable caching for this value.
1366 * aclocal.m4, configure: Regenerated.
1368 2003-06-02 Frank Ch. Eigler <fche@redhat.com>
1370 * testsuite/libmudflap.c/pass38-frag.c: Deleted. -fwritable-strings
1371 is about to become deprecated, and its present handling bugs are
1374 2003-05-30 Frank Ch. Eigler <fche@redhat.com>
1376 * testsuite/libmudflap.c/pass38-frag.c: New test for
1379 2003-05-23 Frank Ch. Eigler <fche@redhat.com>
1381 * mf-runtime.c (__mf_sigusr1_handle): Call unlocked variant of
1382 __mf_report, asserting reentrant calling context.
1384 2003-05-23 Frank Ch. Eigler <fche@redhat.com>
1386 * mf-hooks.c (realloc): Correct reentrancy logic.
1387 * testsuite/libmudflap.c/hook-allocstuff.c: New test case.
1389 2003-05-20 Frank Ch. Eigler <fche@redhat.com>
1391 * mf-hooks.c (LIBMUDFLAPTH_THREADS_MAX): New macro, replaces
1392 PTHREAD_THREADS_MAX. Update users.
1393 * mf-runtime.c (__mf_usage): Print [active] instead of [default]
1395 * testsuite/Makefile.am (all-local): Prime dejagnu site.exp file
1396 with libmudflapth presence indicator.
1397 * testsuite/Makefile.in: Regenerated.
1399 2003-05-16 Frank Ch. Eigler <fche@redhat.com>
1401 * Makefile.am (AM_CFLAGS): Remove "-ansi".
1402 * configure.in: Remove silly no-pthreads => no-shared logic.
1403 * Makefile.in, configure: Regenerated.
1404 * mf-heuristics.c (__mf_heuristic_check): Remove reentrancy hacks.
1405 * mf-hooks.c (BEGIN_PROTECT, END_PROTECT): Reorganize reentrancy
1406 code. Count reentrancy events.
1407 (all hook functions): Don't directly manipulate __mf_state variable.
1408 Add TRACE calls to hook functions without them.
1409 * mf-impl.h (LOCKTH): Try to count lock contention events.
1410 (VERBOSE_TRACE, TRACE): Remove reentrancy hacks.
1411 * mf-runtime.c (BEGIN_RECURSION_PROTECT, END_RECURSION_PROTECT):
1412 Reorganize reentrancy code.
1413 (external __mf_ entry points): Use RECURSION_PROTECT mechanism to
1414 identify reentrancy with mutex holding times.
1415 (internal __mfu_ entry points): Remove internal reentrancy code.
1416 (__mf_init): Use ordinary locked calls.
1417 (__mfu_report): Print the two new counts.
1418 * testsuite/lib/libmudflap.exp: Filter out junk ld/pthreads messages.
1419 * testsuite/libmudfap.cth/cthfrags.exp: New test driver.
1420 * testsuite/libmudflap.cth/pass37-frag.c: New pthreads test.
1421 * testsuite/libmudfap.cth/cfrags.exp: Adapt to new libmudflap
1424 2003-05-09 Frank Ch. Eigler <fche@redhat.com>
1426 * configure.in: Add pthread support, plus glibc and porting hacks.
1427 * Makefile.am (LIBMUDFLAPTH): New conditional, to build -lmudflapth
1428 from objects built into ./pth/.
1429 * mf-runtime.c (__mfu_watch,register,...): Fork new unlocked
1430 functions for internal entry points. Update callers to pick
1431 locked vs. unlocked variants.
1432 (__mf_resolve_single_dynamic): Extend to support symbol versioning
1433 info coming in from a static data structure.
1434 (*): Reorder miscellaneous declarations to group data vs functions.
1435 (__mf_set_default_options): Simplify.
1436 (__mf_usage): Mention threading status of host executable.
1437 * mf-impl.h: Move max/min decls here. Reorganize __mf_dynamic
1438 decls to match above.
1439 (LOCKTH, UNLOCKTH): New macros for Big Libmudflap Lock management.
1440 * mf-heuristics.c: Choose between locked/unlocked calls. Add
1441 some lock/unlock markers. Remove some unused code.
1443 (pthread_create): New hook function.
1444 (__mf_pthread_cleanup, _spawner): New helper functions.
1445 * configure. aclocal.m4, config.h.in, Makefile.in: Regenerated.
1447 2003-05-02 Frank Ch. Eigler <fche@redhat.com>
1449 * testsuite/libmudflap.c/fail27-frag.c: Add more volatile flags.
1451 2002-04-28 Frank Ch. Eigler <fche@redhat.com>
1453 * Makefile.am (HOOKOBJS): Add *time related hooks.
1454 * configure.in: Look for pthreads.h header.
1455 * mf-hooks.c (asctime, ctime, gmtime, localtime): New wrappers.
1456 * mf-runtime.c: Begin sketching some pthreads support.
1457 (__mf_usage): Check for -lpthread presence.
1458 (__mf_unregister): Confirm matching unregistration base.
1459 (__mf_find_objects_rec): Reduce unnecessary recursion.
1460 * mf-runtime.h.in: Add "nothrow" attribute to functions. Add
1461 #defines for new hook functions.
1462 * mf-impl.h: Corresponding changes.
1463 * config.h.in, configure, Makefile.in: Regenerated.
1465 2002-04-27 Diego Novillo <dnovillo@redhat.com>
1467 * testsuite/libmudflap.c/fail1-frag.c: Add volatile
1468 modifiers to prevent being optimized away.
1469 * testsuite/libmudflap.c/fail10-frag.c: Likewise.
1470 * testsuite/libmudflap.c/fail13-frag.c: Likewise.
1471 * testsuite/libmudflap.c/fail14-frag.c: Likewise.
1472 * testsuite/libmudflap.c/fail15-frag.c: Likewise.
1473 * testsuite/libmudflap.c/fail2-frag.c: Likewise.
1474 * testsuite/libmudflap.c/fail20-frag.c: Likewise.
1475 * testsuite/libmudflap.c/fail3-frag.c: Likewise.
1477 2003-04-15 Frank Ch. Eigler <fche@redhat.com>
1479 * Makefile.am (libmudflap_la_LIBADD): Remove -ldl.
1480 * configure.in: Look for uintptr_t and -ldl on target.
1481 * mf-runtime.h.in: Adjust uintptr_t declaration logic.
1482 * Makefile.in, aclocal.m4, configure, config.h.in: Regenerated.
1483 * testsuite/Makefile.in: Regenerated.
1484 * mf-runtime.c (__mf_sigusr1_respond): Tweak declaration and calls
1485 for better C compliance.
1487 2003-04-15 Frank Ch. Eigler <fche@redhat.com>
1489 * mf-hooks.c (MF_VALIDATE_EXTENT): Remove unnecessary reentrancy
1491 * mf-runtime.c (__mf_set_default_options): Turn off
1492 check-initialization.
1493 (__mf_describe_object): Shorten description.
1494 * testsuite/libmudflap.c/fail25-frag.c: Turn on check-initialization.
1496 2003-04-07 Frank Ch. Eigler <fche@redhat.com>
1498 * mf-hooks.c (__mf_0fn_mmap): Correct return value, as per <rth>.
1500 2003-04-02 Frank Ch. Eigler <fche@redhat.com>
1502 * mf-hooks.c (BEGIN_PROTECT): Handle startup-time reentrant
1504 (__mf_0fn_malloc ... _munmap): New dummy backup calls.
1505 * mf-impl.h (CALL_BACKUP): New macros.
1506 * mf-runtime.c (__mf_init): Tweak __mf_state during startup.
1508 2003-03-31 Frank Ch. Eigler <fche@redhat.com>
1510 * Makefile.am (AM_CFLAGS): Remove optimization flags.
1511 (HOOKOBJS): Remove dlopen hook.
1512 (libmudflap_la_LIBADD): Add -ldl.
1513 * mf-hooks.c (dlopen): Remove hook.
1514 * mf-impl.h (__mf_dynamic): Ditto.
1515 * mf-runtime.c (__mf_resolve_dynamics): Ditto.
1516 * Makefile.in: Regenerated.
1518 2003-03-28 Frank Ch. Eigler <fche@redhat.com>
1520 * configure.in: Check for target gettimeofday, signal, some headers.
1521 * mf-impl.h (__mf_opts): Add new "sigusr1_report" field. Comment
1522 out inop multi_threaded field.
1523 * mf-runtime.c (options): Handle new "-sigusr1-report" option.
1524 (__mf_set_options): Correct handling of "-help".
1525 (__mf_sigusr1_respond): New function to manage SIGUSR1 response.
1526 (__mf_check, __mf_register, __mf_unregister): Call it.
1527 (__mf_insert_new_object, __mf_unregister): Respect HAVE_GETTIMEOFDAY.
1528 (__mf_report_leaks): Make callable
1529 (__mf_tree_analyze): Traverse in-order. Accumulate address bit
1530 distribution statistics.
1531 (__mf_adapt_cache): Rewrite shift guessing logic based on address
1533 * config.h.in, configure: Regenerated.
1534 * testsuite/libmudflap.c/fail27-frag.c: New test.
1535 * testsuite/libmudflap.c/pass36-frag.c: New test.
1537 2003-03-11 Frank Ch. Eigler <fche@redhat.com>
1539 * mf-runtime.h.in: Tweak.
1540 * Makefile.am, configure.in: Tweak mf-runtime.h generation some more.
1541 Don't use intermediate files nor AC_OUTPUT-time postprocessing.
1542 * Makefile.in, testsuite/Makefile.in, configure: Regenerated.
1544 2003-03-10 Frank Ch. Eigler <fche@redhat.com>
1546 * configure.in: Tweak generation of mf-runtime.h some more. It
1547 needs to work from both config.status and configure.
1548 * configure: Regenerated.
1550 2003-03-10 Frank Ch. Eigler <fche@redhat.com>
1552 * Makefile.am: Reorganize hook file building. Add auto dependencies.
1553 * configure.in: Tweak generation of mf-runtime.h.
1554 * mf-runtime.h.in: Add new __MF_TYPE_HEAP_I.
1555 * mf-hooks.c (*): Adapt to initialized-heap object type.
1556 * mf-impl.h: Tweak cemetary boundaries.
1557 * mf-runtime.c (__mf_check): Adapt to new initialized-heap object
1559 (__mf_insert_new_object, __mf_register, __mf_unregister): Ditto.
1560 (__mf_describe_object, __mf_report_leaks, __mf_violation): Ditto.
1561 * testsuite/lib/libmudflap.exp (includes): Include build tree.
1562 * testsuite/libmudflap.c/pass{26,5}: Further adapt to initialization
1564 * testsuite/.../fail{25,26}-frag.c: New tests.
1565 * testsuite/.../pass{32,33,34,35}-frag.c: New tests.
1566 * Makefile.in, configure: Regenerated.
1568 2003-03-05 Frank Ch. Eigler <fche@redhat.com>
1570 * mf-runtime.c (__mf_set_default_options): Turn on initialization
1571 checking by default.
1572 (__mf_insert_new_object): As a temporary hack, assume that new
1573 objects registered on the stack start out initialized.
1574 * testsuite/libmudflap.c/fail9,pass23,pass[6789]-*: Initialize
1575 heap objects by hand.
1577 2003-03-05 Frank Ch. Eigler <fche@redhat.com>
1579 Switch to macro-style hooks for str*/mem*/b* functions.
1580 * mf-runtime.h.in (__MF_TYPE_*): Moved some internal values out.
1581 (mem*, str*, b*): Added macro-style hooks for _MUDFLAP case.
1582 * mf-runtime.c: #include config.h to enable glibc backtraces again.
1583 (__mf_set_default_options): Turn off heur_proc_map.
1584 (*): Adapt to to macro-style hook functions.
1585 (__mf_object_dead_head, __mf_object_cemetary): Correct bounds.
1586 (__mf_check, __mf_register, __mf_unregister): Tweak tracing message.
1587 (__mf_violation): Handle __MF_VIOL_WATCH.
1588 * mf-impl.h (__MF_TYPE_*): Moved these internal values here.
1589 (__mf_dynamic): Removed mem*/str*/b* functions.
1590 (TRACE, VERBOSE_TRACE): Add reentrancy locking.
1591 (WRAPPER2): New macro for macro-style hooks.
1592 * mf-hooks.c: Convert mem*/str*/b* functions to simpler
1594 (BEGIN_PROTECT): Tweak tracing vs reentrancy-lock ordering.
1595 * mf-heuristics.c: Adapt to macro-style hook functions.
1596 Correct some comments.
1597 * testsuite/lib/mfdg.exp (dg-test): Simplify result string for
1598 output pattern tests.
1599 * testsuite/libmudflap.c/fail[89]-frag.c: Elaborate output test.
1600 * testsuite/libmudflap.c++/c++frags.exp: Enable non-static tests.
1602 2003-02-28 Frank Ch. Eigler <fche@redhat.com>
1604 * testsuite/libmudflap.c/fail23-frag.c, pass30-frag.c: New tests
1605 for global array registration.
1606 * testsuite/libmudflap.c++/fail24-frag.cxx, pass31-frag.cxx: Ditto.
1607 * testsuite/libmudflap.c++/c++frags.exp: Tweak -static multilib hack.
1609 2003-02-27 Frank Ch. Eigler <fche@redhat.com>
1611 * Makefile.am: Add gross make bug workarounds. Tweaked
1612 SUBDIRS and AM_CFLAGS.
1613 * Makefile.in: Regenerated.
1615 2003-02-26 Frank Ch. Eigler <fche@redhat.com>
1618 * configure.in (AC_PROG_CXX): Don't look for C++ any more.
1619 * Makefile.am (TESTS): Remove simple automake testing.
1620 * configure, Makefile.in: Regenerated.
1621 (SUBDIRS): Include new testsuite/ directory.
1622 * tests/*: Removed all files; moved bulk under:
1623 * testsuite/*: New subdirectory tree.
1624 * testsuite/libmudflap.c/cfrags.exp: New file, C test driver.
1625 * testsuite/libmudflap.c++/c++frags.exp: New file, C++ test driver.
1626 * testsuite/lib/libmudflap.exp: New file, derived from libstdc++.
1627 * testsuite/lib/mfdg.exp: New file, derived from dejagnu.
1628 * testsuite/config/default.exp: New file.
1629 * testsuite/Makefile.am, Makefile.in: New files.
1631 2003-01-29 Frank Ch. Eigler <fche@redhat.com>
1633 * Makefile.am (TESTS_ENVIRONMENT): Remove redundant "-mode-check".
1634 (TESTS): Add fail22 and pass29 tests.
1635 * mf-runtime.h.in: Change API to take void*/size_t region parameters.
1636 Add new access-type parameter for __mf_check. Move __MF_VIOL* out.
1637 * mf-impl.h: Corresponding changes. Update CLAMP* macros for void*
1638 values. Move __MF_VIOL* here.
1639 * mf-runtime.c (*): Adapt to void*/size_t API in mf-runtime.h.
1640 (check_initialization): New field in __mf_opts. Default off.
1641 (read_count,write_count): New fields in __mf_object.
1642 (__mf_check): Implement basic initialization checking.
1643 (__mf_insert_new_object): Assume STATIC|GUESS regions are initialized.
1644 (__mf_describe_object): Print new fields.
1645 (__mf_violation): Identify check/read vs. check/write in messages.
1646 * test/pass29-frag.c, test/fail22-frag.c: Basic tests for new
1647 "-check-initialized" mudflap option.
1648 * test/pass25-frag.c, test/fail21-frag.c: Adapt to API changes.
1649 * mf-hooks.c (MF_VALIDATE_EXTENT): Add new access-type parameter.
1650 Drop __FILE__/__LINE__ hack. Update callers.
1651 (*): Adapt to new mf-runtime.h API.
1652 * Makefile.in: regenerated.
1654 2003-01-24 Frank Ch. Eigler <fche@redhat.com>
1656 * configure.in: Build mf-runtime.h a more proper way.
1657 * mf-hooks.c (strdup, strndup): Correct reentrancy logic.
1658 * mf-runtime.c (verbose_violations): Turn on by default.
1659 * mf-runtime.h.in: Remove some miscellaneous stuff ...
1660 * mf-impl.h: ... and move it here.
1661 * configure: Regenerated.
1663 2003-01-22 Frank Ch. Eigler <fche@redhat.com>
1665 * configure.in: Look for C++ compiler.
1666 * test/*-frag.c, mf-driver.c: Reformatted with GNU indent and
1667 fixed type warnings when built with C++.
1668 * test/pass27-frag.cxx, pass28-frag.cxx: New C++ tests.
1669 * Makefile.am (TESTS): Run them.
1670 (*) Add new rules for building and running C++ tests.
1671 (TESTFLAGS): Set new default to avoid libstdc++-v3 shlib issues.
1672 * mf-runtime.h.in: Protect with extern "C".
1673 * Makefile, configure: Regenerated.
1675 2003-01-06 Frank Ch. Eigler <fche@redhat.com>
1677 Portability improvements.
1678 * configure.in: Look for glibc backtrace headers/functions.
1679 * mf-hooks.c: Don't include <execinfo.h> any more.
1680 * mf-runtime.c (__mf_set_options): Call more stdlib functions
1682 (__mf_backtrace): Provide alternate baby implementation in
1684 * test/mf-driver.c: Portability tweaks.
1685 * acinclude.m4: New file, containing top level libtool.m4.
1686 * aclocal.m4, configure, Makefile.in, config.h.in: Regenerated.
1688 2002-12-19 Frank Ch. Eigler <fche@redhat.com>
1690 * mf-runtime.h.in (HAVE_UINTPTR_T): Define unconditionally.
1692 2002-11-08 Frank Ch. Eigler <fche@redhat.com>
1694 * mf-runtime.c (options): Add new "wipe-heap", "wipe-stack"
1696 (__mf_unregister): Implement stack/heap object wiping.
1697 (__mf_set_options): Renamed from __mf_process_opts.
1698 (__mf_uncache_object): Change arg type, correct callers.
1699 * mf-impl.h: Corresponding changes.
1700 * mf-hooks.c (realloc): Save/restore heap-wiping flag.
1701 * mf-runtime.h.in (__mf_set_options): Extend public API.
1702 * test/pass26-frag.c: New test for stack wiping.
1703 * Makefile.am (TESTS): Run it.
1704 * Makefile.in: Regenerated.
1706 2002-11-07 Frank Ch. Eigler <fche@redhat.com>
1708 * mf-runtime.h.in (__mf_watch, __mf_unwatch): Extend public API.
1709 * mf-runtime.c (__mf_object_t): Add watching_p field.
1710 (__mf_watch_or_not): New function to implement
1711 object watch flagging.
1712 (__mf_watch, __mf_unwatch): New wrappers for above.
1713 (__mf_check, __mf_describe_object): Handle objects with watching_p.
1714 (__mf_count_violation): Enlarge array.
1715 (__mf_uncache_object): Renamed from __mf_remove_old_object. Don't
1716 unlink object. Clear cache properly.
1717 (__mf_unregister): Unlink object explicitly before uncaching.
1718 * test/fail21-frag.c, pass25-frag.c: New tests.
1719 * Makefile.in, aclocal.m4: Regenerated.
1721 2002-11-05 Frank Ch. Eigler <fche@redhat.com>
1723 * test/fail20-frag.c: New test for NULL pointer dereferencing.
1724 * Makefile.am (TESTS): Add it.
1725 * test/pass-stratcliff.c: Add decls of stpcpy.
1726 * configure.in: Test for <stdint.h>. Generate mf-runtime.h in
1727 build tree from config.h and new file mf-runtime.h.in.
1728 * mf-runtime.h.in: Renamed from mf-runtime.h. Tweak uintptr_t decl.
1729 * Makefile.in, configure, config.h.in: Regenerated.
1730 * mf-hooks.c: Add #undef for wrapped glibc str*/mem* macros.
1731 * mf-runtime.c (options, __mf_set_default_options): Support new
1732 default "abbreviate" option.
1733 (__mf_object.description_epoch): New field.
1734 (__mf_describe_object): Conditionally abbreviate objects already
1735 displayed in current epoch. Accept NULL input to increment epoch.
1736 (__mf_fini, __mf_ini): Reset description epoch.
1737 (__mf_register, __mf_unregister, __mf_adapt_cache, __mf_init): Ensure
1738 that NULL pointer slot in lookup cache is invalidated. Register a
1739 NOACCESS region around NULL.
1740 * mf-impl.h: Corresponding changes.
1742 2002-10-16 Frank Ch. Eigler <fche@redhat.com>
1744 * test/fail19-frag.c, pass24-frag.c, pass-stratcliff.c: New tests.
1745 * Makefile.am: Run them. Install mf-runtime.h.
1746 * Makefile.in: Regenerated.
1747 * mf-hooks.c: Add some markers for more missing functions.
1748 * mf-runtime.c (__mf_adapt_cache): Experiment with a utilization-based
1749 statistic to tune tune cache size (mask).
1751 2002-10-01 Frank Ch. Eigler <fche@redhat.com>
1753 * test/pass23-frag.c: New test for bit_field_ref expressions.
1754 * Makefile.am, Makefile.in: Add new test.
1755 * mf-hooks.c (mmap, munmap): Rewrite to track individual pages.
1756 (MF_VALIDATE_EXTENT): Accept zero-size mem/str operations.
1757 * mf-runtime.c (__mf_init): Register errno global.
1758 (__mf_find_object): Removed function.
1759 (__mf_check): Rewrite logic to support accesses across some
1760 contiguous but distinctly registered objects.
1761 (__mf_remove_old_object): Tolerate cache entries that span
1764 2002-09-30 Frank Ch. Eigler <fche@redhat.com>
1766 * test/pass21-frag.c, pass22-frag.c: New tests: alloca, bitfields.
1767 * Makefile.am, Makefile.in: Run new tests.
1768 * mf-hooks.c (alloca): Correct stack direction logic.
1770 2002-09-26 Frank Ch. Eigler <fche@redhat.com>
1772 * mf-impl.h (adapt_cache): New option.
1773 * mf-runtime.c (__mf_set_default_options): Set its default value.
1774 Tweak the tree_aging parameter down.
1775 (__mf_check): Maintain separate counter for cache-adaptation.
1776 (__mf_tree_analyze): New function to collect object tree stats.
1777 (__mf_adapt_cache): New function to automate cache parameters.
1779 2002-09-24 Frank Ch. Eigler <fche@redhat.com>
1781 * mf-heuristics.c (__init_misc, __mf_heuristic_check): Add
1782 hypothetical #if-0'd argv/envp region registration.
1783 * mf-runtime.c (__mf_init): Add kludged form of above.
1784 (*) Add "heur_argv_environ" flag, default on, to govern this.
1785 * mf-impl.h: Corresponding changes.
1787 2002-09-20 Frank Ch. Eigler <fche@redhat.com>
1789 * test/fail18-frag.c: New test file for NOACCESS regions.
1790 * Makefile.am (TESTS): Add new test.
1791 * Makefile.in: Regenerated.
1793 * mf-heuristics.c (__mf_heuristics_check): Correct deja_vu logic.
1794 * mf-impl.h (tree_aging): Add new mudflap_option, default 1000000.
1795 (optimize_object_tree): Remove unused mudflap_option.
1796 * mf-runtime.h (__MF_TYPE_NOACCESS): New region type. Add printing
1797 support throughout. Use .._MAX_CEM for cemetary upper bound.
1798 * mf-runtime.c (__mf_init): Register __mf_* globals as NOACCESS
1800 (__mf_object): Add new liveness field for use by tree aging.
1801 (__mf_check): Trigger tree aging when needed.
1802 (__mf_age_tree): New function to decay liveness field.
1803 (__mf_find_objects_rec): Use liveness field to rotate tree.
1804 (__mf_insert_new_object): Only provide backtrace for HEAP objects.
1805 (__mf_unregister): Ditto.
1806 (__mf_register): Tweak duplicate-static message.
1807 (__mf_violation: Tweak nearby-object counter printing.
1809 2002-09-16 Frank Ch. Eigler <fche@redhat.com>
1811 * test/pass20-frag.c: New test file.
1812 * Makefile.am (TESTS): Reorganize. Add pass20 test.
1813 * Makefile.in: Regenerated.
1815 * mf-impl.h (TRACE_IN, TRACE_OUT): Remove macros. Update callers.
1816 * mf-hooks.c (BEGIN_PROTECT): Add hook tracing here.
1817 * mf-heuristic.c (__mf_heuristic_check): Track seen /proc/self/map
1818 entries to avoid repeat registration.
1819 * mf-runtime.c (__mf_object_cemetary): Don't bother bury GUESS regions.
1820 (__mf_register, __mf_unregister): Rewrite GUESS handling logic.
1822 2002-09-09 Frank Ch. Eigler <fche@redhat.com>
1824 * Makefile.am: Create test sources with #include, not cat>>.
1825 * Makefile.in: Regenerated.
1826 * test/buildtest.sh: Removed.
1827 * test/driver.c (abort_handler, main): Be quiet.
1829 2002-09-06 Frank Ch. Eigler <fche@redhat.com>
1831 * test/pass18-frag.c, pass19-frag.c: New tests.
1832 * Makefile.am (check): Run them. Rebuild test programs each time.
1833 * Makefile.in: Regenerated.
1835 2002-09-06 Frank Ch. Eigler <fche@redhat.com>
1837 * mf-runtime.c (__mf_register): Correct SEGV-inducing error in
1838 overlapping object search.
1839 (__mf_violation): Likewise for nearby objects.
1840 Improve nearby-object listing.
1843 * mf-runtime.c, mf-hooks.c: Remove "{{{"/"}}}" folding marks.
1844 * mf-heuristics.c (__mf_heuristic_check): Tweak message.
1846 2002-09-03 Frank Ch. Eigler <fche@redhat.com>
1849 * Makefile.am (AM_CFLAGS): New definition of needed settings.
1850 (HOOKOBJS): Add alloca-hook.o.
1851 * mf-hooks.c (alloca): New function to implement alloca in libiberty
1853 * mf-runtime.c (__mf_report): Call alloca(0) to flush remaining blocks.
1854 (__mf_backtrace): Reimplement without using alloca.
1855 * Makefile.in: Regenerated.
1858 * mf-hooks.c: Use VERBOSE_TRACE throughout instead of fprintf(stderr).
1859 Correct signedness bugs in length-tracking variables.
1860 * mf-impl.h: Make options unsigned.
1861 (CALL_WRAP): New macro to parallel CALL_REAL().
1862 (DECLARE): Remove erroneous ";" at end.
1863 * mf-runtime.c, mf-hooks.c, mf-heuristics.c: Replace remaining %p
1864 formatting specs with %08lx. Correct several compiler warnings.
1866 2002-08-28 Frank Ch. Eigler <fche@redhat.com>
1868 * mf-runtime.c (__mf_violation): Try harder to locate nearby objects.
1870 2002-08-27 Frank Ch. Eigler <fche@redhat.com>
1872 libmudflap hook breakup:
1873 * Makefile.am (TESTS_ENVIRONMENT): Add ../../gcc to LD_LIBRARY_PATH
1875 (TESTS): Make dependent on libmudflap.
1876 (HOOKOBJS): Break up mf-hooks.o into many little hook objects,
1877 compiled from segments of mf-hooks.c.
1878 * mf-hooks.c: Corresponding changes: wrap each function in
1880 * Makefile.in: Regenerated.
1882 Heuristics reorganization:
1883 * mf-heuristics.c (__mf_register_ro_sections, __mf_init_heuristics):
1884 Remove these functions. Update callers.
1885 (__mf_heuristic_check): Incorporate all the various heuristics.
1886 Encode cacheability/retry judgement into trinary return value.
1887 Separate start-end logic into a separate fallback heuristic. Only
1888 register relevant /proc/self/map segments.
1889 * mf-impl.h: Corresponding changes.
1890 * mf-runtime.c (__mf_check): Reorganize heuristics fallback logic.
1891 (__mf_init): Don't call __mf_init_heuristics.
1894 * mf-heuristics.c, mf-runtime.c: Use new MUDFLAP_OPTION
1895 "-verbose-trace" to emit all tracing messages other than those of
1896 basic public api. Eliminate some duplicate/excessive messages.
1897 * mf-runtime.h: Corresponding changes.
1899 2002-08-27 Graydon Hoare <graydon@redhat.com>
1901 * mf-impl.h (WRAPPER): Change to create linker aliases for __wrap
1902 and __real when compiled with -DPIC.
1903 * mf-hooks.c (WRAPPER): Change all uses of WRAPPER macro slightly.
1904 * Makefile.am (AUTOMAKE_OPTIONS): Fix LD_LIBRARY_PATH for tests.
1905 * Makefile.in: Regenerate.
1907 2002-08-26 Graydon Hoare <graydon@redhat.com>
1909 * mf-impl.h: New file, private implementation header.
1910 * mf-runtime.h: Reorganize a bit.
1911 (CLAMPSZ): Fix arithmetic.
1912 (__MF_CACHE_MISS_P): Fix arithmetic.
1913 * mf-runtime.c: Reorganize a bit.
1914 (__mf_dynamic): New structure.
1915 (resolve_single_dynamic): New function.
1916 (__mf_resolve_dynamics): New function.
1917 (__mf_init): Initialize dynamic wrappers.
1918 * mf-hooks.c: Macro-ize __real calls.
1919 Clamp various bits of arithmetic.
1920 Add explicit __mf_check call contexts.
1921 * Makefile.am: Add dependencies on mf-impl.h
1922 * Makefile.in: Regenerate.
1923 * configure.in: Comment out shared override.
1924 * configure: Regenerate.
1926 2002-08-22 Graydon Hoare <graydon@redhat.com>
1928 * mf-runtime.c (__mf_process_opts): Sanity-check free_queue_length.
1929 (__mf_check): Re-inialize and check heuristics before violation.
1930 (__mf_register): Permit updating pure-guess regions.
1931 * mf-hooks.c (__wrap_free): Correct some free queue logic.
1932 (__wrap_dlopen): New wrapper function.
1933 (__wrap_mmap): New wrapper function.
1934 (__wrap_munmap): New wrapper function.
1935 * mf-heuristics.c (__mf_register_ro_sections): Register *all* regions
1936 which are not stack addresses.
1937 (is_stack_address): New function.
1938 (__mf_init_heuristics): Save and restore state, always initialize with
1941 2002-08-21 Frank Ch. Eigler <fche@redhat.com>
1943 * mf-hooks.c (MF_VALIDATE_EXTENT): Rewrite to correct off-by-one
1944 error. Pass location string.
1945 (wrap_strcpy, wrap_strncpy): Remove extra %s in trace strings.
1946 * mf-runtime.c (options): Add lc-mask, lc-shift options.
1947 (__mf_process_opts): Apply some sanity checking for lc-mask.
1948 (__mf_check, __mf_violation): Take new location-string argument.
1949 Update callers to pass NULL if necessary.
1950 (__mf_backtrace): New smart backtracer function. Calls replace
1951 several ad-hoc blocks elsewhere.
1952 (__mf_describe_object): Remove bad reentrancy test. Improve
1954 * mf-runtime.h: Corresponding changes. Public/private markup.
1955 (__MF_CACHE_MISS_P): New macro.
1957 2002-08-20 Graydon Hoare <graydon@redhat.com>
1959 * mf-runtime.h: New option: stack_bound (heuristic).
1960 Move some macros out of implementation files.
1961 * mf-runtime.c: New option string: -stack-bound.
1962 Unify recursion protection with hooks.
1964 (__mf_check): Call __mf_heuristic_check.
1965 (__mf_process_opts): Fix "no-" processing.
1966 * mf-heuristics.c (__mf_heuristic_check): New function.
1967 * mf-hooks.c: Much off-by-one fixing, recursion protection.
1969 2002-08-20 Frank Ch. Eigler <fche@redhat.com>
1971 Option parsing improvements, region splitting bug fixes:
1972 * mf-heuristics.c (__mf_register_ro_sections): Add warned casts.
1973 * mf-runtime.h (heur_proc_map): New libmudflap option.
1974 * mf-runtime.c (__mf_set_default_options): Set it.
1975 (__mf_usage): Print default values/status.
1976 (__mf_process_opts): Support general "no-" option string prefix.
1977 (__mf_init): Print __mf_usage on unknown-option error.
1978 (__mf_register): Print trace message up front.
1979 Correct region splitting logic for case where a subregion disappears.
1980 Correct memory leak.
1981 (__mf_violation): Make even basic message conditional on option.
1984 * Makefile.am (TESTS_ENVIRONMENT): Add -no-heur-proc-map.
1985 (clean-local): New target.
1986 (test/*x rules): Add -g CFLAGS.
1987 (CFLAGS): Add -freorder-blocks.
1988 (MFCONFIG_CFLAGS, INCLUDE): Remove unneeded settings.
1989 * Makefile.in: Regenerated.
1990 * Makefile, mf-config.h: Removed files.
1992 2002-08-16 Graydon Hoare <graydon@redhat.com>
1994 * mf-runtime.c (__mf_insert_new_object): Factor out of
1996 (__mf_remove_old_object): Factor out of __mf_unregister.
1997 (__mf_register): Handle guessed regions, splitting
1998 guesses when new registrations arrive.
1999 (__mf_unregister): Do not unregister guesses.
2000 * mf-runtime.h: Move convenience macros around,
2001 declare new option fields. Add __MF_TYPE_GUESS.
2002 * mf-hooks.c (__wrap_*alloc): Use crumple zones.
2003 (__wrap_free): Call __real_free for deferred frees.
2004 * Makefile.am: Add more tests, fix dependency.
2005 * Makefile.in: Regenerate.
2006 * test/pass[13..17]-frag.c: New testcases.
2007 * test/fail[13..17]-frag.c: New testcases.
2009 2002-08-15 Graydon Hoare <graydon@redhat.com>
2011 * mf-heuristics.c: New file.
2012 * mf-runtime.c (options): Add -trace-calls option.
2013 (__mf_init): Call __mf_init_heuristics.
2015 2002-08-14 Graydon Hoare <graydon@redhat.com>
2017 * Makefile.am (TESTS): Add testsuite support.
2018 * Makefile.in: Regenerate.
2019 * test/mf-driver.c: New file.
2020 * test/buildtest.sh: New file.
2021 * test/passNN-frag.c: New testcases.
2022 * test/failNN-frag.c: New testcases.
2024 2002-08-14 Graydon Hoare <graydon@redhat.com>
2026 * mf-hooks.c: Change __real_strlen() to __real_strlen()+1 when
2027 verifying non-size-limited string extents.
2029 2002-08-14 Frank Ch. Eigler <fche@redhat.com>
2031 * mf-hooks.c: Make __wrap string* functions use __real_str[n]len
2032 instead of plain str[n]len for internal checks.
2033 * mf-runtime.c (__mf_violation): Print optional stack traceback.
2035 2002-08-14 Frank Ch. Eigler <fche@redhat.com>
2037 * mf-hooks.c: Remove #if-0 around hooks that are now ld-wrapped.
2039 2002-08-13 Graydon Hoare <graydon@redhat.com>
2041 * mf-runtime.c: Rework configuration to operate on
2042 environment variable options rather than #defines
2043 (__mf_violation): Add simple fork-a-gdb violaiton mode.
2044 (__mf_init): Set static __mf_active_p flag on startup,
2045 to inhibit mudflap wrap-based checking during crt0.s.
2046 * mf-runtime.h: Declare options structure.
2047 * mf-hooks.c: New wrappings for mem*, b*, str*
2048 libc functions (temporarily #if 0-ed out).
2050 2002-08-12 Frank Ch. Eigler <fche@redhat.com>
2052 * Makefile.am, configure.in: New files.
2053 * Makefile.in, Makefile, configure, config.h.in: New generated files.
2054 * stamp-h.in, aclocal.m4: Ditto.
2056 2002-08-08 Frank Ch. Eigler <fche@redhat.com>
2058 * Makefile: New file.
2059 * mf-config.h: New file: runtime configuration.
2060 * mf-hooks.c: New file: interposed libc functions.
2061 * mf-runtime.c: New file: bulk of runtime.
2062 * mf-runtime.h: New file: public functions.