blob: d26ef9a73c80dabea0b17d863a65ab6ef24696c5 [file] [log] [blame]
Chris Lattner762fb5f2003-08-03 15:47:49 +00001//===- X86.td - Target definition file for the Intel X86 arch ---*- C++ -*-===//
John Criswell856ba762003-10-21 15:17:13 +00002//
3// The LLVM Compiler Infrastructure
4//
5// This file was developed by the LLVM research group and is distributed under
6// the University of Illinois Open Source License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
Chris Lattner762fb5f2003-08-03 15:47:49 +00009//
10// This is a target description file for the Intel i386 architecture, refered to
11// here as the "X86" architecture.
12//
13//===----------------------------------------------------------------------===//
14
Chris Lattnerc8f45872003-08-04 04:59:56 +000015// Get the target-independent interfaces which we are implementing...
Chris Lattner762fb5f2003-08-03 15:47:49 +000016//
17include "../Target.td"
18
19//===----------------------------------------------------------------------===//
20// Register File Description
21//===----------------------------------------------------------------------===//
22
23include "X86RegisterInfo.td"
24
Chris Lattnerb77eb782003-08-03 18:19:37 +000025//===----------------------------------------------------------------------===//
26// Instruction Descriptions
27//===----------------------------------------------------------------------===//
28
Chris Lattner1cca5e32003-08-03 21:54:21 +000029include "X86InstrInfo.td"
30
Chris Lattnerb77eb782003-08-03 18:19:37 +000031def X86InstrInfo : InstrInfo {
Chris Lattnerc8f45872003-08-04 04:59:56 +000032 let PHIInst = PHI;
Chris Lattner1cca5e32003-08-03 21:54:21 +000033
34 // Define how we want to layout our TargetSpecific information field... This
35 // should be kept up-to-date with the fields in the X86InstrInfo.h file.
Chris Lattner2959b6e2003-08-06 15:32:20 +000036 let TSFlagsFields = ["FormBits" , "hasOpSizePrefix" , "Prefix", "TypeBits",
37 "FPFormBits", "printImplicitUses", "Opcode"];
38 let TSFlagsShifts = [ 0, 5, 6, 10,
39 13, 16, 17];
Chris Lattnerb77eb782003-08-03 18:19:37 +000040}
41
42def X86 : Target {
43 // Specify the callee saved registers.
Chris Lattnerc8f45872003-08-04 04:59:56 +000044 let CalleeSavedRegisters = [ESI, EDI, EBX, EBP];
Chris Lattnerb77eb782003-08-03 18:19:37 +000045
46 // Yes, pointers are 32-bits in size.
Chris Lattnerc8f45872003-08-04 04:59:56 +000047 let PointerType = i32;
Chris Lattnerb77eb782003-08-03 18:19:37 +000048
49 // Information about the instructions...
Chris Lattnerc8f45872003-08-04 04:59:56 +000050 let InstructionSet = X86InstrInfo;
Chris Lattnerb77eb782003-08-03 18:19:37 +000051}