From af5f3db67c5dcbbc7b2038fe781d03301b94783d Mon Sep 17 00:00:00 2001 From: Andrew Cagney Date: Fri, 12 Jul 2002 15:23:10 +0000 Subject: * bcache.h: Update copyright. (struct bstring, struct bcache): Move definition to "bcache.c". Replaced by opaque declaration. (bcache_xfree): Replace free_bcache. (bcache_xmalloc, bcache_memory_used): Declare. * bcache.c: Update copyright. (struct bstring, struct bcache): Moved to here from "bcache.h". Update comments. (bcache_xmalloc, bcache_memory_used): New functions. (bcache_xfree): Replace function free_bcache. * Makefile.in (objfiles.o): Add $(bcache_h). (objfiles_h): Remove $(bcache_h). (symfile.o): Add $(bcache_h). * symmisc.c: Update copyright. (print_symbol_bcache_statistics): Pass psymbol_cache by value. (print_objfile_statistics): Use bcache_memory_used. * symfile.c: Include "bcache.h". (reread_symbols): Use bcache_xfree. (reread_symbols): Use bcache_xmalloc and bcache_xfree. (add_psymbol_to_list): Pass psymbol_cache by value. (add_psymbol_with_dem_name_to_list): Ditto. * objfiles.h: Update copyright. (struct bcache): Declare opaque. Do not include "bcache.h". (struct objfile): Change psymbol_cache and macro_cache to ``struct bcache'' pointers. * dwarf2read.c (macro_start_file): Pass macro_cache by value. * objfiles.c: Include "bcache.h". Update copyright. (allocate_objfile): Use bcache_xmalloc to create psymbol_cache and macro_cache. (free_objfile): Use bcache_xfree. --- gdb/symmisc.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'gdb/symmisc.c') diff --git a/gdb/symmisc.c b/gdb/symmisc.c index 370b76e..55f6926 100644 --- a/gdb/symmisc.c +++ b/gdb/symmisc.c @@ -1,6 +1,8 @@ /* Do various things to symbol tables (other than lookup), for GDB. - Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, - 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc. + + Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, + 1995, 1996, 1997, 1998, 1999, 2000, 2002 Free Software Foundation, + Inc. This file is part of GDB. @@ -167,7 +169,7 @@ print_symbol_bcache_statistics (void) ALL_OBJFILES (objfile) { printf_filtered ("Byte cache statistics for '%s':\n", objfile->name); - print_bcache_statistics (&objfile->psymbol_cache, "partial symbol cache"); + print_bcache_statistics (objfile->psymbol_cache, "partial symbol cache"); } immediate_quit--; } @@ -202,9 +204,9 @@ print_objfile_statistics (void) printf_filtered (" Total memory used for psymbol obstack: %d\n", obstack_memory_used (&objfile->psymbol_obstack)); printf_filtered (" Total memory used for psymbol cache: %d\n", - obstack_memory_used (&objfile->psymbol_cache.cache)); + bcache_memory_used (objfile->psymbol_cache)); printf_filtered (" Total memory used for macro cache: %d\n", - obstack_memory_used (&objfile->macro_cache.cache)); + bcache_memory_used (objfile->macro_cache)); printf_filtered (" Total memory used for symbol obstack: %d\n", obstack_memory_used (&objfile->symbol_obstack)); printf_filtered (" Total memory used for type obstack: %d\n", -- cgit v1.1