| Index: include/llvm/CodeGen/AsmPrinter.h
|
| diff --git a/include/llvm/CodeGen/AsmPrinter.h b/include/llvm/CodeGen/AsmPrinter.h
|
| index 25b99a2c6976d2df578f49e4ae4e014ba77916a5..ccfba30a5f1aaa41c8ce4fab0ce1cb2bfeacbc53 100644
|
| --- a/include/llvm/CodeGen/AsmPrinter.h
|
| +++ b/include/llvm/CodeGen/AsmPrinter.h
|
| @@ -248,6 +248,18 @@ public:
|
| // Targets can, or in the case of EmitInstruction, must implement these to
|
| // customize output.
|
|
|
| + // @LOCALMOD-START
|
| + /// UseReadOnlyJumpTables - true if JumpTableInfo must be in rodata.
|
| + virtual bool UseReadOnlyJumpTables() const { return false; }
|
| + /// GetTargetBasicBlockAlign - the target alignment for basic blocks.
|
| + virtual unsigned GetTargetBasicBlockAlign() const { return 0; }
|
| + /// GetTargetLabelAlign - Get optional alignment for TargetOpcode
|
| + /// labels E.g., EH_LABEL.
|
| + virtual unsigned GetTargetLabelAlign(const MachineInstr *MI) const {
|
| + return 0;
|
| + }
|
| + // @LOCALMOD-END
|
| +
|
| /// This virtual method can be overridden by targets that want to emit
|
| /// something at the start of their file.
|
| virtual void EmitStartOfAsmFile(Module &) {}
|
| @@ -262,7 +274,12 @@ public:
|
|
|
| /// Targets can override this to emit stuff after the last basic block in the
|
| /// function.
|
| - virtual void EmitFunctionBodyEnd() {}
|
| + virtual void EmitFunctionBodyEnd() {
|
| + // @LOCALMOD-START
|
| + unsigned NextFunctionAlignment = GetTargetBasicBlockAlign();
|
| + if (NextFunctionAlignment) EmitAlignment(NextFunctionAlignment);
|
| + // @LOCALMOD-END
|
| + }
|
|
|
| /// Targets can override this to emit stuff at the end of a basic block.
|
| virtual void EmitBasicBlockEnd(const MachineBasicBlock &MBB) {}
|
|
|