diff options
author | Owen Anderson <resistor@mac.com> | 2012-08-29 22:18:56 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2012-08-29 22:18:56 +0000 |
commit | 15b7a98ece81ec275a560c77b814e0479a669bc6 (patch) | |
tree | 25e23a75755e93d97f11c33ec61ec1b9c7e6c790 /include | |
parent | 66390805ad58871cde3f5ccd72a7dcac9b1cd4d8 (diff) | |
download | external_llvm-15b7a98ece81ec275a560c77b814e0479a669bc6.zip external_llvm-15b7a98ece81ec275a560c77b814e0479a669bc6.tar.gz external_llvm-15b7a98ece81ec275a560c77b814e0479a669bc6.tar.bz2 |
Allow targets to specify a minimum supported NOP size when performing NOP padding. If the desired padding is smaller than the supported NOP size,
we will enlarge the padding to make it work.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162870 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/MC/MCAsmBackend.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/llvm/MC/MCAsmBackend.h b/include/llvm/MC/MCAsmBackend.h index 43aceba..1c45090 100644 --- a/include/llvm/MC/MCAsmBackend.h +++ b/include/llvm/MC/MCAsmBackend.h @@ -133,6 +133,13 @@ public: /// @} + /// getMinimumNopSize - Returns the minimum size of a nop in bytes on this + /// target. The assembler will use this to emit excess padding in situations + /// where the padding required for simple alignment would be less than the + /// minimum nop size. + /// + virtual unsigned getMinimumNopSize() const { return 1; } + /// writeNopData - Write an (optimal) nop sequence of Count bytes to the given /// output. If the target cannot generate such a sequence, it should return an /// error. |