Commit 237afed5 by Karl Schimpf

Clean up emitInst() in the integrated ARM assembler.

Moves "EnsureCapacity Buffer" declarations inside emitInst(), so that all callers need not add the declaration before calling emitInst(). BUG=None R=stichnot@chromium.org Review URL: https://codereview.chromium.org/1636513002 .
parent ee718275
...@@ -458,7 +458,10 @@ private: ...@@ -458,7 +458,10 @@ private:
void bindCfgNodeLabel(const CfgNode *Node) override; void bindCfgNodeLabel(const CfgNode *Node) override;
void emitInst(IValueT Value) { Buffer.emit<IValueT>(Value); } void emitInst(IValueT Value) {
AssemblerBuffer::EnsureCapacity _(&Buffer);
Buffer.emit<IValueT>(Value);
}
// List of possible checks to apply when calling emitType01() (below). // List of possible checks to apply when calling emitType01() (below).
enum EmitChecks { NoChecks, RdIsPcAndSetFlags }; enum EmitChecks { NoChecks, RdIsPcAndSetFlags };
......
...@@ -30,7 +30,7 @@ entry: ...@@ -30,7 +30,7 @@ entry:
%test = fcmp olt float 0.0, 0.0 %test = fcmp olt float 0.0, 0.0
; ASM: vmrs APSR_nzcv, FPSCR ; ASM: vmrs APSR_nzcv, FPSCR
; DIS: 18: eef1fa10 ; DIS: 14: eef1fa10
; IASM-NOT: vmrs ; IASM-NOT: vmrs
%result = zext i1 %test to i32 %result = zext i1 %test to i32
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment