src/share/vm/opto/type.hpp

Print this page


   1 /*
   2  * Copyright (c) 1997, 2009, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 







  25 // Portions of code courtesy of Clifford Click
  26 
  27 // Optimization - Graph Style
  28 
  29 
  30 // This class defines a Type lattice.  The lattice is used in the constant
  31 // propagation algorithms, and for some type-checking of the iloc code.
  32 // Basic types include RSD's (lower bound, upper bound, stride for integers),
  33 // float & double precision constants, sets of data-labels and code-labels.
  34 // The complete lattice is described below.  Subtypes have no relationship to
  35 // up or down in the lattice; that is entirely determined by the behavior of
  36 // the MEET/JOIN functions.
  37 
  38 class Dict;
  39 class Type;
  40 class   TypeD;
  41 class   TypeF;
  42 class   TypeInt;
  43 class   TypeLong;
  44 class   TypeNarrowOop;


1271 #define RShiftXNode  RShiftINode
1272 // For card marks and hashcodes
1273 #define URShiftXNode URShiftINode
1274 // UseOptoBiasInlining
1275 #define XorXNode     XorINode
1276 #define StoreXConditionalNode StoreIConditionalNode
1277 // Opcodes
1278 #define Op_LShiftX   Op_LShiftI
1279 #define Op_AndX      Op_AndI
1280 #define Op_AddX      Op_AddI
1281 #define Op_SubX      Op_SubI
1282 #define Op_XorX      Op_XorI
1283 #define Op_URShiftX  Op_URShiftI
1284 // conversions
1285 #define ConvI2X(x)   (x)
1286 #define ConvL2X(x)   ConvL2I(x)
1287 #define ConvX2I(x)   (x)
1288 #define ConvX2L(x)   ConvI2L(x)
1289 
1290 #endif


   1 /*
   2  * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 #ifndef SHARE_VM_OPTO_TYPE_HPP
  26 #define SHARE_VM_OPTO_TYPE_HPP
  27 
  28 #include "libadt/port.hpp"
  29 #include "opto/adlcVMDeps.hpp"
  30 #include "runtime/handles.hpp"
  31 
  32 // Portions of code courtesy of Clifford Click
  33 
  34 // Optimization - Graph Style
  35 
  36 
  37 // This class defines a Type lattice.  The lattice is used in the constant
  38 // propagation algorithms, and for some type-checking of the iloc code.
  39 // Basic types include RSD's (lower bound, upper bound, stride for integers),
  40 // float & double precision constants, sets of data-labels and code-labels.
  41 // The complete lattice is described below.  Subtypes have no relationship to
  42 // up or down in the lattice; that is entirely determined by the behavior of
  43 // the MEET/JOIN functions.
  44 
  45 class Dict;
  46 class Type;
  47 class   TypeD;
  48 class   TypeF;
  49 class   TypeInt;
  50 class   TypeLong;
  51 class   TypeNarrowOop;


1278 #define RShiftXNode  RShiftINode
1279 // For card marks and hashcodes
1280 #define URShiftXNode URShiftINode
1281 // UseOptoBiasInlining
1282 #define XorXNode     XorINode
1283 #define StoreXConditionalNode StoreIConditionalNode
1284 // Opcodes
1285 #define Op_LShiftX   Op_LShiftI
1286 #define Op_AndX      Op_AndI
1287 #define Op_AddX      Op_AddI
1288 #define Op_SubX      Op_SubI
1289 #define Op_XorX      Op_XorI
1290 #define Op_URShiftX  Op_URShiftI
1291 // conversions
1292 #define ConvI2X(x)   (x)
1293 #define ConvL2X(x)   ConvL2I(x)
1294 #define ConvX2I(x)   (x)
1295 #define ConvX2L(x)   ConvI2L(x)
1296 
1297 #endif
1298 
1299 #endif // SHARE_VM_OPTO_TYPE_HPP