blob: dce443997ea5971de718adfb1c19254fd84c85e7 [file] [log] [blame]
Chris Lattner79fa3712010-11-15 05:57:53 +00001//===-- PPCFixupKinds.h - PPC Specific Fixup Entries ------------*- C++ -*-===//
2//
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
Benjamin Kramera7c40ef2014-08-13 16:26:38 +000010#ifndef LLVM_LIB_TARGET_POWERPC_MCTARGETDESC_PPCFIXUPKINDS_H
11#define LLVM_LIB_TARGET_POWERPC_MCTARGETDESC_PPCFIXUPKINDS_H
Chris Lattner79fa3712010-11-15 05:57:53 +000012
13#include "llvm/MC/MCFixup.h"
14
Sylvestre Ledru37ef20d2013-03-17 12:40:42 +000015#undef PPC
16
Chris Lattner79fa3712010-11-15 05:57:53 +000017namespace llvm {
18namespace PPC {
19enum Fixups {
Rafael Espindola1416c2d2017-06-28 17:23:13 +000020 // 24-bit PC relative relocation for direct branches like 'b' and 'bl'.
Chris Lattner79fa3712010-11-15 05:57:53 +000021 fixup_ppc_br24 = FirstTargetFixupKind,
Rafael Espindola1416c2d2017-06-28 17:23:13 +000022
23 /// 14-bit PC relative relocation for conditional branches.
Chris Lattner85e37682010-11-15 06:12:22 +000024 fixup_ppc_brcond14,
Rafael Espindola1416c2d2017-06-28 17:23:13 +000025
26 /// 24-bit absolute relocation for direct branches like 'ba' and 'bla'.
Ulrich Weigandb6a30d12013-06-24 11:03:33 +000027 fixup_ppc_br24abs,
28
Rafael Espindola1416c2d2017-06-28 17:23:13 +000029 /// 14-bit absolute relocation for conditional branches.
Ulrich Weigandb6a30d12013-06-24 11:03:33 +000030 fixup_ppc_brcond14abs,
31
Rafael Espindola1416c2d2017-06-28 17:23:13 +000032 /// A 16-bit fixup corresponding to lo16(_foo) or ha16(_foo) for instrs like
33 /// 'li' or 'addis'.
Ulrich Weigand6e23ac62013-05-17 12:37:21 +000034 fixup_ppc_half16,
Rafael Espindola1416c2d2017-06-28 17:23:13 +000035
36 /// A 14-bit fixup corresponding to lo16(_foo) with implied 2 zero bits for
37 /// instrs like 'std'.
Ulrich Weigand6e23ac62013-05-17 12:37:21 +000038 fixup_ppc_half16ds,
Bill Schmidtca4a0c92012-12-04 16:18:08 +000039
Rafael Espindola1416c2d2017-06-28 17:23:13 +000040 /// Not a true fixup, but ties a symbol to a call to __tls_get_addr for the
41 /// TLS general and local dynamic models, or inserts the thread-pointer
42 /// register number.
Bill Schmidt24b8dd62012-12-12 19:29:35 +000043 fixup_ppc_nofixup,
Rafael Espindola1416c2d2017-06-28 17:23:13 +000044
Chris Lattner79fa3712010-11-15 05:57:53 +000045 // Marker
46 LastTargetFixupKind,
47 NumTargetFixupKinds = LastTargetFixupKind - FirstTargetFixupKind
48};
Alexander Kornienkof00654e2015-06-23 09:49:53 +000049}
50}
Chris Lattner79fa3712010-11-15 05:57:53 +000051
52#endif