aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorVikram S. Adve <vadve@cs.uiuc.edu>2001-07-28 04:19:10 +0000
committerVikram S. Adve <vadve@cs.uiuc.edu>2001-07-28 04:19:10 +0000
commit3c3b713d55da4f0d13578c38644607716bebcca0 (patch)
treeb58b196287f3705809eff37e685537e92c797d94 /lib
parent9b0b1ec1ecc14d46a9e6e50e3ba4c054de239d83 (diff)
downloadexternal_llvm-3c3b713d55da4f0d13578c38644607716bebcca0.zip
external_llvm-3c3b713d55da4f0d13578c38644607716bebcca0.tar.gz
external_llvm-3c3b713d55da4f0d13578c38644607716bebcca0.tar.bz2
Added UltraSparcInstrInfo class to specialize class MachineInstrInfo.
Relevant changes elsewhere: Added MachineInstrInfo class and moved instruction-related members there. Added several fields to MachineInstrDescriptor (and renamed it from MachineInstrInfo. Latency fields are to support scheduling. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CodeGen/TargetMachine/Sparc/Sparc.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/lib/CodeGen/TargetMachine/Sparc/Sparc.cpp b/lib/CodeGen/TargetMachine/Sparc/Sparc.cpp
index 68270fa..a9ea1da 100644
--- a/lib/CodeGen/TargetMachine/Sparc/Sparc.cpp
+++ b/lib/CodeGen/TargetMachine/Sparc/Sparc.cpp
@@ -11,27 +11,23 @@
#include "llvm/CodeGen/Sparc.h"
-//************************ Exported Constants ******************************/
-
-
-// Set external object describing the machine instructions
-//
-const MachineInstrInfo* TargetMachineInstrInfo = SparcMachineInstrInfo;
-
-
//************************ Class Implementations **************************/
+
//---------------------------------------------------------------------------
// class UltraSparcMachine
//
// Purpose:
-// Machine description.
+// Primary interface to machine description for the UltraSPARC.
+// Primarily just initializes machine-dependent parameters in
+// class TargetMachine, and creates machine-dependent subclasses
+// for classes such as MachineInstrInfo.
//
//---------------------------------------------------------------------------
UltraSparc::UltraSparc()
- : TargetMachine()
+ : TargetMachine(new UltraSparcInstrInfo)
{
optSizeForSubWordData = 4;
intSize = 4;
@@ -42,8 +38,12 @@ UltraSparc::UltraSparc()
pointerSize = 8;
minMemOpWordSize = 8;
maxAtomicMemOpWordSize = 8;
- machineInstrInfo = SparcMachineInstrInfo;
zeroRegNum = 0; // %g0 always gives 0 on Sparc
}
+UltraSparc::~UltraSparc()
+{
+ delete (UltraSparcInstrInfo*) machineInstrInfo;
+}
+
//**************************************************************************/