1 //===-- llvm/Support/CodeGen.h - CodeGen Concepts ---------------*- C++ -*-===//
3 // 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
7 //===----------------------------------------------------------------------===//
9 // This file define some types which define code generation concepts. For
10 // example, relocation model.
12 //===----------------------------------------------------------------------===//
14 #ifndef LLVM_SUPPORT_CODEGEN_H
15 #define LLVM_SUPPORT_CODEGEN_H
19 // Relocation model types.
21 enum Model
{ Static
, PIC_
, DynamicNoPIC
, ROPI
, RWPI
, ROPI_RWPI
};
26 // Sync changes with CodeGenCWrappers.h.
27 enum Model
{ Tiny
, Small
, Kernel
, Medium
, Large
};
31 // This is used to map -fpic/-fPIC.
32 enum Level
{ NotPIC
=0, SmallPIC
=1, BigPIC
=2 };
36 enum Level
{ Default
=0, Small
=1, Large
=2 };
49 // Code generation optimization level.
50 namespace CodeGenOpt
{
54 Default
= 2, // -O2, -Os
59 // Specify effect of frame pointer elimination optimization.
60 namespace FramePointer
{
61 enum FP
{All
, NonLeaf
, None
};
64 } // end llvm namespace