1 2005-11-22 Janis Johnson <janis187@us.ibm.com>
3 * testsuite/lib/libmudflap.exp (libmudflap-init): Remove -static from
4 MUDFLAP_FLAGS if static library not supported.
5 * testsuite/libmudflap.c/cfrags.exp (MUDFLAP_FLAGS): new.
6 * testsuite/libmudflap.c/externs.exp: Ditto.
7 * testsuite/libmudflap.c++/ctors.exp: Ditto.
8 * testsuite/libmudflap.c++/c++frags.exp: Ditto.
9 * testsuite/libmudflap.cth/cthfrags.exp: Ditto.
11 2005-10-04 James E Wilson <wilson@specifix.com>
13 * configure.ac (mudflap_cv_entry_point): Use quadrigraphs to declare
14 $name as array of characters with unknown bound. Also store into the
16 * configure: Regenerate.
18 2005-09-30 James E. Wilson <wilson@specifix.com>
20 * configure.ac (pthread.h): Use AC_CHECK_HEADERS instead of
22 (target_thread_file): New. Set from sed'ed gcc output.
23 (posix_threads): New. Set from target_thread_file. Use instead of
25 (pthread_create_version): Move initialization before code using it.
26 * configure: Regenerate.
28 * mf-heuristics.c (_end, ENTRY_POINT): Make them arrays with unknown
31 2005-09-29 James E. Wilson <wilson@specifix.com>
33 * mf-hooks1.c (__mf_0fn_mmap, mmap, __mf_0fn_munmap, munmap): Protect
36 2005-09-23 Frank Ch. Eigler <fche@elastic.org>
39 * mf-hooks2.c (accept): Tolerate NULL sockaddr* parameter.
41 2005-09-23 Frank Ch. Eigler <fche@elastic.org>
43 * testsuite/libmudflap.c++/pass58-frag.cxx: New test for heisenbug 19319.
45 2005-09-23 Tom Tromey <tromey@redhat.com>
47 * aclocal.m4, configure: Rebuilt.
48 * configure.ac: Use GCC_CHECK_TLS.
49 * acinclude.m4 (LIBMUDFLAP_CHECK_TLS, LIBMUDFLAP_ENABLE): Moved
52 2005-08-22 Jim Wilson <wilson@specifix.com>
54 * mf-hooks2.c (MF_REGISTER_fopen): Define to __MF_TYPE_STATIC when
55 __FreeBSD__ is defined.
57 2005-08-17 Jim Wilson <wilson@specifix.com>
59 * mf-hooks1.c (malloc, calloc, realloc, free,
60 __mf_wrap_alloca_indirect): Call BEGIN_MALLOC_PROTECT before calling
61 the real routines, and END_MALLOC_PROTECT afterwards.
62 * mf-impl.h (enum __mf_state_enum): Expand comment. Add in_malloc.
63 (BEGIN_PROTECT): Handle in_malloc state.
64 (BEGIN_MALLOC_PROTECT, END_MALLOC_PROTECT): New.
65 * testsuite/libmudflap.c/hook2-allocstuff.c: New.
67 2005-08-17 Kelley Cook <kcook@gcc.gnu.org>
69 * All files: Update FSF address.
71 2005-08-15 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
73 * mf-hooks3.c (main_seen_p): Remove.
74 (__mf_get_state): Remove attempt to recognize the main thread.
76 2005-08-15 Maciej W. Rozycki <macro@linux-mips.org>
78 * configure.ac: Test for the name of the symbol used for the entry
79 point; define ENTRY_POINT to the result.
80 * configure: Regenerate.
81 * config.h.in: Regenerate.
82 * mf-heuristics.c: Replace _start with ENTRY_POINT throughout.
84 2005-08-14 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
86 * mf-runtime.c (__mf_state_1): Initialize to reentrant.
87 (__mf_init): Set thread state active.
88 * mf-hooks3.c (__mf_pthread_spawner): Always set thread
90 (pthread_create wrapper): Always use thread spawner.
92 * testsuite/libmudflap.cth/pass37-frag.c: Increase timeout.
93 * testsuite/libmudflap.cth/pass39-frag.c: Likewise.
95 2005-07-16 Richard Henderson <rth@redhat.com>
97 * acinclude.m4: New file.
98 * configure.ac: Invoke LIBMUDFLAP_CHECK_TLS.
99 * configure, config.h.in, Makefile.in, testsuite/Makefile.in: Rebuild.
100 * mf-hooks1.c (__mf_0fn_malloc): Move body from ...
101 (__mf_0fn_calloc): ... here.
102 * mf-hooks3.c (struct pthread_info): Remove.
103 (__mf_pthread_info, __mf_pthread_info_idx): Remove.
104 (LIBMUDFLAPTH_THREADS_MAX): Set to 1021.
105 (struct mf_thread_data): New.
106 (mf_thread_data, mf_thread_data_lock): New.
107 (__mf_allocate_blank_threadinfo): Remove.
108 (__mf_find_threadinfo): Rewrite and simplify. Only use if TLS is
110 (__mf_state_perthread): Remove.
111 (__mf_get_state, __mf_set_state): New.
112 (__mf_pthread_cleanup): Use &errno, rather than saved pointer.
113 Update mf_thread_data killing procedure.
114 (__mf_pthread_spawner): Similarly.
115 (__mf_0fn_pthread_create): Only use wrapper if necessary. Remove
116 code to allocate thread stack space.
117 (__mf_0fn_pthread_join, pthread_join): Remove.
118 (__mf_0fn_pthread_exit, pthread_exit): Remove.
119 * mf-impl.h (dyn_pthread_join, dyn_pthread_exit): Remove.
120 (__mf_state_1): Rename from __mf_state; use TLS when available.
121 (__mf_get_state, __mf_set_state): New. Update all users.
122 * mf-runtime.c (begin_recursion_protect1): New.
123 (BEGIN_RECURSION_PROTECT): Use it.
124 (__mf_state_1): Rename from __mf_state; use TLS when available.
125 (threads_active_p): Remove.
126 (__mf_usage): Compute it directly.
128 2005-06-19 Ulrich Weigand <uweigand@de.ibm.com>
130 * testsuite/libmudflap.c/externs-1.c (main): Add return statement.
132 2005-06-15 Frank Ch. Eigler <fche@redhat.com>
134 Fix for uncaching bug reported by Herman ten Brugge.
135 * mf-runtime.c (__mf_uncache_object): Search whole cache.
136 * testsuite/libmudflap.c/fail40-frag.c: New test.
138 2005-05-23 Alfred M. Szmidt <ams@gnu.org>
141 * Makefile.am (AM_MAKEFLAGS): Pass includedir.
142 * Makefile.in: Amend.
144 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
147 * testsuite/libmudflap.c/externs.exp, externs-{1,2}.c: New test files.
148 * testsuite/libmudflap.c/cfrags.exp: Bypass new sources.
150 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
153 * testsuite/libmudflap.c++/*.exp: Assert build tree g++.
155 2005-06-14 Frank Ch. Eigler <fche@redhat.com>
158 * mf-impl.h (mudflap_mode, violation_mode): Make these ordinary
159 unsigned vars with #defines instead of enums.
161 2005-05-09 Mike Stump <mrs@apple.com>
163 * configure: Regenerate.
165 2005-04-12 Mike Stump <mrs@apple.com>
167 * configure: Regenerate.
169 2005-04-12 Frank Ch. Eigler <fche@redhat.com>
172 * testsuite/libmudflap.c++/c++frags.exp: Also test -O permutation.
173 * testsuite/libmudflap.c++/pass57-frag.cxx: New test.
175 2005-04-04 Alan Modra <amodra@bigpond.net.au>
177 * mf-runtime.c (__mfu_unregister): Warning fix for char unsigned.
179 2005-03-31 Mike Stump <mrs@apple.com>
181 * mf-runtime.h: Add libmudflap copyright clause.
183 2005-03-21 Mike Stump <mrs@apple.com>
185 * mf-heuristics.c: Fix whitespace at end of line.
186 * mf-hooks1.c: Likewise.
187 * mf-hooks2.c: Likewise.
188 * mf-hooks3.c: Likewise.
189 * mf-impl.h: Likewise.
190 * mf-runtime.c: Likewise.
191 * mf-runtime.h: Likewise.
193 2005-03-21 Zack Weinberg <zack@codesourcery.com>
195 * configure.ac: Do not invoke TL_AC_GCC_VERSION.
196 In all substitutions, expand gcc_version in Makefile.
197 * aclocal.m4, configure: Regenerate.
198 * Makefile.am: Set gcc_version.
199 * Makefile.in, testsuite/Makefile.in: Regenerate.
201 2005-03-17 Frank Ch. Eigler <fche@redhat.com>
203 * mf-runtime.c (__mfu_check): Respect ignore_reads configuration.
204 * testsuite/libmudflap.c/{pass56,fail39}-frag.c: New tests.
206 2005-02-13 Frank Ch. Eigler <fche@redhat.com>
209 * testsuite/libmudflap.c++/pass55-frag.c: New test.
211 2005-01-05 Richard Henderson <rth@redhat.com>
213 * testsuite/libmudflap.c/pass32-frag.c: Fix typo.
215 2005-01-02 Greg McGary <greg@mcgary.org>
217 * mf-impl.h (uintptr_t): Get typedef via stdint.h or define explicitly.
218 * mf-runtime.h: New file, replaces mf-runtime.h.in.
219 * configure.ac (AC_CONFIG_FILES): mf-runtime.h is no longer generated.
220 * Makefile.in: Ditto.
221 * testsuite/lib/libmudflap.exp: Add -I${srcdir}/.. to get mf-runtime.h
222 * testsuite/libmudflap.c/pass32-frag.c: s/uintptr_t/__mf_uintptr_t/
223 * testsuite/libmudflap.c/fail36-frag.c: New test.
224 * testsuite/libmudflap.c/fail37-frag.c: New test.
225 * testsuite/libmudflap.c/fail38-frag.c: New test.
227 2004-12-08 Kelley Cook <kcook@gcc.gnu.org>
229 * Makefile.am: Add ../config to ACLOCAL_AMFLAGS.
230 * aclocal.m4, Makefile.in, testsuite/Makefile.in: Regenerate.
232 2004-12-02 Richard Sandiford <rsandifo@redhat.com>
234 * configure.ac: Use TL_AC_GCC_VERSION to set gcc_version.
235 * aclocal.m4: Include ../config/gcc-version.m4.
236 * configure, Makefile.in, testsuite/Makefile.in: Regenerate.
238 2004-11-29 Kelley Cook <kcook@gcc.gnu.org>
240 * Makefile.am: Define ACLOCAL_AMFLAGS.
241 * acinclude.m4: Remove.
242 * stamp-h.in: Remove superfluous stamp file.
243 * aclocal.m4, configure, Makefile.in: Regenerate.
244 * testsuite/Makefile.in: Likewise.
246 2004-11-24 Kelley Cook <kcook@gcc.gnu.org>
248 * Makefile.am: Revert previous.
249 * acinclude.m4: Restore.
250 * aclocal.m4, configure, Makefile.in: Regenerate.
251 * testsuite/Makefile.in: Likewise.
253 2004-11-24 Kelley Cook <kcook@gcc.gnu.org>
255 * Makefile.am: Define ACLOCAL_AMFLAGS.
256 * acinclude.m4: Remove.
257 * aclocal.m4, configure, Makefile.in: Regenerate.
258 * testsuite/Makefile.in: Likewise.
260 2004-11-23 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
262 * testsuite/lib/libmudflap.exp: Use new procs in target-libpath.exp.
264 2004-11-23 Kelley Cook <kcook@gcc.gnu.org>
266 * Makefile.in, configure, aclocal.m4: Regenerate with automake 1.9.3.
267 * testsuite/Makefile.in: Likewise.
269 2004-11-01 Andreas Schwab <schwab@suse.de>
271 * configure.ac: (target_alias): Default to $host_alias, not
273 * configure: Regenerated.
275 2004-10-28 Frank Ch. Eigler <fche@redhat.com>
277 * testsuite/libmudflap.c/fail35-,pass53-,pass54-frag.c: New tests.
278 * testsuite/libmudflap.c/pass35-frag.c: Correct embedded warning
281 2004-10-25 Eric Botcazou <ebotcazou@libertysurf.fr>
284 * testsuite/lib/libmudflap.exp: Accept more than one multilib libgcc.
286 2004-10-12 Frank Ch. Eigler <fche@redhat.com>
288 * configure.ac: Check for more headers, functions.
289 * mf-hooks2.c (mkbuffer, unmkbuffer): New helper functions for
290 tracking overridden FILE buffers.
291 (fopen, setvbuf): New/revised hook functions for buffer overriding.
292 (setbuf,setlinebuf,fdopen,freopen,fopen64,freopen64,fclose): Ditto.
293 (fflush): Accept given NULL stream (means "all streams").
295 * mf-runtime.c (__mfu_check): Accept accesses that span adjacent
297 (LOOKUP_CACHE_SIZE_MAX): Raise to 64K entries tentatively.
298 (__mf_adapt_cache): Use them all.
299 * testsuite/libmudflap.c/pass35-frag.c: Update warning message.
300 * testsuite/libmudflap.c++/ctors.exp: Ditto.
301 * testsuite/libmudflap.c/{pass51,pass52}-frag.c: New tests.
302 * configure, config.h.in: Regenerated.
304 2004-10-05 Frank Ch. Eigler <fche@redhat.com>
306 * configure.ac: Checking for sys/socket.h once is enough.
307 * configure: Regenerated.
309 2004-10-04 Frank Ch. Eigler <fche@redhat.com>
311 * configure.ac: Look for more headers & functions.
312 * mf-hooks2.c (getmntent, inet_ntoa, getproto*): New wrapper functions.
313 * mf-runtime.h.in: Add new "#pragma redefine_extname"s for them.
314 * mf-runtime.c (options): Clean up integer signedness warnings.
315 (main): Add a declaration to fix a warning.
316 * mf-hooks3.c (pthread_exit): Add not-reached exit() to wrapper.
317 * configure, config.h.in: Regenerated.
319 2004-10-02 Frank Ch. Eigler <fche@redhat.com>
321 * testsuite/libmudflap.c/pass50-frag.c, fail33-frag.c, fail34-frag.c:
322 New tests for proper base/limit checking for aggregates.
324 2004-09-15 Joseph S. Myers <jsm@polyomino.org.uk>
326 * testsuite/libmudflap.c/pass35-frag.c: Update expected message.
328 2004-09-07 Frank Ch. Eigler <fche@redhat.com>
330 * configure.ac: Look for pwd.h, grp.h, netdb.h headers and functions.
331 * mf-hooks2.c (strerror): Unregister previous string returned by
333 (getlogin,cuserid,getpwnam,getpwuid,getgrnam,getgrgid): New wrappers.
334 (getservent,getservbyname,getservbyport,gai_strerror): Ditto.
335 * mf-runtime.h.in: Add redefine_extname pragmas for them all.
336 * mf-runtime.c (__mf_describe_object): Clarify object life status.
337 * testsuite/libmudflap.c/pass48-frag.c, pass49-frag.c, fail32-frag.c:
339 * configure, config.h.in: Regenerated.
341 2004-08-03 Dale Johannesen <dalej@apple.com>
343 * mf-runtime.c: Conditionalize POSIX_SOURCE for Darwin.
345 2004-08-03 Frank Ch. Eigler <fche@redhat.com>
347 * mf-runtime.c (compare_uintptr_t): Remove function. Inline
348 simplified contents in all former callers.
350 2004-07-27 Ulrich Weigand <weigand@informatik.uni-erlangen.de>
352 * mf-runtime.c (__mf_fini): Set mudflap_mode to mode_nop in
353 the statically linked case.
355 2004-07-27 Frank Ch. Eigler <fche@redhat.com>
357 * splay-tree.[ch]: Remove. Merge contents into ...
358 * mf-runtime.c: ... here, renaming symbols and making all functions
359 static. Remove unused min/max functions.
360 * Makefile.am: Forget about splay-tree.[ch].
361 * Makefile.in, testsuite/Makefile.in: Regenerated.
363 2004-07-21 Frank Ch. Eigler <fche@redhat.com>
365 * mf-runtime.c (__mfu_check): Remove mistaken mode-nop handling.
366 (__mfu_usage): Include (C) 2004.
367 * mf-hooks3.c (__mf_find_threadinfo): Don't call tracing functions
368 here. Include a comment explaining why.
370 2004-07-20 Frank Ch. Eigler <fche@redhat.com>
372 * mf-impl.h (__mf_options): Add ignore_reads and timestamps fields.
373 * mf-runtime.c (options): Give them a name.
374 (__mf_set_default_options): Set them.
375 (__mf_insert_new_object, __mfu_unregister): Optionalize timestamps.
376 (__mf_violation): Warning cleanup.
377 * mf-impl.h (MF_VALIDATE_EXTENT): Support ignore_reads option.
378 * splay-tree.c (splay_tree_delete_helper): Remove obsolete decl.
380 2004-07-15 Frank Ch. Eigler <fche@redhat.com>
383 * mf-runtime.c (__mf_init): Make it non-static. Tolerate
386 2004-07-09 Frank Ch. Eigler <fche@redhat.com>
388 Test case for g++/15861
389 * testsuite/libmudflap.c++/ctors-[12].cxx: New test case halves.
390 * testsuite/libmudflap.c++/ctors.exp: Driver.
391 * testsuite/libmudflap.c++/c++frags.exp: Elide redundant default.
392 Look only for *frag* test cases.
394 2004-07-08 Frank Ch. Eigler <fche@redhat.com>
396 ANSI C conversion, libmudflap specialization, recursion limiting.
397 * splay-tree.h (splay_tree_{de,}allocate_fn): Remove allocation_data
398 argument and indirection function pointers, update callers.
399 (splay_tree_s): Add statistics and recursion control fields
400 num_keys, max_depth, depth, rebalance_p.
401 * splay-tree.c (splay_tree_splay_helper): Track recursion depth.
402 Back out of search if it exceeds limit.
403 (splay_tree_splay): Manage recursion limiting with rebalancing as
405 (splay_tree_new): More initialization.
406 (splay_tree_rebalance): New function.
407 (splay_tree_foreach): Rewrite using nonrecursive logic.
408 (splay_tree_xmalloc_allocate, splay_tree_xmalloc_deallocate):
409 Remove. Point indirect calls to mf-runtime.c's routines.
410 (splay_tree_compare_ints, splay_tree_compare_pointers): Remove unused
412 (splay_tree_delete, splay_tree_delete_helper): Ditto.
413 * testsuite/heap-scalestress.c: New test based on one from
414 Eyal Lebedinsky <eyal@eyal.emu.id.au>:
416 2004-07-05 Matthias Klose <doko@debian.org>
418 * libtool-version: New.
419 * Makefile.am (libmudflap_la_LDFLAGS, libmudflapth_la_LDFLAGS):
420 Use -version-info for soname.
421 * Makefile.in: Regenerate.
422 * configure.ac: Remove libtool_VERSION macro
423 * configure: Regenerate
425 2004-07-05 Zack Weinberg <zack@codesourcery.com>
427 * mf-runtime.h.in: Wrap declarations of struct __mf_cache,
428 __mf_lookup_cache, __mf_lc_mask, or __mf_lc_shift in
431 2004-06-29 Frank Ch. Eigler <fche@redhat.com>
433 Splay tree implementation fork.
434 * splay-tree.c, splay-tree.h: Copied & modified from libiberty.
435 Use hard-coded comparison function for uintptr_t. Remove key/value
436 deallocation logic. Cache last splayed key for consecutive lookups.
437 * Makefile.am, Makefile.in: Use them, don't link to them.
438 * mf-runtime.c (__mf_object_tree): Adapt to simpler splay_tree_new.
439 (__mf_find_objects2): Flip successor/predecessor search sequence.
440 * ansidecl.h, libiberty.h: Removed dummy files.
442 2004-06-29 Nick Clifton <nickc@redhat.com>
444 * configure.ac (AC_CHECK_HEADERS): Add dirent.h
445 * configure: Regenerate.
446 * mf-hooks2.c: Surround uses of dirent.h with #ifdef
448 Remove spurious inclusion of <strings.h>.
450 2004-06-29 Nick Clifton <nickc@redhat.com>
452 * mf-runtime.c (pthread_join): Only apply the weak pragma if the
453 function actually exists.
455 2004-06-25 Frank Ch. Eigler <fche@redhat.com>
457 * ansidecl.h, libiberty.h: New dummy files for building splay-tree.
458 * config.h.in: Regenerated.
460 2004-06-24 Frank Ch. Eigler <fche@redhat.com>
462 Adopt splay trees for object database.
463 * Makefile.am: Copy splay-tree.* from libiberty.
464 * Makefile.in, testsuite/Makefile.in: Regenerated.
465 * mf-runtime.h.in (__mf_unregister): Add third parameter (type).
466 * mf-hooks[123].c (*): Add new third parameter to mf_unregister.
467 * mf-impl.h (BEGIN_PROTECT): Remove some trace text.
468 * mf-runtime.c: Rewrite code dealing with object database to use
469 libiberty splay trees. Remove tree liveness aging option.
470 * testsuite/libmudflap.c/fail18-frag.c: Add volatile flag.
472 2004-06-15 Paolo Bonzini <bonzini@gnu.org>
474 * configure.ac: New name of configure.in. Update
475 AC_INIT, AC_CONFIG_SRCDIR, AC_CONFIG_HEADERS, AC_CONFIG_FILES,
476 AC_OUTPUT, AM_INIT_AUTOMAKE to the preferred style for
477 Autoconf 2.5x and Automake 1.7 or later.
478 * configure.in: Remove.
479 * configure: Regenerate.
481 * Makefile.am: Remove useless multilib rules.
482 * Makefile.in: Regenerate.
484 2004-06-15 Paolo Bonzini <bonzini@gnu.org>
486 * .cvsignore: New file.
488 2004-06-10 Stephen Crowley <stephen.crowley@sbcglobal.net>
491 * mf-hooks2.c (semctl): Add cygwin porting hack.
493 2004-06-09 Frank Ch. Eigler <fche@redhat.com>
496 * configure.in: Look for ctype header and glibc implementation.
497 * mf-hooks2.c (__ctype_{b,toupper,tolower}_loc): Sample ctype
498 array hooks for glibc 2.3.
499 * mf-runtime.h.in: Wrap them.
500 * mf-runtime.c (__mf_init): Leave marker regarding other ctype
502 * testsuite/libmudflap.c/pass47-frag.c: New test.
503 * configure, config.h.in: Regenerated.
505 2004-06-04 Frank Ch. Eigler <fche@redhat.com>
507 Portability improvements, e.g., libmudflap/15293.
508 * configure.in: Look for glibc extension functions. Look for
509 support of -f{function,data}-sections. Look for more headers.
510 Create testsuite/mfconfig.exp. Correct more "test x.." thinkos.
511 * Makefile.am: Use $(SECTION_FLAGS). Collapse piecemeal-compiled
512 mf-hooks* into usual single object per source.
513 * mf-hooks*.c: Remove all #if WRAP_foo conditionals.
514 * mf-hooks2.c: #include a bunch more system headers. Define strnlen
515 if system doesn't provide one.
516 * mf-hooks3.c (struct pthread_info): Add stack_*_alloc fields.
517 (pthread_create): Use it to properly GC dead thread stacks.
518 * mf-runtime.c (__mf_violation): Correct snprintf type warning.
519 * testsuite/Makefile.am: Stop generating site.exp.
520 * testsuite/mfconfig.exp.in: New file.
521 * testsuite/config/default.exp: Load new mfconfig.exp.
522 * testsuite/lib/libmudflap.exp (libmudflap-init): Add extra libraries.
523 (prune_gcc_output): Add glibc static linking warnings.
524 * testsuite/libmudflap.*/*frags.exp: Enumerate needed -lmudflap* libs.
525 * testsuite/libmudflap.c/pass46-frag.c: Ditto.
526 * configure, Makefile, aclocal.m4, config.h.in, testsuite/Makefile.in:
527 Regenerated with autoconf 2.57 and automake 1.7.
529 2004-06-04 Per Bothner <per@bothner.com>
531 * configure.in (LIBMUDFLAPTH): Fix thinko.
533 * configure.in: Check for more headers.
534 * mf-hooks2.c: Conditionalize on HAVE_SYS_SOCKET_H etc.
536 * mf-runtime.c: In two places conditionalize on SIUSR1 rather than
537 HAVE_SIGNAL as mingw has signal.h but not SIUSR1.
539 2004-06-01 Andreas Jaeger <aj@suse.de>
541 * configure.in: Handle multilibs, support
542 --enable-version-specific-runtime-libs.
543 * Makefile.am (lib_LTLIBRARIES): Rename to ...
544 (toolexeclib_LTLIBRARIES): this for multilib support.
545 * Makefile.in: Regenerated.
546 * configure: Regenerated.
547 * aclocal.m4: Regenerated.
548 * config.h.in: Regenerated.
549 * testsuite/Makefile.in: Regenerated.
551 2004-06-01 Andreas Jaeger <aj@suse.de>
553 * testsuite/lib/libmudflap.exp (libmudflap-init): Handle
554 multilibs, using multilib directory instead of hardcoded path.
557 2004-05-21 Frank Ch. Eigler <fche@redhat.com>
559 * Makefile.am (AM_MAKEFLAGS): Pass RUNTESTFLAGS.
560 * Makefile.in: Ditto.
562 2004-05-18 Kaz Kojima <kkojima@gcc.gnu.org>
564 * acinclude.m4 (lt_cv_deplibs_check_method): Use pass_all on sh*.
565 * aclocal.m4, configure: Rebuilt.
567 2004-05-17 Frank Ch. Eigler <fche@redhat.com>
569 * lib/libmudflap.exp (libmudflap-init): For C++ test cases only,
570 import some build settings from libstdc++-v3 testsuite_flags.
571 * .../cfrags.exp, .../c++frags.exp, .../cthfrags.exp: Corresponding
572 changes to pass test language.
574 * mf-runtime.c (__mfu_check): Poison the cache with antidote for
575 quicker mode-nop handling.
577 2004-03-25 Frank Ch. Eigler <fche@redhat.com>
579 * mf-impl.h: Added libgcc license header.
581 2004-03-20 Frank Ch. Eigler <fche@redhat.com>
583 * mf-hooks[123].c, mf-runtime.c, mf-heuristics.c:
584 Added libgcc license header.
585 * mf-hooks3.c (__mf_0fn_pthread_create): Correct arg constness.
586 (pthread_create): Simplify stack allocation syntax.
588 2004-03-08 Loren J. Rittle <ljrittle@acm.org>
590 * mf-hooks2.c: Support FreeBSD.
591 (WRAP_gets): Avoid gets().
592 * testsuite/libmudflap.c/pass-stratcliff.c: Do not
593 test unimplemented mem/str calls on FreeBSD.
594 * testsuite/libmudflap.c/pass21-frag.c: Do not include
595 <alloca.h> on FreeBSD.
597 2004-01-30 Frank Ch. Eigler <fche@redhat.com>
599 * testsuite/libmudflap.c/pass36-frag.c: Add missing free() call.
600 * testsuite/libmudflap.c/pass46-frag.c: New test for -fmudflapir.
601 * testsuite/libmudflap.cth/cthfrags.exp: Add -DSTATIC to compiler
602 flags for static linking permutation.
603 * testsuite/libmudflap.cth/pass40-frag.c: When -DSTATIC, avoid
604 some pthreads code that croaks on linux glibc tls.
606 2004-01-27 Frank Ch. Eigler <fche@redhat.com>
608 * testsuite/libmudflap.c/fail31-frag.c, pass45-frag.c: New tests.
610 2004-01-15 Frank Ch. Eigler <fche@redhat.com>
612 * testsuite/libmudflap.c/pass44-frag.c: New test.
614 2004-01-12 Frank Ch. Eigler <fche@redhat.com>
616 * testsuite/libmudflap.c/fail{28,29,30}-frag.c: New tests.
618 2004-01-08 Frank Ch. Eigler <fche@redhat.com>
620 * testsuite/libmudflap.c/pass43-frag.c: Added missing program rc.
622 2003-12-11 Frank Ch. Eigler <fche@redhat.com>
624 * testsuite/libmudflap.c/pass42-frag.c, pass43-frag.c: New tests.
626 2003-12-08 Andrew Pinski <pinskia@physics.uc.edu>
629 * configure.in: Add check for see if
630 socklen_t typedef is in sys/socket.h.
631 * mf-hooks1.c: Add define if socklen_t
633 * mf-hooks2.c: Likewise.
634 * mf-hooks3.c: Likewise.
635 * config.h.in: Regen.
638 2003-12-08 Frank Ch. Eigler <fche@redhat.com>
640 * mf-runtime.c (__mf_watch_or_not): Tweak tracing message.
641 * testsuite/libmudflap.c/fail21-frag.c: Defeat aliasing
643 * testsuite/libmudflap.c/pass25-frag.c: Ditto.
644 * testsuite/libmudflap.c/pass26-frag.c: Tolerate non-overlapping
645 (unoptimized) allocation of stack space.
647 2003-12-07 Richard Henderson <rth@redhat.com>
649 * testsuite/libmudflap.c/fail23-frag.c (main): Adjust addend to 11.
650 * testsuite/libmudflap.c/fail27-frag.c (foo): Mark noinline.
652 2003-12-06 Andrew Pinski <apinski@apple.com>
654 partial PR libmudflap/12670
655 * mf-hooks1.c: Respect Darwin checks. Conditionalize POSIX_SOURCE.
656 * mf-hooks2.c: Likewise.
657 * mf-hooks3.c: Likewise.
659 2003-11-19 Frank Ch. Eigler <fche@redhat.com>
662 * mf-runtime.h.in: Switch to #pragma redefine_extname for
663 symbols interposed at compile time.
664 * testsuite/libmudflap.c++/pass41-frag.cxx: New test.
667 * mf-hooks2.c (semctl): Tolerate FreeBSD.
669 * configure.in: Reorganize check for <pthread.h>.
670 * configure: Regenerated.
672 2003-11-04 David Edelsohn <edelsohn@gnu.org>
674 * mf-runtime.c (_ALL_SOURCE): Define for AIX.
675 (_LARGE_FILE_API): Define for AIX.
676 * mf-hooks[123]: Same.
677 (_XOPEN_SOURCE_EXTENDED): Define to 1 for AIX.
679 2003-10-21 David Edelsohn <edelsohn@gnu.org>
681 * mf-runtime.c (_XOPEN_SOURCE_EXTENDED): Define to 1 for AIX.
683 2003-07-29 Frank Ch. Eigler <fche@redhat.com>
685 2003-07-29 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
687 * configure.in: Update check for union semun.
689 2003-07-29 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
692 * mf-hooks2.c [WRAP_semctl]: Fix check for HAVE_UNION_SEMUN.
694 2003-07-29 Frank Ch. Eigler <fche@redhat.com>
697 * configure.in: Add checks for 64-bit LFS functions, struct semun
698 definition, for BSD compatibility.
699 * mf-hooks1.c: Respect BSD checks. Conditionalize POSIX_SOURCE.
700 * mf-hooks2.c: Ditto. Include <strings.h> for bcmp* decls.
701 * mf-hooks3.c: Ditto.
702 (pthread_create): Try MAP_ANON on platforms without the MAP_ANONYMOUS
704 * configure, config.h.in: Regenerated.
706 2003-07-23 Frank Ch. Eigler <fche@redhat.com>
708 Multithreading fixes:
709 * mf-runtime.c (__mf_object): Store allocating/deallocating
711 (options): Support new "-thread-stack" option.
712 Rename "-heur-argv-environ" option to "-heur-stdlib".
713 Disable "-lc-mask" and "-lc-shift" options.
714 (__mf_dynamic): Add function pointers for pthread_join/_exit.
715 (__assert_fail): New self-contained function for glibc.
716 * mf-hooks3.c: Essentially rewritten, particularly related to
717 use of __mf_pthread_info array.
718 (pthread_join, _exit): New hook functions.
719 * mf-impl.h (BEGIN_PROTECT): Handle starting_p case.
720 * testsuite/libmudflap.cth/pass40-frag.c: New test.
723 * mf-heuristics.c: Add type casts for tracing, sub calls.
724 * mf-impl.h (BEGIN_PROTECT): Redefine to omit result type.
725 Update all callers to declare explicit result holder.
726 (END_PROTECT): Removed.
727 * testsuite/*/*frags.exp: Clean up default MUDFLAP_OPTIONS.
729 2003-07-15 Diego Novillo <dnovillo@redhat.com>
731 * testsuite/libmudflap.c/fail21-frag.c: Add volatile modifiers.
732 * testsuite/libmudflap.c/fail15-frag.c: Likewise.
733 * testsuite/libmudflap.c/fail13-frag.c: Likewise.
735 2003-07-04 Frank Ch. Eigler <fche@redhat.com>
737 * mf-hooks1.c, 2.c, 3.c: New file, splits up content from old ...
739 * mf-impl.h (MF_VALIDATE_EXTENT, BEGIN_PROTECT, END_PROTECT):
740 Move these macros from old mf-hooks.c here.
741 * Makefile.am: Adapt to split-up hook sources for faster builds.
742 * Makefile.in: Regenerated.
744 * mf-heuristics.c: Remove #if-0 block.
746 * mf-impl.h (__mf_state): Reorganize declaration and implementation.
747 (__mf_starting_p): New state only for use while dlsym bootstrapping.
748 (CALL_REAL, __mf_init): Corresponding changes.
749 (TRACE, VERBOSE_TRACE): Include thread id and "mf:" prefix. Update
750 all callers to remove redundant "mf:" prefix.
751 * mf-runtime.h.in: #define a few reentrancy macros for libmudflapth.
752 * mf-hooks3.c: Rewrite chunks to support per-thread __mf_state value.
753 (__mf_pthread_info): Become a hash table.
755 * testsuite/lib/mfdg.exp: Support new "dg-timeout" and
756 "dg-repetitions" directives to control test case execution.
757 * testsuite/libmudflap.cth/pass37-frag.c: Add timeout and repeat
759 * testsuite/libmudflap.cth/pass39-frag.c: Ditto for this new test.
761 2003-06-25 Frank Ch. Eigler <fche@redhat.com>
763 * mf-hooks.c (alloca): Separate into stub.
764 (__mf_wrap_alloca_indirect): New function. Use CALL_REAL
765 malloc/free for alloca blocks.
766 (pthread_create): Tolerate failing pthread_attr_get* calls.
767 * mf-runtime.c (__mf_fini): Call __mf_wrap_alloca_indirect.
768 * mf-impl.h (CALL_WRAP): Remove macro.
769 * testsuite/libmudflap.c/pass21-frag.c: Include <alloca.h>.
770 * testsuite/libmudflap.c/pass23-frag.c: Include more struct
771 padding for ia64 BIT_FIELD_REF constructs.
773 2003-06-19 Frank Ch. Eigler <fche@redhat.com>
775 * mf-hooks.c (struct pthread_info): Add "thread_errno" field.
776 (__mf_pthread_spawner, __mf_pthread_cleanup): Use it with GUESS
777 libmudflap object type.
778 * mf-runtime.c (__mfu_unregister): Correct cemetary logic to avoid
779 crashes on unregistering STATIC objects.
781 2003-06-17 Frank Ch. Eigler <fche@redhat.com>
783 Based on patch from Eyal Lebedinsky <eyal@eyal.emu.id.au>:
784 * mf-hooks.c (__mf_pthread_spawner): Register thread errno.
785 (time, strerror, fopen, fopen64, fclose, fread): New hooks.
786 (fwrite, fgetc, fgets, getc, gets, ungetc, fputc): New hooks.
787 (fputs, putc, puts, clearerr, feof, ferror, fileno): New hooks.
788 (printf, fprintf, sprintf, snprintf, vprintf, vfprintf): New hooks.
789 (vsprintf, vsnprintf, access, remove, fflush, fseek): New hooks.
790 (fseeko64, ftell, ftello64, rewind, fgetpos, fsetpos): New hooks.
791 (stat, stat64, fstat, lstat, mkfifo, setvbuf, setbuf): New hooks.
792 (setvbuf, opendir, closedir, readdir, recv, recvfrom): New hooks.
793 (recvmsg, send, sendto, sendmsg, setsockopt, getsockopt): New hooks.
794 (accept, bind, connect, gethostname, sethostname): New hooks.
795 (gethostbyname, wait, waitpid, popen, pclose, execve): New hooks.
796 (execv, execvp, system, dlopen, dlclose, dlerror, dlsym): New hooks.
797 (semop, semctl, shmctl, shmat, shmdt): New hooks.
798 * mf-runtime.h.in: Corresponding changes.
799 * mf-runtime.c (__mf_ini): Register stdio objects. Use STATIC type.
800 (opts) Rename heur_argv_environ to heur_std_data.
801 (__mf_wrap_main): Use STATIC type for argv/environ strings.
802 * Makefile.am: Corresponding changes.
803 * Makefile.in: Regenerated.
805 2003-06-11 Frank Ch. Eigler <fche@redhat.com>
807 * mf-heuristics.c (__mf_heuristic_check): Disable stack_bounds
808 heuristic for threaded case, and for non-x86-linux targets.
809 * mf-hooks.c (__mf_0fn_calloc): Provide a working dummy implementation
810 for use during pre-main() program startup.
811 (__mf_0fn_*): Make these functions non-static.
812 * mf-impl.h (DECLARE, CALL_REAL): Support calls to 0fn backup hook
814 * mf-runtime.c (__mf_state): Set initial state to "starting".
815 (__mf_resolve_single_dynamic): Tolerate repeated calls for same symbol.
816 (__wrap_main): New function to register argv[] and environ[] strings.
818 (*): In all trace functions, use "%p" as formatter for uintptr_t.
820 * testsuite/libmudflap.c/pass38-frag.c: New test case.
821 * testsuite/libmudflap.cth/pass37-frag.c: Improved test.
823 * acinclude.m4: Add comments with aoliva's concerns about x86_64
825 * aclocal.m4, configure: Regenerated.
827 2003-06-04 Frank Ch. Eigler <fche@redhat.com>
829 * acinclude.m4: Correct typo in AC_MSG_CHECKING.
830 * aclocal.m4, configure: Regenerated.
832 2003-06-03 Frank Ch. Eigler <fche@redhat.com>
834 * acinclude.m4: Force "pass_all" deplibs_check_method for libtool
835 for x86_64 target. Disable caching for this value.
836 * aclocal.m4, configure: Regenerated.
838 2003-06-02 Frank Ch. Eigler <fche@redhat.com>
840 * testsuite/libmudflap.c/pass38-frag.c: Deleted. -fwritable-strings
841 is about to become deprecated, and its present handling bugs are
844 2003-05-30 Frank Ch. Eigler <fche@redhat.com>
846 * testsuite/libmudflap.c/pass38-frag.c: New test for
849 2003-05-23 Frank Ch. Eigler <fche@redhat.com>
851 * mf-runtime.c (__mf_sigusr1_handle): Call unlocked variant of
852 __mf_report, asserting reentrant calling context.
854 2003-05-23 Frank Ch. Eigler <fche@redhat.com>
856 * mf-hooks.c (realloc): Correct reentrancy logic.
857 * testsuite/libmudflap.c/hook-allocstuff.c: New test case.
859 2003-05-20 Frank Ch. Eigler <fche@redhat.com>
861 * mf-hooks.c (LIBMUDFLAPTH_THREADS_MAX): New macro, replaces
862 PTHREAD_THREADS_MAX. Update users.
863 * mf-runtime.c (__mf_usage): Print [active] instead of [default]
865 * testsuite/Makefile.am (all-local): Prime dejagnu site.exp file
866 with libmudflapth presence indicator.
867 * testsuite/Makefile.in: Regenerated.
869 2003-05-16 Frank Ch. Eigler <fche@redhat.com>
871 * Makefile.am (AM_CFLAGS): Remove "-ansi".
872 * configure.in: Remove silly no-pthreads => no-shared logic.
873 * Makefile.in, configure: Regenerated.
874 * mf-heuristics.c (__mf_heuristic_check): Remove reentrancy hacks.
875 * mf-hooks.c (BEGIN_PROTECT, END_PROTECT): Reorganize reentrancy
876 code. Count reentrancy events.
877 (all hook functions): Don't directly manipulate __mf_state variable.
878 Add TRACE calls to hook functions without them.
879 * mf-impl.h (LOCKTH): Try to count lock contention events.
880 (VERBOSE_TRACE, TRACE): Remove reentrancy hacks.
881 * mf-runtime.c (BEGIN_RECURSION_PROTECT, END_RECURSION_PROTECT):
882 Reorganize reentrancy code.
883 (external __mf_ entry points): Use RECURSION_PROTECT mechanism to
884 identify reentrancy with mutex holding times.
885 (internal __mfu_ entry points): Remove internal reentrancy code.
886 (__mf_init): Use ordinary locked calls.
887 (__mfu_report): Print the two new counts.
888 * testsuite/lib/libmudflap.exp: Filter out junk ld/pthreads messages.
889 * testsuite/libmudfap.cth/cthfrags.exp: New test driver.
890 * testsuite/libmudflap.cth/pass37-frag.c: New pthreads test.
891 * testsuite/libmudfap.cth/cfrags.exp: Adapt to new libmudflap
894 2003-05-09 Frank Ch. Eigler <fche@redhat.com>
896 * configure.in: Add pthread support, plus glibc and porting hacks.
897 * Makefile.am (LIBMUDFLAPTH): New conditional, to build -lmudflapth
898 from objects built into ./pth/.
899 * mf-runtime.c (__mfu_watch,register,...): Fork new unlocked
900 functions for internal entry points. Update callers to pick
901 locked vs. unlocked variants.
902 (__mf_resolve_single_dynamic): Extend to support symbol versioning
903 info coming in from a static data structure.
904 (*): Reorder miscellaneous declarations to group data vs functions.
905 (__mf_set_default_options): Simplify.
906 (__mf_usage): Mention threading status of host executable.
907 * mf-impl.h: Move max/min decls here. Reorganize __mf_dynamic
908 decls to match above.
909 (LOCKTH, UNLOCKTH): New macros for Big Libmudflap Lock management.
910 * mf-heuristics.c: Choose between locked/unlocked calls. Add
911 some lock/unlock markers. Remove some unused code.
913 (pthread_create): New hook function.
914 (__mf_pthread_cleanup, _spawner): New helper functions.
915 * configure. aclocal.m4, config.h.in, Makefile.in: Regenerated.
917 2003-05-02 Frank Ch. Eigler <fche@redhat.com>
919 * testsuite/libmudflap.c/fail27-frag.c: Add more volatile flags.
921 2002-04-28 Frank Ch. Eigler <fche@redhat.com>
923 * Makefile.am (HOOKOBJS): Add *time related hooks.
924 * configure.in: Look for pthreads.h header.
925 * mf-hooks.c (asctime, ctime, gmtime, localtime): New wrappers.
926 * mf-runtime.c: Begin sketching some pthreads support.
927 (__mf_usage): Check for -lpthread presence.
928 (__mf_unregister): Confirm matching unregistration base.
929 (__mf_find_objects_rec): Reduce unnecessary recursion.
930 * mf-runtime.h.in: Add "nothrow" attribute to functions. Add
931 #defines for new hook functions.
932 * mf-impl.h: Corresponding changes.
933 * config.h.in, configure, Makefile.in: Regenerated.
935 2002-04-27 Diego Novillo <dnovillo@redhat.com>
937 * testsuite/libmudflap.c/fail1-frag.c: Add volatile
938 modifiers to prevent being optimized away.
939 * testsuite/libmudflap.c/fail10-frag.c: Likewise.
940 * testsuite/libmudflap.c/fail13-frag.c: Likewise.
941 * testsuite/libmudflap.c/fail14-frag.c: Likewise.
942 * testsuite/libmudflap.c/fail15-frag.c: Likewise.
943 * testsuite/libmudflap.c/fail2-frag.c: Likewise.
944 * testsuite/libmudflap.c/fail20-frag.c: Likewise.
945 * testsuite/libmudflap.c/fail3-frag.c: Likewise.
947 2003-04-15 Frank Ch. Eigler <fche@redhat.com>
949 * Makefile.am (libmudflap_la_LIBADD): Remove -ldl.
950 * configure.in: Look for uintptr_t and -ldl on target.
951 * mf-runtime.h.in: Adjust uintptr_t declaration logic.
952 * Makefile.in, aclocal.m4, configure, config.h.in: Regenerated.
953 * testsuite/Makefile.in: Regenerated.
954 * mf-runtime.c (__mf_sigusr1_respond): Tweak declaration and calls
955 for better C compliance.
957 2003-04-15 Frank Ch. Eigler <fche@redhat.com>
959 * mf-hooks.c (MF_VALIDATE_EXTENT): Remove unnecessary reentrancy
961 * mf-runtime.c (__mf_set_default_options): Turn off
962 check-initialization.
963 (__mf_describe_object): Shorten description.
964 * testsuite/libmudflap.c/fail25-frag.c: Turn on check-initialization.
966 2003-04-07 Frank Ch. Eigler <fche@redhat.com>
968 * mf-hooks.c (__mf_0fn_mmap): Correct return value, as per <rth>.
970 2003-04-02 Frank Ch. Eigler <fche@redhat.com>
972 * mf-hooks.c (BEGIN_PROTECT): Handle startup-time reentrant
974 (__mf_0fn_malloc ... _munmap): New dummy backup calls.
975 * mf-impl.h (CALL_BACKUP): New macros.
976 * mf-runtime.c (__mf_init): Tweak __mf_state during startup.
978 2003-03-31 Frank Ch. Eigler <fche@redhat.com>
980 * Makefile.am (AM_CFLAGS): Remove optimization flags.
981 (HOOKOBJS): Remove dlopen hook.
982 (libmudflap_la_LIBADD): Add -ldl.
983 * mf-hooks.c (dlopen): Remove hook.
984 * mf-impl.h (__mf_dynamic): Ditto.
985 * mf-runtime.c (__mf_resolve_dynamics): Ditto.
986 * Makefile.in: Regenerated.
988 2003-03-28 Frank Ch. Eigler <fche@redhat.com>
990 * configure.in: Check for target gettimeofday, signal, some headers.
991 * mf-impl.h (__mf_opts): Add new "sigusr1_report" field. Comment
992 out inop multi_threaded field.
993 * mf-runtime.c (options): Handle new "-sigusr1-report" option.
994 (__mf_set_options): Correct handling of "-help".
995 (__mf_sigusr1_respond): New function to manage SIGUSR1 response.
996 (__mf_check, __mf_register, __mf_unregister): Call it.
997 (__mf_insert_new_object, __mf_unregister): Respect HAVE_GETTIMEOFDAY.
998 (__mf_report_leaks): Make callable
999 (__mf_tree_analyze): Traverse in-order. Accumulate address bit
1000 distribution statistics.
1001 (__mf_adapt_cache): Rewrite shift guessing logic based on address
1003 * config.h.in, configure: Regenerated.
1004 * testsuite/libmudflap.c/fail27-frag.c: New test.
1005 * testsuite/libmudflap.c/pass36-frag.c: New test.
1007 2003-03-11 Frank Ch. Eigler <fche@redhat.com>
1009 * mf-runtime.h.in: Tweak.
1010 * Makefile.am, configure.in: Tweak mf-runtime.h generation some more.
1011 Don't use intermediate files nor AC_OUTPUT-time postprocessing.
1012 * Makefile.in, testsuite/Makefile.in, configure: Regenerated.
1014 2003-03-10 Frank Ch. Eigler <fche@redhat.com>
1016 * configure.in: Tweak generation of mf-runtime.h some more. It
1017 needs to work from both config.status and configure.
1018 * configure: Regenerated.
1020 2003-03-10 Frank Ch. Eigler <fche@redhat.com>
1022 * Makefile.am: Reorganize hook file building. Add auto dependencies.
1023 * configure.in: Tweak generation of mf-runtime.h.
1024 * mf-runtime.h.in: Add new __MF_TYPE_HEAP_I.
1025 * mf-hooks.c (*): Adapt to initialized-heap object type.
1026 * mf-impl.h: Tweak cemetary boundaries.
1027 * mf-runtime.c (__mf_check): Adapt to new initialized-heap object
1029 (__mf_insert_new_object, __mf_register, __mf_unregister): Ditto.
1030 (__mf_describe_object, __mf_report_leaks, __mf_violation): Ditto.
1031 * testsuite/lib/libmudflap.exp (includes): Include build tree.
1032 * testsuite/libmudflap.c/pass{26,5}: Further adapt to initialization
1034 * testsuite/.../fail{25,26}-frag.c: New tests.
1035 * testsuite/.../pass{32,33,34,35}-frag.c: New tests.
1036 * Makefile.in, configure: Regenerated.
1038 2003-03-05 Frank Ch. Eigler <fche@redhat.com>
1040 * mf-runtime.c (__mf_set_default_options): Turn on initialization
1041 checking by default.
1042 (__mf_insert_new_object): As a temporary hack, assume that new
1043 objects registered on the stack start out initialized.
1044 * testsuite/libmudflap.c/fail9,pass23,pass[6789]-*: Initialize
1045 heap objects by hand.
1047 2003-03-05 Frank Ch. Eigler <fche@redhat.com>
1049 Switch to macro-style hooks for str*/mem*/b* functions.
1050 * mf-runtime.h.in (__MF_TYPE_*): Moved some internal values out.
1051 (mem*, str*, b*): Added macro-style hooks for _MUDFLAP case.
1052 * mf-runtime.c: #include config.h to enable glibc backtraces again.
1053 (__mf_set_default_options): Turn off heur_proc_map.
1054 (*): Adapt to to macro-style hook functions.
1055 (__mf_object_dead_head, __mf_object_cemetary): Correct bounds.
1056 (__mf_check, __mf_register, __mf_unregister): Tweak tracing message.
1057 (__mf_violation): Handle __MF_VIOL_WATCH.
1058 * mf-impl.h (__MF_TYPE_*): Moved these internal values here.
1059 (__mf_dynamic): Removed mem*/str*/b* functions.
1060 (TRACE, VERBOSE_TRACE): Add reentrancy locking.
1061 (WRAPPER2): New macro for macro-style hooks.
1062 * mf-hooks.c: Convert mem*/str*/b* functions to simpler
1064 (BEGIN_PROTECT): Tweak tracing vs reentrancy-lock ordering.
1065 * mf-heuristics.c: Adapt to macro-style hook functions.
1066 Correct some comments.
1067 * testsuite/lib/mfdg.exp (dg-test): Simplify result string for
1068 output pattern tests.
1069 * testsuite/libmudflap.c/fail[89]-frag.c: Elaborate output test.
1070 * testsuite/libmudflap.c++/c++frags.exp: Enable non-static tests.
1072 2003-02-28 Frank Ch. Eigler <fche@redhat.com>
1074 * testsuite/libmudflap.c/fail23-frag.c, pass30-frag.c: New tests
1075 for global array registration.
1076 * testsuite/libmudflap.c++/fail24-frag.cxx, pass31-frag.cxx: Ditto.
1077 * testsuite/libmudflap.c++/c++frags.exp: Tweak -static multilib hack.
1079 2003-02-27 Frank Ch. Eigler <fche@redhat.com>
1081 * Makefile.am: Add gross make bug workarounds. Tweaked
1082 SUBDIRS and AM_CFLAGS.
1083 * Makefile.in: Regenerated.
1085 2003-02-26 Frank Ch. Eigler <fche@redhat.com>
1088 * configure.in (AC_PROG_CXX): Don't look for C++ any more.
1089 * Makefile.am (TESTS): Remove simple automake testing.
1090 * configure, Makefile.in: Regenerated.
1091 (SUBDIRS): Include new testsuite/ directory.
1092 * tests/*: Removed all files; moved bulk under:
1093 * testsuite/*: New subdirectory tree.
1094 * testsuite/libmudflap.c/cfrags.exp: New file, C test driver.
1095 * testsuite/libmudflap.c++/c++frags.exp: New file, C++ test driver.
1096 * testsuite/lib/libmudflap.exp: New file, derived from libstdc++.
1097 * testsuite/lib/mfdg.exp: New file, derived from dejagnu.
1098 * testsuite/config/default.exp: New file.
1099 * testsuite/Makefile.am, Makefile.in: New files.
1101 2003-01-29 Frank Ch. Eigler <fche@redhat.com>
1103 * Makefile.am (TESTS_ENVIRONMENT): Remove redundant "-mode-check".
1104 (TESTS): Add fail22 and pass29 tests.
1105 * mf-runtime.h.in: Change API to take void*/size_t region parameters.
1106 Add new access-type parameter for __mf_check. Move __MF_VIOL* out.
1107 * mf-impl.h: Corresponding changes. Update CLAMP* macros for void*
1108 values. Move __MF_VIOL* here.
1109 * mf-runtime.c (*): Adapt to void*/size_t API in mf-runtime.h.
1110 (check_initialization): New field in __mf_opts. Default off.
1111 (read_count,write_count): New fields in __mf_object.
1112 (__mf_check): Implement basic initialization checking.
1113 (__mf_insert_new_object): Assume STATIC|GUESS regions are initialized.
1114 (__mf_describe_object): Print new fields.
1115 (__mf_violation): Identify check/read vs. check/write in messages.
1116 * test/pass29-frag.c, test/fail22-frag.c: Basic tests for new
1117 "-check-initialized" mudflap option.
1118 * test/pass25-frag.c, test/fail21-frag.c: Adapt to API changes.
1119 * mf-hooks.c (MF_VALIDATE_EXTENT): Add new access-type parameter.
1120 Drop __FILE__/__LINE__ hack. Update callers.
1121 (*): Adapt to new mf-runtime.h API.
1122 * Makefile.in: regenerated.
1124 2003-01-24 Frank Ch. Eigler <fche@redhat.com>
1126 * configure.in: Build mf-runtime.h a more proper way.
1127 * mf-hooks.c (strdup, strndup): Correct reentrancy logic.
1128 * mf-runtime.c (verbose_violations): Turn on by default.
1129 * mf-runtime.h.in: Remove some miscellaneous stuff ...
1130 * mf-impl.h: ... and move it here.
1131 * configure: Regenerated.
1133 2003-01-22 Frank Ch. Eigler <fche@redhat.com>
1135 * configure.in: Look for C++ compiler.
1136 * test/*-frag.c, mf-driver.c: Reformatted with GNU indent and
1137 fixed type warnings when built with C++.
1138 * test/pass27-frag.cxx, pass28-frag.cxx: New C++ tests.
1139 * Makefile.am (TESTS): Run them.
1140 (*) Add new rules for building and running C++ tests.
1141 (TESTFLAGS): Set new default to avoid libstdc++-v3 shlib issues.
1142 * mf-runtime.h.in: Protect with extern "C".
1143 * Makefile, configure: Regenerated.
1145 2003-01-06 Frank Ch. Eigler <fche@redhat.com>
1147 Portability improvements.
1148 * configure.in: Look for glibc backtrace headers/functions.
1149 * mf-hooks.c: Don't include <execinfo.h> any more.
1150 * mf-runtime.c (__mf_set_options): Call more stdlib functions
1152 (__mf_backtrace): Provide alternate baby implementation in
1154 * test/mf-driver.c: Portability tweaks.
1155 * acinclude.m4: New file, containing top level libtool.m4.
1156 * aclocal.m4, configure, Makefile.in, config.h.in: Regenerated.
1158 2002-12-19 Frank Ch. Eigler <fche@redhat.com>
1160 * mf-runtime.h.in (HAVE_UINTPTR_T): Define unconditionally.
1162 2002-11-08 Frank Ch. Eigler <fche@redhat.com>
1164 * mf-runtime.c (options): Add new "wipe-heap", "wipe-stack"
1166 (__mf_unregister): Implement stack/heap object wiping.
1167 (__mf_set_options): Renamed from __mf_process_opts.
1168 (__mf_uncache_object): Change arg type, correct callers.
1169 * mf-impl.h: Corresponding changes.
1170 * mf-hooks.c (realloc): Save/restore heap-wiping flag.
1171 * mf-runtime.h.in (__mf_set_options): Extend public API.
1172 * test/pass26-frag.c: New test for stack wiping.
1173 * Makefile.am (TESTS): Run it.
1174 * Makefile.in: Regenerated.
1176 2002-11-07 Frank Ch. Eigler <fche@redhat.com>
1178 * mf-runtime.h.in (__mf_watch, __mf_unwatch): Extend public API.
1179 * mf-runtime.c (__mf_object_t): Add watching_p field.
1180 (__mf_watch_or_not): New function to implement
1181 object watch flagging.
1182 (__mf_watch, __mf_unwatch): New wrappers for above.
1183 (__mf_check, __mf_describe_object): Handle objects with watching_p.
1184 (__mf_count_violation): Enlarge array.
1185 (__mf_uncache_object): Renamed from __mf_remove_old_object. Don't
1186 unlink object. Clear cache properly.
1187 (__mf_unregister): Unlink object explicitly before uncaching.
1188 * test/fail21-frag.c, pass25-frag.c: New tests.
1189 * Makefile.in, aclocal.m4: Regenerated.
1191 2002-11-05 Frank Ch. Eigler <fche@redhat.com>
1193 * test/fail20-frag.c: New test for NULL pointer dereferencing.
1194 * Makefile.am (TESTS): Add it.
1195 * test/pass-stratcliff.c: Add decls of stpcpy.
1196 * configure.in: Test for <stdint.h>. Generate mf-runtime.h in
1197 build tree from config.h and new file mf-runtime.h.in.
1198 * mf-runtime.h.in: Renamed from mf-runtime.h. Tweak uintptr_t decl.
1199 * Makefile.in, configure, config.h.in: Regenerated.
1200 * mf-hooks.c: Add #undef for wrapped glibc str*/mem* macros.
1201 * mf-runtime.c (options, __mf_set_default_options): Support new
1202 default "abbreviate" option.
1203 (__mf_object.description_epoch): New field.
1204 (__mf_describe_object): Conditionally abbreviate objects already
1205 displayed in current epoch. Accept NULL input to increment epoch.
1206 (__mf_fini, __mf_ini): Reset description epoch.
1207 (__mf_register, __mf_unregister, __mf_adapt_cache, __mf_init): Ensure
1208 that NULL pointer slot in lookup cache is invalidated. Register a
1209 NOACCESS region around NULL.
1210 * mf-impl.h: Corresponding changes.
1212 2002-10-16 Frank Ch. Eigler <fche@redhat.com>
1214 * test/fail19-frag.c, pass24-frag.c, pass-stratcliff.c: New tests.
1215 * Makefile.am: Run them. Install mf-runtime.h.
1216 * Makefile.in: Regenerated.
1217 * mf-hooks.c: Add some markers for more missing functions.
1218 * mf-runtime.c (__mf_adapt_cache): Experiment with a utilization-based
1219 statistic to tune tune cache size (mask).
1221 2002-10-01 Frank Ch. Eigler <fche@redhat.com>
1223 * test/pass23-frag.c: New test for bit_field_ref expressions.
1224 * Makefile.am, Makefile.in: Add new test.
1225 * mf-hooks.c (mmap, munmap): Rewrite to track individual pages.
1226 (MF_VALIDATE_EXTENT): Accept zero-size mem/str operations.
1227 * mf-runtime.c (__mf_init): Register errno global.
1228 (__mf_find_object): Removed function.
1229 (__mf_check): Rewrite logic to support accesses across some
1230 contiguous but distinctly registered objects.
1231 (__mf_remove_old_object): Tolerate cache entries that span
1234 2002-09-30 Frank Ch. Eigler <fche@redhat.com>
1236 * test/pass21-frag.c, pass22-frag.c: New tests: alloca, bitfields.
1237 * Makefile.am, Makefile.in: Run new tests.
1238 * mf-hooks.c (alloca): Correct stack direction logic.
1240 2002-09-26 Frank Ch. Eigler <fche@redhat.com>
1242 * mf-impl.h (adapt_cache): New option.
1243 * mf-runtime.c (__mf_set_default_options): Set its default value.
1244 Tweak the tree_aging parameter down.
1245 (__mf_check): Maintain separate counter for cache-adaptation.
1246 (__mf_tree_analyze): New function to collect object tree stats.
1247 (__mf_adapt_cache): New function to automate cache parameters.
1249 2002-09-24 Frank Ch. Eigler <fche@redhat.com>
1251 * mf-heuristics.c (__init_misc, __mf_heuristic_check): Add
1252 hypothetical #if-0'd argv/envp region registration.
1253 * mf-runtime.c (__mf_init): Add kludged form of above.
1254 (*) Add "heur_argv_environ" flag, default on, to govern this.
1255 * mf-impl.h: Corresponding changes.
1257 2002-09-20 Frank Ch. Eigler <fche@redhat.com>
1259 * test/fail18-frag.c: New test file for NOACCESS regions.
1260 * Makefile.am (TESTS): Add new test.
1261 * Makefile.in: Regenerated.
1263 * mf-heuristics.c (__mf_heuristics_check): Correct deja_vu logic.
1264 * mf-impl.h (tree_aging): Add new mudflap_option, default 1000000.
1265 (optimize_object_tree): Remove unused mudflap_option.
1266 * mf-runtime.h (__MF_TYPE_NOACCESS): New region type. Add printing
1267 support throughout. Use .._MAX_CEM for cemetary upper bound.
1268 * mf-runtime.c (__mf_init): Register __mf_* globals as NOACCESS
1270 (__mf_object): Add new liveness field for use by tree aging.
1271 (__mf_check): Trigger tree aging when needed.
1272 (__mf_age_tree): New function to decay liveness field.
1273 (__mf_find_objects_rec): Use liveness field to rotate tree.
1274 (__mf_insert_new_object): Only provide backtrace for HEAP objects.
1275 (__mf_unregister): Ditto.
1276 (__mf_register): Tweak duplicate-static message.
1277 (__mf_violation: Tweak nearby-object counter printing.
1279 2002-09-16 Frank Ch. Eigler <fche@redhat.com>
1281 * test/pass20-frag.c: New test file.
1282 * Makefile.am (TESTS): Reorganize. Add pass20 test.
1283 * Makefile.in: Regenerated.
1285 * mf-impl.h (TRACE_IN, TRACE_OUT): Remove macros. Update callers.
1286 * mf-hooks.c (BEGIN_PROTECT): Add hook tracing here.
1287 * mf-heuristic.c (__mf_heuristic_check): Track seen /proc/self/map
1288 entries to avoid repeat registration.
1289 * mf-runtime.c (__mf_object_cemetary): Don't bother bury GUESS regions.
1290 (__mf_register, __mf_unregister): Rewrite GUESS handling logic.
1292 2002-09-09 Frank Ch. Eigler <fche@redhat.com>
1294 * Makefile.am: Create test sources with #include, not cat>>.
1295 * Makefile.in: Regenerated.
1296 * test/buildtest.sh: Removed.
1297 * test/driver.c (abort_handler, main): Be quiet.
1299 2002-09-06 Frank Ch. Eigler <fche@redhat.com>
1301 * test/pass18-frag.c, pass19-frag.c: New tests.
1302 * Makefile.am (check): Run them. Rebuild test programs each time.
1303 * Makefile.in: Regenerated.
1305 2002-09-06 Frank Ch. Eigler <fche@redhat.com>
1307 * mf-runtime.c (__mf_register): Correct SEGV-inducing error in
1308 overlapping object search.
1309 (__mf_violation): Likewise for nearby objects.
1310 Improve nearby-object listing.
1313 * mf-runtime.c, mf-hooks.c: Remove "{{{"/"}}}" folding marks.
1314 * mf-heuristics.c (__mf_heuristic_check): Tweak message.
1316 2002-09-03 Frank Ch. Eigler <fche@redhat.com>
1319 * Makefile.am (AM_CFLAGS): New definition of needed settings.
1320 (HOOKOBJS): Add alloca-hook.o.
1321 * mf-hooks.c (alloca): New function to implement alloca in libiberty
1323 * mf-runtime.c (__mf_report): Call alloca(0) to flush remaining blocks.
1324 (__mf_backtrace): Reimplement without using alloca.
1325 * Makefile.in: Regenerated.
1328 * mf-hooks.c: Use VERBOSE_TRACE throughout instead of fprintf(stderr).
1329 Correct signedness bugs in length-tracking variables.
1330 * mf-impl.h: Make options unsigned.
1331 (CALL_WRAP): New macro to parallel CALL_REAL().
1332 (DECLARE): Remove erroneous ";" at end.
1333 * mf-runtime.c, mf-hooks.c, mf-heuristics.c: Replace remaining %p
1334 formatting specs with %08lx. Correct several compiler warnings.
1336 2002-08-28 Frank Ch. Eigler <fche@redhat.com>
1338 * mf-runtime.c (__mf_violation): Try harder to locate nearby objects.
1340 2002-08-27 Frank Ch. Eigler <fche@redhat.com>
1342 libmudflap hook breakup:
1343 * Makefile.am (TESTS_ENVIRONMENT): Add ../../gcc to LD_LIBRARY_PATH
1345 (TESTS): Make dependent on libmudflap.
1346 (HOOKOBJS): Break up mf-hooks.o into many little hook objects,
1347 compiled from segments of mf-hooks.c.
1348 * mf-hooks.c: Corresponding changes: wrap each function in
1350 * Makefile.in: Regenerated.
1352 Heuristics reorganization:
1353 * mf-heuristics.c (__mf_register_ro_sections, __mf_init_heuristics):
1354 Remove these functions. Update callers.
1355 (__mf_heuristic_check): Incorporate all the various heuristics.
1356 Encode cacheability/retry judgement into trinary return value.
1357 Separate start-end logic into a separate fallback heuristic. Only
1358 register relevant /proc/self/map segments.
1359 * mf-impl.h: Corresponding changes.
1360 * mf-runtime.c (__mf_check): Reorganize heuristics fallback logic.
1361 (__mf_init): Don't call __mf_init_heuristics.
1364 * mf-heuristics.c, mf-runtime.c: Use new MUDFLAP_OPTION
1365 "-verbose-trace" to emit all tracing messages other than those of
1366 basic public api. Eliminate some duplicate/excessive messages.
1367 * mf-runtime.h: Corresponding changes.
1369 2002-08-27 Graydon Hoare <graydon@redhat.com>
1371 * mf-impl.h (WRAPPER): Change to create linker aliases for __wrap
1372 and __real when compiled with -DPIC.
1373 * mf-hooks.c (WRAPPER): Change all uses of WRAPPER macro slightly.
1374 * Makefile.am (AUTOMAKE_OPTIONS): Fix LD_LIBRARY_PATH for tests.
1375 * Makefile.in: Regenerate.
1377 2002-08-26 Graydon Hoare <graydon@redhat.com>
1379 * mf-impl.h: New file, private implementation header.
1380 * mf-runtime.h: Reorganize a bit.
1381 (CLAMPSZ): Fix arithmetic.
1382 (__MF_CACHE_MISS_P): Fix arithmetic.
1383 * mf-runtime.c: Reorganize a bit.
1384 (__mf_dynamic): New structure.
1385 (resolve_single_dynamic): New function.
1386 (__mf_resolve_dynamics): New function.
1387 (__mf_init): Initialize dynamic wrappers.
1388 * mf-hooks.c: Macro-ize __real calls.
1389 Clamp various bits of arithmetic.
1390 Add explicit __mf_check call contexts.
1391 * Makefile.am: Add dependencies on mf-impl.h
1392 * Makefile.in: Regenerate.
1393 * configure.in: Comment out shared override.
1394 * configure: Regenerate.
1396 2002-08-22 Graydon Hoare <graydon@redhat.com>
1398 * mf-runtime.c (__mf_process_opts): Sanity-check free_queue_length.
1399 (__mf_check): Re-inialize and check heuristics before violation.
1400 (__mf_register): Permit updating pure-guess regions.
1401 * mf-hooks.c (__wrap_free): Correct some free queue logic.
1402 (__wrap_dlopen): New wrapper function.
1403 (__wrap_mmap): New wrapper function.
1404 (__wrap_munmap): New wrapper function.
1405 * mf-heuristics.c (__mf_register_ro_sections): Register *all* regions
1406 which are not stack addresses.
1407 (is_stack_address): New function.
1408 (__mf_init_heuristics): Save and restore state, always initialize with
1411 2002-08-21 Frank Ch. Eigler <fche@redhat.com>
1413 * mf-hooks.c (MF_VALIDATE_EXTENT): Rewrite to correct off-by-one
1414 error. Pass location string.
1415 (wrap_strcpy, wrap_strncpy): Remove extra %s in trace strings.
1416 * mf-runtime.c (options): Add lc-mask, lc-shift options.
1417 (__mf_process_opts): Apply some sanity checking for lc-mask.
1418 (__mf_check, __mf_violation): Take new location-string argument.
1419 Update callers to pass NULL if necessary.
1420 (__mf_backtrace): New smart backtracer function. Calls replace
1421 several ad-hoc blocks elsewhere.
1422 (__mf_describe_object): Remove bad reentrancy test. Improve
1424 * mf-runtime.h: Corresponding changes. Public/private markup.
1425 (__MF_CACHE_MISS_P): New macro.
1427 2002-08-20 Graydon Hoare <graydon@redhat.com>
1429 * mf-runtime.h: New option: stack_bound (heuristic).
1430 Move some macros out of implementation files.
1431 * mf-runtime.c: New option string: -stack-bound.
1432 Unify recursion protection with hooks.
1434 (__mf_check): Call __mf_heuristic_check.
1435 (__mf_process_opts): Fix "no-" processing.
1436 * mf-heuristics.c (__mf_heuristic_check): New function.
1437 * mf-hooks.c: Much off-by-one fixing, recursion protection.
1439 2002-08-20 Frank Ch. Eigler <fche@redhat.com>
1441 Option parsing improvements, region splitting bug fixes:
1442 * mf-heuristics.c (__mf_register_ro_sections): Add warned casts.
1443 * mf-runtime.h (heur_proc_map): New libmudflap option.
1444 * mf-runtime.c (__mf_set_default_options): Set it.
1445 (__mf_usage): Print default values/status.
1446 (__mf_process_opts): Support general "no-" option string prefix.
1447 (__mf_init): Print __mf_usage on unknown-option error.
1448 (__mf_register): Print trace message up front.
1449 Correct region splitting logic for case where a subregion disappears.
1450 Correct memory leak.
1451 (__mf_violation): Make even basic message conditional on option.
1454 * Makefile.am (TESTS_ENVIRONMENT): Add -no-heur-proc-map.
1455 (clean-local): New target.
1456 (test/*x rules): Add -g CFLAGS.
1457 (CFLAGS): Add -freorder-blocks.
1458 (MFCONFIG_CFLAGS, INCLUDE): Remove unneeded settings.
1459 * Makefile.in: Regenerated.
1460 * Makefile, mf-config.h: Removed files.
1462 2002-08-16 Graydon Hoare <graydon@redhat.com>
1464 * mf-runtime.c (__mf_insert_new_object): Factor out of
1466 (__mf_remove_old_object): Factor out of __mf_unregister.
1467 (__mf_register): Handle guessed regions, splitting
1468 guesses when new registrations arrive.
1469 (__mf_unregister): Do not unregister guesses.
1470 * mf-runtime.h: Move convenience macros around,
1471 declare new option fields. Add __MF_TYPE_GUESS.
1472 * mf-hooks.c (__wrap_*alloc): Use crumple zones.
1473 (__wrap_free): Call __real_free for deferred frees.
1474 * Makefile.am: Add more tests, fix dependency.
1475 * Makefile.in: Regenerate.
1476 * test/pass[13..17]-frag.c: New testcases.
1477 * test/fail[13..17]-frag.c: New testcases.
1479 2002-08-15 Graydon Hoare <graydon@redhat.com>
1481 * mf-heuristics.c: New file.
1482 * mf-runtime.c (options): Add -trace-calls option.
1483 (__mf_init): Call __mf_init_heuristics.
1485 2002-08-14 Graydon Hoare <graydon@redhat.com>
1487 * Makefile.am (TESTS): Add testsuite support.
1488 * Makefile.in: Regenerate.
1489 * test/mf-driver.c: New file.
1490 * test/buildtest.sh: New file.
1491 * test/passNN-frag.c: New testcases.
1492 * test/failNN-frag.c: New testcases.
1494 2002-08-14 Graydon Hoare <graydon@redhat.com>
1496 * mf-hooks.c: Change __real_strlen() to __real_strlen()+1 when
1497 verifying non-size-limited string extents.
1499 2002-08-14 Frank Ch. Eigler <fche@redhat.com>
1501 * mf-hooks.c: Make __wrap string* functions use __real_str[n]len
1502 instead of plain str[n]len for internal checks.
1503 * mf-runtime.c (__mf_violation): Print optional stack traceback.
1505 2002-08-14 Frank Ch. Eigler <fche@redhat.com>
1507 * mf-hooks.c: Remove #if-0 around hooks that are now ld-wrapped.
1509 2002-08-13 Graydon Hoare <graydon@redhat.com>
1511 * mf-runtime.c: Rework configuration to operate on
1512 environment variable options rather than #defines
1513 (__mf_violation): Add simple fork-a-gdb violaiton mode.
1514 (__mf_init): Set static __mf_active_p flag on startup,
1515 to inhibit mudflap wrap-based checking during crt0.s.
1516 * mf-runtime.h: Declare options structure.
1517 * mf-hooks.c: New wrappings for mem*, b*, str*
1518 libc functions (temporarily #if 0-ed out).
1520 2002-08-12 Frank Ch. Eigler <fche@redhat.com>
1522 * Makefile.am, configure.in: New files.
1523 * Makefile.in, Makefile, configure, config.h.in: New generated files.
1524 * stamp-h.in, aclocal.m4: Ditto.
1526 2002-08-08 Frank Ch. Eigler <fche@redhat.com>
1528 * Makefile: New file.
1529 * mf-config.h: New file: runtime configuration.
1530 * mf-hooks.c: New file: interposed libc functions.
1531 * mf-runtime.c: New file: bulk of runtime.
1532 * mf-runtime.h: New file: public functions.