vectornode.hpp revision 29
0N/A * Copyright 2007 Sun Microsystems, Inc. All Rights Reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 0N/A * published by the Free Software Foundation. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 0N/A * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 0N/A * CA 95054 USA or visit www.sun.com if you need additional information or 0N/A * have any questions. 0N/A//------------------------------VectorNode-------------------------------------- 0N/A // Element and vector type 0N/A // Vector opcode from scalar opcode 0N/A//===========================Vector=ALU=Operations==================================== 0N/A//------------------------------AddVBNode--------------------------------------- 0N/A//------------------------------AddVCNode--------------------------------------- 0N/A//------------------------------AddVSNode--------------------------------------- 0N/A//------------------------------AddVINode--------------------------------------- 0N/A//------------------------------AddVLNode--------------------------------------- 0N/A//------------------------------AddVFNode--------------------------------------- 0N/A//------------------------------AddVDNode--------------------------------------- 0N/A//------------------------------SubVBNode--------------------------------------- 0N/A// Vector subtract byte 0N/A//------------------------------SubVCNode--------------------------------------- 0N/A// Vector subtract char 0N/A//------------------------------SubVSNode--------------------------------------- 0N/A// Vector subtract short 0N/A//------------------------------SubVINode--------------------------------------- 0N/A// Vector subtract int 0N/A//------------------------------SubVLNode--------------------------------------- 0N/A// Vector subtract long 0N/A//------------------------------SubVFNode--------------------------------------- 0N/A// Vector subtract float 0N/A//------------------------------SubVDNode--------------------------------------- 0N/A// Vector subtract double 0N/A//------------------------------MulVFNode--------------------------------------- 0N/A// Vector multiply float 0N/A//------------------------------MulVDNode--------------------------------------- 0N/A// Vector multiply double 0N/A//------------------------------DivVFNode--------------------------------------- 0N/A// Vector divide float 0N/A//------------------------------DivVDNode--------------------------------------- 0N/A// Vector Divide double 0N/A//------------------------------LShiftVBNode--------------------------------------- 0N/A// Vector lshift byte 0N/A//------------------------------LShiftVCNode--------------------------------------- 0N/A// Vector lshift chars 0N/A//------------------------------LShiftVSNode--------------------------------------- 0N/A// Vector lshift shorts 0N/A//------------------------------LShiftVINode--------------------------------------- 0N/A// Vector lshift ints 0N/A//------------------------------URShiftVBNode--------------------------------------- 0N/A// Vector urshift bytes 0N/A//------------------------------URShiftVCNode--------------------------------------- 0N/A// Vector urshift char 0N/A//------------------------------URShiftVSNode--------------------------------------- 0N/A// Vector urshift shorts 0N/A//------------------------------URShiftVINode--------------------------------------- 0N/A// Vector urshift ints 0N/A//------------------------------AndVNode--------------------------------------- 0N/A//------------------------------OrVNode--------------------------------------- 0N/A//------------------------------XorVNode--------------------------------------- 0N/A//================================= M E M O R Y ================================== 0N/A//------------------------------VectorLoadNode-------------------------------------- 0N/A// Vector Load from memory 0N/A // For use in constructor 0N/A // Element and vector type 0N/A // Vector opcode from scalar opcode 0N/A//------------------------------Load16BNode-------------------------------------- 0N/A// Vector load of 16 bytes (8bits signed) from memory 0N/A//------------------------------Load8BNode-------------------------------------- 0N/A// Vector load of 8 bytes (8bits signed) from memory 0N/A//------------------------------Load4BNode-------------------------------------- 0N/A// Vector load of 4 bytes (8bits signed) from memory 0N/A//------------------------------Load8CNode-------------------------------------- 0N/A// Vector load of 8 chars (16bits unsigned) from memory 0N/A//------------------------------Load4CNode-------------------------------------- 0N/A// Vector load of 4 chars (16bits unsigned) from memory 0N/A//------------------------------Load2CNode-------------------------------------- 0N/A// Vector load of 2 chars (16bits unsigned) from memory 0N/A//------------------------------Load8SNode-------------------------------------- 0N/A// Vector load of 8 shorts (16bits signed) from memory 0N/A//------------------------------Load4SNode-------------------------------------- 0N/A// Vector load of 4 shorts (16bits signed) from memory 0N/A//------------------------------Load2SNode-------------------------------------- 0N/A// Vector load of 2 shorts (16bits signed) from memory 0N/A//------------------------------Load4INode-------------------------------------- 0N/A// Vector load of 4 integers (32bits signed) from memory 0N/A//------------------------------Load2INode-------------------------------------- 0N/A// Vector load of 2 integers (32bits signed) from memory 0N/A//------------------------------Load2LNode-------------------------------------- 0N/A// Vector load of 2 longs (64bits signed) from memory 0N/A//------------------------------Load4FNode-------------------------------------- 0N/A// Vector load of 4 floats (32bits) from memory 0N/A//------------------------------Load2FNode-------------------------------------- 0N/A// Vector load of 2 floats (32bits) from memory 0N/A//------------------------------Load2DNode-------------------------------------- 0N/A// Vector load of 2 doubles (64bits) from memory 0N/A//------------------------------VectorStoreNode-------------------------------------- 0N/A// Vector Store to memory 0N/A // Element and vector type 0N/A // Vector opcode from scalar opcode 0N/A//------------------------------Store16BNode-------------------------------------- 0N/A// Vector store of 16 bytes (8bits signed) to memory 0N/A//------------------------------Store8BNode-------------------------------------- 0N/A// Vector store of 8 bytes (8bits signed) to memory 0N/A//------------------------------Store4BNode-------------------------------------- 0N/A// Vector store of 4 bytes (8bits signed) to memory 0N/A//------------------------------Store8CNode-------------------------------------- 0N/A//------------------------------Store4CNode-------------------------------------- 0N/A//------------------------------Store2CNode-------------------------------------- 0N/A//------------------------------Store4INode-------------------------------------- 0N/A// Vector store of 4 integers (32bits signed) to memory 0N/A//------------------------------Store2INode-------------------------------------- 0N/A// Vector store of 2 integers (32bits signed) to memory 0N/A//------------------------------Store2LNode-------------------------------------- 0N/A// Vector store of 2 longs (64bits signed) to memory 0N/A//------------------------------Store4FNode-------------------------------------- 0N/A// Vector store of 4 floats (32bits) to memory 0N/A//------------------------------Store2FNode-------------------------------------- 0N/A// Vector store of 2 floats (32bits) to memory 0N/A//------------------------------Store2DNode-------------------------------------- 0N/A// Vector store of 2 doubles (64bits) to memory 0N/A//=========================Promote_Scalar_to_Vector==================================== 0N/A//------------------------------Replicate16BNode--------------------------------------- 0N/A// Replicate byte scalar to be vector of 16 bytes 0N/A//------------------------------Replicate8BNode--------------------------------------- 0N/A// Replicate byte scalar to be vector of 8 bytes 0N/A//------------------------------Replicate4BNode--------------------------------------- 0N/A// Replicate byte scalar to be vector of 4 bytes 0N/A//------------------------------Replicate8CNode--------------------------------------- 0N/A// Replicate char scalar to be vector of 8 chars 0N/A//------------------------------Replicate4CNode--------------------------------------- 0N/A// Replicate char scalar to be vector of 4 chars 0N/A//------------------------------Replicate2CNode--------------------------------------- 0N/A// Replicate char scalar to be vector of 2 chars 0N/A//------------------------------Replicate8SNode--------------------------------------- 0N/A// Replicate short scalar to be vector of 8 shorts 0N/A//------------------------------Replicate4SNode--------------------------------------- 0N/A// Replicate short scalar to be vector of 4 shorts 0N/A//------------------------------Replicate2SNode--------------------------------------- 0N/A// Replicate short scalar to be vector of 2 shorts 0N/A//------------------------------Replicate4INode--------------------------------------- 0N/A// Replicate int scalar to be vector of 4 ints 0N/A//------------------------------Replicate2INode--------------------------------------- 0N/A// Replicate int scalar to be vector of 2 ints 0N/A//------------------------------Replicate2LNode--------------------------------------- 0N/A// Replicate long scalar to be vector of 2 longs 0N/A//------------------------------Replicate4FNode--------------------------------------- 0N/A// Replicate float scalar to be vector of 4 floats 0N/A//------------------------------Replicate2FNode--------------------------------------- 0N/A// Replicate float scalar to be vector of 2 floats 0N/A//------------------------------Replicate2DNode--------------------------------------- 0N/A// Replicate double scalar to be vector of 2 doubles 0N/A//========================Pack_Scalars_into_a_Vector============================== 0N/A//------------------------------PackNode--------------------------------------- 0N/A// Pack parent class (not for code generation). 0N/A // Create a binary tree form for Packs. [lo, hi) (half-open) range 0N/A//------------------------------PackBNode--------------------------------------- 0N/A// Pack byte scalars into vector 0N/A//------------------------------PackCNode--------------------------------------- 0N/A// Pack char scalars into vector 0N/A//------------------------------PackSNode--------------------------------------- 0N/A// Pack short scalars into a vector 0N/A//------------------------------PackINode--------------------------------------- 0N/A// Pack integer scalars into a vector 0N/A//------------------------------PackLNode--------------------------------------- 0N/A// Pack long scalars into a vector 0N/A//------------------------------PackFNode--------------------------------------- 0N/A// Pack float scalars into vector 0N/A//------------------------------PackDNode--------------------------------------- 0N/A// Pack double scalars into a vector 0N/A// The Pack2xN nodes assist code generation. They are created from 0N/A// Pack4C, etc. nodes in final_graph_reshape in the form of a 0N/A// balanced, binary tree. 0N/A//------------------------------Pack2x1BNode----------------------------------------- 0N/A// Pack 2 1-byte integers into vector of 2 bytes 0N/A//------------------------------Pack2x2BNode--------------------------------------- 0N/A// Pack 2 2-byte integers into vector of 4 bytes 0N/A//========================Extract_Scalar_from_Vector=============================== 0N/A//------------------------------ExtractNode--------------------------------------- 0N/A// Extract a scalar from a vector at position "pos" 0N/A//------------------------------ExtractBNode--------------------------------------- 0N/A// Extract a byte from a vector at position "pos" 0N/A//------------------------------ExtractCNode--------------------------------------- 0N/A// Extract a char from a vector at position "pos" 0N/A//------------------------------ExtractSNode--------------------------------------- 0N/A// Extract a short from a vector at position "pos" 0N/A//------------------------------ExtractINode--------------------------------------- 0N/A// Extract an int from a vector at position "pos" 0N/A//------------------------------ExtractLNode--------------------------------------- 0N/A// Extract a long from a vector at position "pos" 0N/A//------------------------------ExtractFNode--------------------------------------- 0N/A// Extract a float from a vector at position "pos" 0N/A//------------------------------ExtractDNode--------------------------------------- 0N/A// Extract a double from a vector at position "pos"