blob: 67f35b8034d99b094a136d62872cf39ff56a3e13 [file] [log] [blame]
Anton Korobeynikov10138002009-05-03 12:57:15 +00001//==-- MSP430.h - Top-level interface for MSP430 representation --*- C++ -*-==//
2//
Chandler Carruth2946cd72019-01-19 08:50:56 +00003// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
Anton Korobeynikov10138002009-05-03 12:57:15 +00006//
7//===----------------------------------------------------------------------===//
8//
9// This file contains the entry points for global functions defined in
10// the LLVM MSP430 backend.
11//
12//===----------------------------------------------------------------------===//
13
Benjamin Kramera7c40ef2014-08-13 16:26:38 +000014#ifndef LLVM_LIB_TARGET_MSP430_MSP430_H
15#define LLVM_LIB_TARGET_MSP430_MSP430_H
Anton Korobeynikov10138002009-05-03 12:57:15 +000016
Evan Chengbc153d42011-07-14 20:59:42 +000017#include "MCTargetDesc/MSP430MCTargetDesc.h"
Anton Korobeynikov1324f812009-05-03 13:19:42 +000018#include "llvm/Target/TargetMachine.h"
19
Anton Korobeynikov2983dcb2009-10-21 19:16:49 +000020namespace MSP430CC {
21 // MSP430 specific condition code.
22 enum CondCodes {
23 COND_E = 0, // aka COND_Z
24 COND_NE = 1, // aka COND_NZ
25 COND_HS = 2, // aka COND_C
26 COND_LO = 3, // aka COND_NC
27 COND_GE = 4,
28 COND_L = 5,
Anton Korobeynikov49045c62018-11-15 12:29:43 +000029 COND_N = 6, // jump if negative
30 COND_NONE, // unconditional
Anton Korobeynikov2983dcb2009-10-21 19:16:49 +000031
32 COND_INVALID = -1
33 };
Alexander Kornienkof00654e2015-06-23 09:49:53 +000034}
Anton Korobeynikov2983dcb2009-10-21 19:16:49 +000035
Anton Korobeynikov10138002009-05-03 12:57:15 +000036namespace llvm {
37 class MSP430TargetMachine;
38 class FunctionPass;
David Greenea31f96c2009-07-14 20:18:05 +000039 class formatted_raw_ostream;
Anton Korobeynikov10138002009-05-03 12:57:15 +000040
Anton Korobeynikov1324f812009-05-03 13:19:42 +000041 FunctionPass *createMSP430ISelDag(MSP430TargetMachine &TM,
42 CodeGenOpt::Level OptLevel);
Daniel Dunbar67038c12009-07-18 23:03:22 +000043
Anton Korobeynikovce52fd52010-01-15 21:19:05 +000044 FunctionPass *createMSP430BranchSelectionPass();
45
Alexander Kornienkof00654e2015-06-23 09:49:53 +000046} // end namespace llvm;
Anton Korobeynikov10138002009-05-03 12:57:15 +000047
Anton Korobeynikov10138002009-05-03 12:57:15 +000048#endif