mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-10 22:00:58 +00:00
genericize MCAsmStreamer::EmitCodeAlignment to support other targets
so that it doesn't break them when the code generator starts using it. llvm-svn: 96966
This commit is contained in:
parent
0c478ab8af
commit
405e4a1d63
@ -518,8 +518,9 @@ void MCAsmStreamer::EmitValueToAlignment(unsigned ByteAlignment, int64_t Value,
|
||||
|
||||
void MCAsmStreamer::EmitCodeAlignment(unsigned ByteAlignment,
|
||||
unsigned MaxBytesToEmit) {
|
||||
// FIXME: a hack for now to only work for x86 using the 0x90 nop opcode.
|
||||
EmitValueToAlignment(ByteAlignment, 0x90, 1, MaxBytesToEmit);
|
||||
// Emit with a text fill value.
|
||||
EmitValueToAlignment(ByteAlignment, MAI.getTextAlignFillValue(),
|
||||
1, MaxBytesToEmit);
|
||||
}
|
||||
|
||||
void MCAsmStreamer::EmitValueToOffset(const MCExpr *Offset,
|
||||
|
Loading…
x
Reference in New Issue
Block a user