00001 //-*-c++-*- 00002 // ==================================================================== 00003 // ==================================================================== 00004 // 00005 // Module: optimizer.h 00006 // $Revision: 1.1.1.1 $ 00007 // $Date: 2005/10/21 19:00:00 $ 00008 // $Author: marcel $ 00009 // $Source: /proj/osprey/CVS/open64/osprey1.0/be/opt/optimizer.h,v $ 00010 // 00011 // Revision history: 00012 // 14-SEP-94 - Original Version 00013 // 00014 // ==================================================================== 00015 // 00016 // Copyright (C) 2000, 2001 Silicon Graphics, Inc. All Rights Reserved. 00017 // 00018 // This program is free software; you can redistribute it and/or modify 00019 // it under the terms of version 2 of the GNU General Public License as 00020 // published by the Free Software Foundation. 00021 // 00022 // This program is distributed in the hope that it would be useful, but 00023 // WITHOUT ANY WARRANTY; without even the implied warranty of 00024 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 00025 // 00026 // Further, this software is distributed without any warranty that it 00027 // is free of the rightful claim of any third person regarding 00028 // infringement or the like. Any license provided herein, whether 00029 // implied or otherwise, applies only to this software file. Patent 00030 // licenses, if any, provided herein do not apply to combinations of 00031 // this program with other software, or any other product whatsoever. 00032 // 00033 // You should have received a copy of the GNU General Public License 00034 // along with this program; if not, write the Free Software Foundation, 00035 // Inc., 59 Temple Place - Suite 330, Boston MA 02111-1307, USA. 00036 // 00037 // Contact information: Silicon Graphics, Inc., 1600 Amphitheatre Pky, 00038 // Mountain View, CA 94043, or: 00039 // 00040 // http://www.sgi.com 00041 // 00042 // For further information regarding this notice, see: 00043 // 00044 // http://oss.sgi.com/projects/GenInfo/NoticeExplan 00045 // 00046 // ==================================================================== 00047 // 00048 // Description: 00049 // 00050 // The external interface for the optimizer. 00051 // 00052 // ==================================================================== 00053 // ==================================================================== 00054 00055 00056 #ifndef optimizer_INCLUDED 00057 #define optimizer_INCLUDED "optimizer.h" 00058 #ifdef _KEEP_RCS_ID 00059 static char *optimizerrcs_id = optimizer_INCLUDED"$Revision$"; 00060 #endif /* _KEEP_RCS_ID */ 00061 00062 #include "opt_alias_interface.h" 00063 00064 /* The phases of PREOPT */ 00065 typedef enum { 00066 PREOPT_PHASE, // used for -PHASE:p 00067 PREOPT_LNO_PHASE, // used for -PHASE:l 00068 PREOPT_DUONLY_PHASE, // called by LNO, but will disable optimization */ 00069 #ifdef TARG_NVISA 00070 PREOPT_CMC_PHASE, 00071 #endif 00072 MAINOPT_PHASE, // used for -PHASE:w 00073 PREOPT_IPA0_PHASE, // called by IPL 00074 PREOPT_IPA1_PHASE, // called by main IPA 00075 } PREOPT_PHASES; 00076 00077 typedef PREOPT_PHASES OPT_PHASE; 00078 00079 #ifdef __cplusplus 00080 extern "C" { 00081 #endif 00082 00083 00084 /* Clients of the optimizer pass a WHIRL tree for the function, and 00085 * receive back a possibly optimized version of the tree. 00086 */ 00087 struct DU_MANAGER; 00088 00089 extern WN *Pre_Optimizer( INT32 /* PREOPT_PHASES */, WN *, struct DU_MANAGER * , struct ALIAS_MANAGER *); 00090 00091 struct DU_MANAGER* Create_Du_Manager(MEM_POOL *); 00092 void Delete_Du_Manager(struct DU_MANAGER *, MEM_POOL *); 00093 00094 00095 #ifdef __cplusplus 00096 } 00097 #endif 00098 #endif /* optimizer_INCLUDED */ 00099
1.5.6