From 680b1bdd7e5d112ba4b95d6c81a43b65119b3b9c Mon Sep 17 00:00:00 2001 From: Ian Rogers Date: Wed, 7 Mar 2012 20:18:49 -0800 Subject: Unify branch flags, pretty printer for OpKind. LIR operand 0 is always an offset for a branch. This is clear in conditional branches that are binary and have the 2nd operand as the condition codes of the branch. This changes unconditional branches to be unary and therefore more intention revealing that the 1st operand will be used by the assembler to hold an offset. A << operator for OpKind allows easy pretty printing. Change-Id: I933b8e0bf43f5be3eff13f93c3fc1539ae526840 --- src/compiler/codegen/GenCommon.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/compiler/codegen/GenCommon.cc') diff --git a/src/compiler/codegen/GenCommon.cc b/src/compiler/codegen/GenCommon.cc index 3d46240df6..c43d8ff2a4 100644 --- a/src/compiler/codegen/GenCommon.cc +++ b/src/compiler/codegen/GenCommon.cc @@ -47,7 +47,7 @@ void genBarrier(CompilationUnit* cUnit) /* Generate unconditional branch instructions */ LIR* opUnconditionalBranch(CompilationUnit* cUnit, LIR* target) { - LIR* branch = opNone(cUnit, kOpUncondBr); + LIR* branch = opBranchUnconditional(cUnit, kOpUncondBr); branch->target = (LIR*) target; return branch; } -- cgit v1.2.3-59-g8ed1b