blob: 4d8792eede7fc9d53aba436c52211695b3d3d27c [file] [log] [blame]
Jia Liub22310f2012-02-18 12:03:15 +00001//===-- MSP430Subtarget.h - Define Subtarget for the MSP430 ----*- C++ -*--===//
Anton Korobeynikov10138002009-05-03 12:57:15 +00002//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9//
Evan Cheng0d639a22011-07-01 21:01:15 +000010// This file declares the MSP430 specific subclass of TargetSubtargetInfo.
Anton Korobeynikov10138002009-05-03 12:57:15 +000011//
12//===----------------------------------------------------------------------===//
13
14#ifndef LLVM_TARGET_MSP430_SUBTARGET_H
15#define LLVM_TARGET_MSP430_SUBTARGET_H
16
Evan Cheng0d639a22011-07-01 21:01:15 +000017#include "llvm/Target/TargetSubtargetInfo.h"
Craig Topperb25fda92012-03-17 18:46:09 +000018#include <string>
Anton Korobeynikov10138002009-05-03 12:57:15 +000019
Evan Cheng54b68e32011-07-01 20:45:01 +000020#define GET_SUBTARGETINFO_HEADER
Evan Chengc9c090d2011-07-01 22:36:09 +000021#include "MSP430GenSubtargetInfo.inc"
Evan Cheng54b68e32011-07-01 20:45:01 +000022
Anton Korobeynikov10138002009-05-03 12:57:15 +000023namespace llvm {
Evan Cheng1a72add62011-07-07 07:07:08 +000024class StringRef;
Anton Korobeynikov10138002009-05-03 12:57:15 +000025
Evan Cheng54b68e32011-07-01 20:45:01 +000026class MSP430Subtarget : public MSP430GenSubtargetInfo {
David Blaikiea379b1812011-12-20 02:50:00 +000027 virtual void anchor();
Anton Korobeynikov10138002009-05-03 12:57:15 +000028 bool ExtendedInsts;
29public:
30 /// This constructor initializes the data members to match that
Daniel Dunbar31b44e82009-08-02 22:11:08 +000031 /// of the specified triple.
Anton Korobeynikov10138002009-05-03 12:57:15 +000032 ///
Evan Chengfe6e4052011-06-30 01:53:36 +000033 MSP430Subtarget(const std::string &TT, const std::string &CPU,
34 const std::string &FS);
Anton Korobeynikov10138002009-05-03 12:57:15 +000035
36 /// ParseSubtargetFeatures - Parses features string setting specified
37 /// subtarget options. Definition of function is auto generated by tblgen.
Evan Cheng1a72add62011-07-07 07:07:08 +000038 void ParseSubtargetFeatures(StringRef CPU, StringRef FS);
Anton Korobeynikov10138002009-05-03 12:57:15 +000039};
40} // End llvm namespace
41
42#endif // LLVM_TARGET_MSP430_SUBTARGET_H