vfp.isa revision 7396
114184Sgabeblack@google.com// -*- mode:c++ -*- 214184Sgabeblack@google.com 314184Sgabeblack@google.com// Copyright (c) 2010 ARM Limited 414184Sgabeblack@google.com// All rights reserved 514184Sgabeblack@google.com// 614184Sgabeblack@google.com// The license below extends only to copyright in the software and shall 714184Sgabeblack@google.com// not be construed as granting a license to any other intellectual 814184Sgabeblack@google.com// property including but not limited to intellectual property relating 914184Sgabeblack@google.com// to a hardware implementation of the functionality of the software 1014184Sgabeblack@google.com// licensed hereunder. You may use the software subject to the license 1114184Sgabeblack@google.com// terms below provided that you ensure that this notice is replicated 1214184Sgabeblack@google.com// unmodified and in its entirety in all distributions of the software, 1314184Sgabeblack@google.com// modified or unmodified, in source code or in binary form. 1414184Sgabeblack@google.com// 1514184Sgabeblack@google.com// Redistribution and use in source and binary forms, with or without 1614184Sgabeblack@google.com// modification, are permitted provided that the following conditions are 1714184Sgabeblack@google.com// met: redistributions of source code must retain the above copyright 1814184Sgabeblack@google.com// notice, this list of conditions and the following disclaimer; 1914184Sgabeblack@google.com// redistributions in binary form must reproduce the above copyright 2014184Sgabeblack@google.com// notice, this list of conditions and the following disclaimer in the 2114184Sgabeblack@google.com// documentation and/or other materials provided with the distribution; 2214184Sgabeblack@google.com// neither the name of the copyright holders nor the names of its 2314184Sgabeblack@google.com// contributors may be used to endorse or promote products derived from 2414184Sgabeblack@google.com// this software without specific prior written permission. 2514184Sgabeblack@google.com// 2614184Sgabeblack@google.com// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 2714184Sgabeblack@google.com// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 2814184Sgabeblack@google.com// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 2914184Sgabeblack@google.com// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 3014184Sgabeblack@google.com// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 3114184Sgabeblack@google.com// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 3214184Sgabeblack@google.com// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 3314184Sgabeblack@google.com// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 3414184Sgabeblack@google.com// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 3514184Sgabeblack@google.com// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 3614184Sgabeblack@google.com// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 3714184Sgabeblack@google.com// 3814184Sgabeblack@google.com// Authors: Gabe Black 3914184Sgabeblack@google.com 4014184Sgabeblack@google.comdef template FpRegRegOpDeclare {{ 4114184Sgabeblack@google.comclass %(class_name)s : public %(base_class)s 4214184Sgabeblack@google.com{ 4314184Sgabeblack@google.com public: 4414184Sgabeblack@google.com // Constructor 4514184Sgabeblack@google.com %(class_name)s(ExtMachInst machInst, 4614184Sgabeblack@google.com IntRegIndex _dest, IntRegIndex _op1, 4714184Sgabeblack@google.com VfpMicroMode mode = VfpNotAMicroop); 4814184Sgabeblack@google.com %(BasicExecDeclare)s 4914184Sgabeblack@google.com}; 5014184Sgabeblack@google.com}}; 5114184Sgabeblack@google.com 5214184Sgabeblack@google.comdef template FpRegRegOpConstructor {{ 5314184Sgabeblack@google.com inline %(class_name)s::%(class_name)s(ExtMachInst machInst, 5414184Sgabeblack@google.com IntRegIndex _dest, IntRegIndex _op1, 5514184Sgabeblack@google.com VfpMicroMode mode) 5614184Sgabeblack@google.com : %(base_class)s("%(mnemonic)s", machInst, %(op_class)s, 5714184Sgabeblack@google.com _dest, _op1, mode) 5814184Sgabeblack@google.com { 5914184Sgabeblack@google.com %(constructor)s; 6014184Sgabeblack@google.com } 6114184Sgabeblack@google.com}}; 6214184Sgabeblack@google.com 6314184Sgabeblack@google.comdef template FpRegImmOpDeclare {{ 6414184Sgabeblack@google.comclass %(class_name)s : public %(base_class)s 6514184Sgabeblack@google.com{ 6614184Sgabeblack@google.com public: 6714184Sgabeblack@google.com // Constructor 6814184Sgabeblack@google.com %(class_name)s(ExtMachInst machInst, IntRegIndex _dest, 6914184Sgabeblack@google.com uint64_t _imm, VfpMicroMode mode = VfpNotAMicroop); 7014184Sgabeblack@google.com %(BasicExecDeclare)s 7114184Sgabeblack@google.com}; 7214184Sgabeblack@google.com}}; 7314184Sgabeblack@google.com 7414184Sgabeblack@google.comdef template FpRegImmOpConstructor {{ 7514184Sgabeblack@google.com inline %(class_name)s::%(class_name)s(ExtMachInst machInst, 7614184Sgabeblack@google.com IntRegIndex _dest, uint64_t _imm, VfpMicroMode mode) 7714184Sgabeblack@google.com : %(base_class)s("%(mnemonic)s", machInst, %(op_class)s, 7814184Sgabeblack@google.com _dest, _imm, mode) 7914184Sgabeblack@google.com { 8014184Sgabeblack@google.com %(constructor)s; 8114184Sgabeblack@google.com } 8214184Sgabeblack@google.com}}; 8314184Sgabeblack@google.com 8414184Sgabeblack@google.comdef template FpRegRegImmOpDeclare {{ 8514184Sgabeblack@google.comclass %(class_name)s : public %(base_class)s 8614184Sgabeblack@google.com{ 8714184Sgabeblack@google.com public: 8814184Sgabeblack@google.com // Constructor 8914184Sgabeblack@google.com %(class_name)s(ExtMachInst machInst, 9014184Sgabeblack@google.com IntRegIndex _dest, IntRegIndex _op1, 9114184Sgabeblack@google.com uint64_t _imm, VfpMicroMode mode = VfpNotAMicroop); 9214184Sgabeblack@google.com %(BasicExecDeclare)s 9314184Sgabeblack@google.com}; 9414184Sgabeblack@google.com}}; 9514184Sgabeblack@google.com 9614184Sgabeblack@google.comdef template FpRegRegImmOpConstructor {{ 9714184Sgabeblack@google.com inline %(class_name)s::%(class_name)s(ExtMachInst machInst, 9814184Sgabeblack@google.com IntRegIndex _dest, 9914184Sgabeblack@google.com IntRegIndex _op1, 10014184Sgabeblack@google.com uint64_t _imm, 10114184Sgabeblack@google.com VfpMicroMode mode) 10214184Sgabeblack@google.com : %(base_class)s("%(mnemonic)s", machInst, %(op_class)s, 10314184Sgabeblack@google.com _dest, _op1, _imm, mode) 10414184Sgabeblack@google.com { 10514184Sgabeblack@google.com %(constructor)s; 10614184Sgabeblack@google.com } 10714184Sgabeblack@google.com}}; 10814184Sgabeblack@google.com 10914184Sgabeblack@google.comdef template FpRegRegRegOpDeclare {{ 11014184Sgabeblack@google.comclass %(class_name)s : public %(base_class)s 11114184Sgabeblack@google.com{ 11214184Sgabeblack@google.com public: 11314184Sgabeblack@google.com // Constructor 11414184Sgabeblack@google.com %(class_name)s(ExtMachInst machInst, 11514184Sgabeblack@google.com IntRegIndex _dest, IntRegIndex _op1, IntRegIndex _op2, 11614184Sgabeblack@google.com VfpMicroMode mode = VfpNotAMicroop); 11714184Sgabeblack@google.com %(BasicExecDeclare)s 11814184Sgabeblack@google.com}; 11914184Sgabeblack@google.com}}; 12014184Sgabeblack@google.com 12114184Sgabeblack@google.comdef template FpRegRegRegOpConstructor {{ 12214184Sgabeblack@google.com inline %(class_name)s::%(class_name)s(ExtMachInst machInst, 12314184Sgabeblack@google.com IntRegIndex _dest, 12414184Sgabeblack@google.com IntRegIndex _op1, 12514184Sgabeblack@google.com IntRegIndex _op2, 12614184Sgabeblack@google.com VfpMicroMode mode) 12714184Sgabeblack@google.com : %(base_class)s("%(mnemonic)s", machInst, %(op_class)s, 12814184Sgabeblack@google.com _dest, _op1, _op2, mode) 12914184Sgabeblack@google.com { 13014184Sgabeblack@google.com %(constructor)s; 13114184Sgabeblack@google.com } 13214184Sgabeblack@google.com}}; 13314184Sgabeblack@google.com