2011-12-12 22:14:40 +01:00
|
|
|
//=-- Hexagon.h - Top-level interface for Hexagon representation --*- C++ -*-=//
|
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
//
|
|
|
|
// This file contains the entry points for global functions defined in the LLVM
|
|
|
|
// Hexagon back-end.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
2014-08-13 18:26:38 +02:00
|
|
|
#ifndef LLVM_LIB_TARGET_HEXAGON_HEXAGON_H
|
|
|
|
#define LLVM_LIB_TARGET_HEXAGON_HEXAGON_H
|
2011-12-12 22:14:40 +01:00
|
|
|
|
|
|
|
#define Hexagon_POINTER_SIZE 4
|
|
|
|
|
|
|
|
#define Hexagon_PointerSize (Hexagon_POINTER_SIZE)
|
|
|
|
#define Hexagon_PointerSize_Bits (Hexagon_POINTER_SIZE * 8)
|
|
|
|
#define Hexagon_WordSize Hexagon_PointerSize
|
|
|
|
#define Hexagon_WordSize_Bits Hexagon_PointerSize_Bits
|
|
|
|
|
|
|
|
// allocframe saves LR and FP on stack before allocating
|
|
|
|
// a new stack frame. This takes 8 bytes.
|
|
|
|
#define HEXAGON_LRFP_SIZE 8
|
|
|
|
|
2012-04-12 19:55:53 +02:00
|
|
|
// Normal instruction size (in bytes).
|
|
|
|
#define HEXAGON_INSTR_SIZE 4
|
|
|
|
|
2012-05-03 23:52:53 +02:00
|
|
|
// Maximum number of words and instructions in a packet.
|
2012-04-12 19:55:53 +02:00
|
|
|
#define HEXAGON_PACKET_SIZE 4
|
2015-06-15 21:05:35 +02:00
|
|
|
#define HEXAGON_MAX_PACKET_SIZE (HEXAGON_PACKET_SIZE * HEXAGON_INSTR_SIZE)
|
2015-05-29 16:44:13 +02:00
|
|
|
// Minimum number of instructions in an end-loop packet.
|
|
|
|
#define HEXAGON_PACKET_INNER_SIZE 2
|
|
|
|
#define HEXAGON_PACKET_OUTER_SIZE 3
|
2015-05-31 23:57:09 +02:00
|
|
|
// Maximum number of instructions in a packet before shuffling,
|
|
|
|
// including a compound one or a duplex or an extender.
|
|
|
|
#define HEXAGON_PRESHUFFLE_PACKET_SIZE (HEXAGON_PACKET_SIZE + 3)
|
2015-05-29 16:44:13 +02:00
|
|
|
|
2015-06-15 21:05:35 +02:00
|
|
|
// Name of the global offset table as defined by the Hexagon ABI
|
|
|
|
#define HEXAGON_GOT_SYM_NAME "_GLOBAL_OFFSET_TABLE_"
|
|
|
|
|
|
|
|
#include "MCTargetDesc/HexagonMCTargetDesc.h"
|
2017-11-17 02:07:10 +01:00
|
|
|
#include "llvm/CodeGen/TargetLowering.h"
|
2015-06-15 21:05:35 +02:00
|
|
|
#include "llvm/Target/TargetMachine.h"
|
|
|
|
|
|
|
|
namespace llvm {
|
|
|
|
class HexagonTargetMachine;
|
|
|
|
|
|
|
|
/// \brief Creates a Hexagon-specific Target Transformation Info pass.
|
|
|
|
ImmutablePass *createHexagonTargetTransformInfoPass(const HexagonTargetMachine *TM);
|
2015-06-23 11:49:53 +02:00
|
|
|
} // end namespace llvm;
|
2015-06-15 21:05:35 +02:00
|
|
|
|
2011-12-12 22:14:40 +01:00
|
|
|
#endif
|