00001 /* 00002 00003 Copyright (C) 2000, 2001 Silicon Graphics, Inc. All Rights Reserved. 00004 00005 This program is free software; you can redistribute it and/or modify it 00006 under the terms of version 2 of the GNU General Public License as 00007 published by the Free Software Foundation. 00008 00009 This program is distributed in the hope that it would be useful, but 00010 WITHOUT ANY WARRANTY; without even the implied warranty of 00011 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 00012 00013 Further, this software is distributed without any warranty that it is 00014 free of the rightful claim of any third person regarding infringement 00015 or the like. Any license provided herein, whether implied or 00016 otherwise, applies only to this software file. Patent licenses, if 00017 any, provided herein do not apply to combinations of this program with 00018 other software, or any other product whatsoever. 00019 00020 You should have received a copy of the GNU General Public License along 00021 with this program; if not, write the Free Software Foundation, Inc., 59 00022 Temple Place - Suite 330, Boston MA 02111-1307, USA. 00023 00024 Contact information: Silicon Graphics, Inc., 1600 Amphitheatre Pky, 00025 Mountain View, CA 94043, or: 00026 00027 http://www.sgi.com 00028 00029 For further information regarding this notice, see: 00030 00031 http://oss.sgi.com/projects/GenInfo/NoticeExplan 00032 00033 */ 00034 00035 00036 #ifndef common_include_INCLUDED 00037 #define common_include_INCLUDED 00038 /* ==================================================================== 00039 * ==================================================================== 00040 * 00041 * Module: common_include.h 00042 * $Revision: 1.2 $ 00043 * $Date: 02/11/07 23:41:59-00:00 $ 00044 * $Author: fchow@keyresearch.com $ 00045 * $Source: /scratch/mee/2.4-65/kpro64-pending/be/whirl2c/SCCS/s.common_include.h $ 00046 * 00047 * Revision history: 00048 * 07-Mar-95 - Original Version 00049 * 00050 * Description: 00051 * 00052 * Groups together the files to be included by virtually all 00053 * files translating WHIRL to another language. We also 00054 * provide macros for dynamic memory allocation in this header 00055 * file. 00056 * 00057 * ==================================================================== 00058 * ==================================================================== 00059 */ 00060 00061 #include <stdio.h> 00062 00063 #include "defs.h" /* Basic types, such as INT32 */ 00064 #include "config.h" 00065 #include "erglob.h" /* For errors.h and EC definitions */ 00066 #include "wn.h" /* WN nodes */ 00067 #include "symtab.h" /* TY and ST nodes */ 00068 #include "be_symtab.h" /* BE_ST flags */ 00069 #include "glob.h" /* Irb_File_Name */ 00070 /* Ensure that we never refer to Cur_PU_Name, since this will not be 00071 * initialized, but instead use the PUinfo facilities. 00072 */ 00073 #define Cur_PU_Name You_should_not_use("Cur_PU_Name") 00074 00075 #include "diagnostics.h" /* For diagnostics */ 00076 #include "wn_attr.h" /* Attributes of WN nodes (beyond wn_core.h) */ 00077 #include "stab_attr.h" /* Attributes of TY and ST nodes (beyond stab.h) */ 00078 #include "token_buffer.h" /* formatting tokenized output */ 00079 #include "w2cf_symtab.h" /* Identifier name-table */ 00080 00081 00082 // W2FC flag accessors.. 00083 00084 extern void Set_TY_is_translated_to_c(const TY_IDX ty) ; 00085 extern void Reset_TY_is_translated_to_c(const TY_IDX ty) ; 00086 extern BOOL TY_is_translated_to_c(const TY_IDX ty) ; 00087 extern void Clear_w2fc_flags(void) ; 00088 00089 00090 /* Some general utility routines for memory allocation. Include 00091 * "mempool.h" when using these! 00092 */ 00093 #define TYPE_ALLOC_N(type, count)\ 00094 TYPE_MEM_POOL_ALLOC_N(type, Malloc_Mem_Pool, count) 00095 00096 #define TYPE_REALLOC_N(type, old_ptr, old_count, new_count)\ 00097 TYPE_MEM_POOL_REALLOC_N(type, Malloc_Mem_Pool, old_ptr,\ 00098 old_count, new_count) 00099 00100 #define FREE(ptr) MEM_POOL_FREE(Malloc_Mem_Pool, ptr) 00101 00102 #endif /* common_include_INCLUDED */ 00103 00104
1.5.6