Skip to content

Commit ecef4b5

Browse files
committed
CodeGen: Move ABI option enums to support
Move these out of TargetOptions and into Support to avoid the dependency on Target. There are similar ABI options already in Support/CodeGen.h.
1 parent 7468718 commit ecef4b5

File tree

2 files changed

+17
-16
lines changed

2 files changed

+17
-16
lines changed

llvm/include/llvm/Support/CodeGen.h

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,22 @@ namespace llvm {
5050
};
5151
}
5252

53+
namespace FloatABI {
54+
enum ABIType {
55+
Default, // Target-specific (either soft or hard depending on triple, etc).
56+
Soft, // Soft float.
57+
Hard // Hard float.
58+
};
59+
}
60+
61+
enum class EABI {
62+
Unknown,
63+
Default, // Default means not specified
64+
EABI4, // Target-specific (either 4, 5 or gnu depending on triple).
65+
EABI5,
66+
GNU
67+
};
68+
5369
/// Code generation optimization level.
5470
enum class CodeGenOptLevel {
5571
None = 0, ///< -O0

llvm/include/llvm/Target/TargetOptions.h

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
#include "llvm/ADT/FloatingPointMode.h"
1818
#include "llvm/MC/MCTargetOptions.h"
19+
#include "llvm/Support/CodeGen.h"
1920
#include "llvm/Support/Compiler.h"
2021

2122
#include <memory>
@@ -25,14 +26,6 @@ struct fltSemantics;
2526
class MachineFunction;
2627
class MemoryBuffer;
2728

28-
namespace FloatABI {
29-
enum ABIType {
30-
Default, // Target-specific (either soft or hard depending on triple, etc).
31-
Soft, // Soft float.
32-
Hard // Hard float.
33-
};
34-
}
35-
3629
namespace FPOpFusion {
3730
enum FPOpFusionMode {
3831
Fast, // Enable fusion of FP ops wherever it's profitable.
@@ -71,14 +64,6 @@ enum class BasicBlockSection {
7164
None // Do not use Basic Block Sections.
7265
};
7366

74-
enum class EABI {
75-
Unknown,
76-
Default, // Default means not specified
77-
EABI4, // Target-specific (either 4, 5 or gnu depending on triple).
78-
EABI5,
79-
GNU
80-
};
81-
8267
/// Identify a debugger for "tuning" the debug info.
8368
///
8469
/// The "debugger tuning" concept allows us to present a more intuitive

0 commit comments

Comments
 (0)