00001 /* Null garbage collection for the GNU compiler. 00002 Copyright (C) 1998, 1999, 2000, 2003, 2004, 2005 00003 Free Software Foundation, Inc. 00004 00005 This file is part of GCC. 00006 00007 GCC is free software; you can redistribute it and/or modify it 00008 under the terms of the GNU General Public License as published by 00009 the Free Software Foundation; either version 2, or (at your option) 00010 any later version. 00011 00012 GCC is distributed in the hope that it will be useful, but WITHOUT 00013 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 00014 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 00015 License for more details. 00016 00017 You should have received a copy of the GNU General Public License 00018 along with GCC; see the file COPYING. If not, write to the Free 00019 Software Foundation, 59 Temple Place - Suite 330, Boston, MA 00020 02111-1307, USA. */ 00021 00022 /* This version is used by the gen* programs and certain language-specific 00023 targets (such as java), where we don't really need GC at all. 00024 This prevents problems with pulling in all the tree stuff. */ 00025 00026 #ifdef GENERATOR_FILE 00027 #include "bconfig.h" 00028 #else 00029 #include "config.h" 00030 #endif 00031 00032 #include "system.h" 00033 #include "coretypes.h" 00034 #include "ggc.h" 00035 00036 struct alloc_zone *rtl_zone = NULL; 00037 struct alloc_zone *garbage_zone = NULL; 00038 00039 void * 00040 ggc_alloc_typed_stat (enum gt_types_enum ARG_UNUSED (gte), size_t size 00041 MEM_STAT_DECL) 00042 { 00043 return xmalloc (size); 00044 } 00045 00046 void * 00047 ggc_alloc_stat (size_t size MEM_STAT_DECL) 00048 { 00049 return xmalloc (size); 00050 } 00051 00052 void * 00053 ggc_alloc_zone_stat (size_t size, struct alloc_zone * ARG_UNUSED (zone) 00054 MEM_STAT_DECL) 00055 { 00056 return xmalloc (size); 00057 } 00058 00059 void * 00060 ggc_alloc_cleared_stat (size_t size MEM_STAT_DECL) 00061 { 00062 return xcalloc (size, 1); 00063 } 00064 00065 void * 00066 ggc_realloc_stat (void *x, size_t size MEM_STAT_DECL) 00067 { 00068 return xrealloc (x, size); 00069 } 00070 00071 void 00072 ggc_free (void *p) 00073 { 00074 free (p); 00075 }
1.5.6