includes.isa revision 5083
14158Sgblack@eecs.umich.edu// Copyright (c) 2007 The Regents of The University of Michigan
24158Sgblack@eecs.umich.edu// All rights reserved.
34158Sgblack@eecs.umich.edu//
44158Sgblack@eecs.umich.edu// Redistribution and use in source and binary forms, with or without
54158Sgblack@eecs.umich.edu// modification, are permitted provided that the following conditions are
64158Sgblack@eecs.umich.edu// met: redistributions of source code must retain the above copyright
74158Sgblack@eecs.umich.edu// notice, this list of conditions and the following disclaimer;
84158Sgblack@eecs.umich.edu// redistributions in binary form must reproduce the above copyright
94158Sgblack@eecs.umich.edu// notice, this list of conditions and the following disclaimer in the
104158Sgblack@eecs.umich.edu// documentation and/or other materials provided with the distribution;
114158Sgblack@eecs.umich.edu// neither the name of the copyright holders nor the names of its
124158Sgblack@eecs.umich.edu// contributors may be used to endorse or promote products derived from
134158Sgblack@eecs.umich.edu// this software without specific prior written permission.
144158Sgblack@eecs.umich.edu//
154158Sgblack@eecs.umich.edu// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
164158Sgblack@eecs.umich.edu// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
174158Sgblack@eecs.umich.edu// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
184158Sgblack@eecs.umich.edu// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
194158Sgblack@eecs.umich.edu// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
204158Sgblack@eecs.umich.edu// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
214158Sgblack@eecs.umich.edu// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
224158Sgblack@eecs.umich.edu// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
234158Sgblack@eecs.umich.edu// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
244158Sgblack@eecs.umich.edu// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
254158Sgblack@eecs.umich.edu// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
264158Sgblack@eecs.umich.edu//
274158Sgblack@eecs.umich.edu// Authors: Gabe Black
284158Sgblack@eecs.umich.edu
294158Sgblack@eecs.umich.edu// Copyright (c) 2007 The Hewlett-Packard Development Company
304158Sgblack@eecs.umich.edu// All rights reserved.
314158Sgblack@eecs.umich.edu//
324158Sgblack@eecs.umich.edu// Redistribution and use of this software in source and binary forms,
334158Sgblack@eecs.umich.edu// with or without modification, are permitted provided that the
344158Sgblack@eecs.umich.edu// following conditions are met:
354158Sgblack@eecs.umich.edu//
364158Sgblack@eecs.umich.edu// The software must be used only for Non-Commercial Use which means any
374158Sgblack@eecs.umich.edu// use which is NOT directed to receiving any direct monetary
384158Sgblack@eecs.umich.edu// compensation for, or commercial advantage from such use.  Illustrative
394158Sgblack@eecs.umich.edu// examples of non-commercial use are academic research, personal study,
404158Sgblack@eecs.umich.edu// teaching, education and corporate research & development.
414158Sgblack@eecs.umich.edu// Illustrative examples of commercial use are distributing products for
424158Sgblack@eecs.umich.edu// commercial advantage and providing services using the software for
434158Sgblack@eecs.umich.edu// commercial advantage.
444158Sgblack@eecs.umich.edu//
454158Sgblack@eecs.umich.edu// If you wish to use this software or functionality therein that may be
464158Sgblack@eecs.umich.edu// covered by patents for commercial use, please contact:
474158Sgblack@eecs.umich.edu//     Director of Intellectual Property Licensing
484158Sgblack@eecs.umich.edu//     Office of Strategy and Technology
494158Sgblack@eecs.umich.edu//     Hewlett-Packard Company
504158Sgblack@eecs.umich.edu//     1501 Page Mill Road
514158Sgblack@eecs.umich.edu//     Palo Alto, California  94304
524158Sgblack@eecs.umich.edu//
534158Sgblack@eecs.umich.edu// Redistributions of source code must retain the above copyright notice,
544158Sgblack@eecs.umich.edu// this list of conditions and the following disclaimer.  Redistributions
554158Sgblack@eecs.umich.edu// in binary form must reproduce the above copyright notice, this list of
564158Sgblack@eecs.umich.edu// conditions and the following disclaimer in the documentation and/or
574158Sgblack@eecs.umich.edu// other materials provided with the distribution.  Neither the name of
584158Sgblack@eecs.umich.edu// the COPYRIGHT HOLDER(s), HEWLETT-PACKARD COMPANY, nor the names of its
594158Sgblack@eecs.umich.edu// contributors may be used to endorse or promote products derived from
604158Sgblack@eecs.umich.edu// this software without specific prior written permission.  No right of
614158Sgblack@eecs.umich.edu// sublicense is granted herewith.  Derivatives of the software and
624158Sgblack@eecs.umich.edu// output created using the software may be prepared, but only for
634158Sgblack@eecs.umich.edu// Non-Commercial Uses.  Derivatives of the software may be shared with
644158Sgblack@eecs.umich.edu// others provided: (i) the others agree to abide by the list of
654158Sgblack@eecs.umich.edu// conditions herein which includes the Non-Commercial Use restrictions;
664158Sgblack@eecs.umich.edu// and (ii) such Derivatives of the software include the above copyright
674158Sgblack@eecs.umich.edu// notice to acknowledge the contribution from this software where
684158Sgblack@eecs.umich.edu// applicable, this list of conditions and the disclaimer below.
694158Sgblack@eecs.umich.edu//
704158Sgblack@eecs.umich.edu// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
714158Sgblack@eecs.umich.edu// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
724158Sgblack@eecs.umich.edu// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
734158Sgblack@eecs.umich.edu// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
744158Sgblack@eecs.umich.edu// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
754158Sgblack@eecs.umich.edu// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
764158Sgblack@eecs.umich.edu// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
774158Sgblack@eecs.umich.edu// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
784158Sgblack@eecs.umich.edu// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
794158Sgblack@eecs.umich.edu// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
804158Sgblack@eecs.umich.edu// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
814158Sgblack@eecs.umich.edu//
824158Sgblack@eecs.umich.edu// Authors: Gabe Black
834158Sgblack@eecs.umich.edu
844158Sgblack@eecs.umich.edu////////////////////////////////////////////////////////////////////
854158Sgblack@eecs.umich.edu//
864323Sgblack@eecs.umich.edu// Output include file directives. Also import the python modules we
874323Sgblack@eecs.umich.edu// need for all the x86 custom decoder stuff
884158Sgblack@eecs.umich.edu//
894158Sgblack@eecs.umich.edu
904323Sgblack@eecs.umich.edulet {{
914323Sgblack@eecs.umich.edu    import copy
924323Sgblack@eecs.umich.edu}};
934323Sgblack@eecs.umich.edu
944158Sgblack@eecs.umich.eduoutput header {{
954158Sgblack@eecs.umich.edu#include <cstring>
964158Sgblack@eecs.umich.edu#include <sstream>
974158Sgblack@eecs.umich.edu#include <iostream>
984158Sgblack@eecs.umich.edu
994601Sgblack@eecs.umich.edu#include "arch/x86/emulenv.hh"
1005083Sgblack@eecs.umich.edu#include "arch/x86/insts/microfpop.hh"
1014679Sgblack@eecs.umich.edu#include "arch/x86/insts/microldstop.hh"
1024679Sgblack@eecs.umich.edu#include "arch/x86/insts/microregop.hh"
1034679Sgblack@eecs.umich.edu#include "arch/x86/insts/static_inst.hh"
1044158Sgblack@eecs.umich.edu#include "arch/x86/isa_traits.hh"
1054158Sgblack@eecs.umich.edu#include "arch/x86/regfile.hh"
1064528Sgblack@eecs.umich.edu#include "arch/x86/types.hh"
1074158Sgblack@eecs.umich.edu#include "base/misc.hh"
1084158Sgblack@eecs.umich.edu#include "cpu/static_inst.hh"
1094158Sgblack@eecs.umich.edu#include "mem/packet.hh"
1104616Sgblack@eecs.umich.edu#include "sim/faults.hh"
1114158Sgblack@eecs.umich.edu}};
1124158Sgblack@eecs.umich.edu
1134158Sgblack@eecs.umich.eduoutput decoder {{
1144616Sgblack@eecs.umich.edu#include "arch/x86/faults.hh"
1155026Sgblack@eecs.umich.edu#include "arch/x86/floatregs.hh"
1164685Sgblack@eecs.umich.edu#include "arch/x86/miscregs.hh"
1174616Sgblack@eecs.umich.edu#include "arch/x86/segmentregs.hh"
1184158Sgblack@eecs.umich.edu#include "base/cprintf.hh"
1194158Sgblack@eecs.umich.edu#include "base/loader/symtab.hh"
1204158Sgblack@eecs.umich.edu#include "cpu/thread_context.hh"  // for Jump::branchTarget()
1214158Sgblack@eecs.umich.edu#include "mem/packet.hh"
1224158Sgblack@eecs.umich.edu
1234158Sgblack@eecs.umich.edu#if defined(linux) || defined(__APPLE__)
1244158Sgblack@eecs.umich.edu#include <fenv.h>
1254158Sgblack@eecs.umich.edu#endif
1264158Sgblack@eecs.umich.edu#include <algorithm>
1274158Sgblack@eecs.umich.edu
1284158Sgblack@eecs.umich.eduusing namespace X86ISA;
1294158Sgblack@eecs.umich.edu}};
1304158Sgblack@eecs.umich.edu
1314158Sgblack@eecs.umich.eduoutput exec {{
1324158Sgblack@eecs.umich.edu#if defined(linux) || defined(__APPLE__)
1334158Sgblack@eecs.umich.edu#include <fenv.h>
1344158Sgblack@eecs.umich.edu#endif
1354158Sgblack@eecs.umich.edu
1364158Sgblack@eecs.umich.edu#if defined(__sun) || defined (__OpenBSD__)
1374158Sgblack@eecs.umich.edu#include <ieeefp.h>
1384158Sgblack@eecs.umich.edu#endif
1394158Sgblack@eecs.umich.edu
1404158Sgblack@eecs.umich.edu#if FULL_SYSTEM
1414158Sgblack@eecs.umich.edu#include "sim/pseudo_inst.hh"
1424158Sgblack@eecs.umich.edu#endif
1434158Sgblack@eecs.umich.edu
1444158Sgblack@eecs.umich.edu#include <limits>
1454158Sgblack@eecs.umich.edu
1464158Sgblack@eecs.umich.edu#include <cmath>
1475058Sgblack@eecs.umich.edu#include "arch/x86/miscregs.hh"
1484158Sgblack@eecs.umich.edu#include "base/bigint.hh"
1494158Sgblack@eecs.umich.edu#include "cpu/base.hh"
1504158Sgblack@eecs.umich.edu#include "cpu/exetrace.hh"
1514158Sgblack@eecs.umich.edu#include "sim/sim_exit.hh"
1524158Sgblack@eecs.umich.edu#include "mem/packet.hh"
1534158Sgblack@eecs.umich.edu#include "mem/packet_access.hh"
1544158Sgblack@eecs.umich.edu
1554158Sgblack@eecs.umich.eduusing namespace X86ISA;
1564158Sgblack@eecs.umich.eduusing namespace std;
1574158Sgblack@eecs.umich.edu}};
1584158Sgblack@eecs.umich.edu
159