diff options
Diffstat (limited to 'llvm/lib/Target/Mips/MipsSubtarget.h')
-rw-r--r-- | llvm/lib/Target/Mips/MipsSubtarget.h | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/llvm/lib/Target/Mips/MipsSubtarget.h b/llvm/lib/Target/Mips/MipsSubtarget.h index ef04c931138..0c9688865c1 100644 --- a/llvm/lib/Target/Mips/MipsSubtarget.h +++ b/llvm/lib/Target/Mips/MipsSubtarget.h @@ -155,6 +155,13 @@ class MipsSubtarget : public MipsGenSubtargetInfo { // Disable use of the `jal` instruction. bool UseLongCalls = false; + /// The minimum alignment known to hold of the stack frame on + /// entry to the function and which must be maintained by every function. + unsigned stackAlignment; + + /// The overridden stack alignment. + unsigned StackAlignOverride; + InstrItineraryData InstrItins; // We can override the determination of whether we are in mips16 mode @@ -186,7 +193,7 @@ public: /// This constructor initializes the data members to match that /// of the specified triple. MipsSubtarget(const Triple &TT, StringRef CPU, StringRef FS, bool little, - const MipsTargetMachine &TM); + const MipsTargetMachine &TM, unsigned StackAlignOverride); /// ParseSubtargetFeatures - Parses features string setting specified /// subtarget options. Definition of function is auto generated by tblgen. @@ -295,9 +302,7 @@ public: // really use them if in addition we are in mips16 mode static bool useConstantIslands(); - unsigned stackAlignment() const { - return isABI_N32() || isABI_N64() ? 16 : 8; - } + unsigned getStackAlignment() const { return stackAlignment; } // Grab relocation model Reloc::Model getRelocationModel() const; |