Index: src/compiler/code-generator.cc |
diff --git a/src/compiler/code-generator.cc b/src/compiler/code-generator.cc |
index f2c7ec6df48890c25343935e198b91894b1285ac..da568d6f0aa9e6a805439a0d7b052fa545f7505b 100644 |
--- a/src/compiler/code-generator.cc |
+++ b/src/compiler/code-generator.cc |
@@ -417,12 +417,14 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleInstruction( |
if (instr->IsJump() && block->must_deconstruct_frame()) { |
AssembleDeconstructFrame(); |
} |
- AssembleSourcePosition(instr); |
+ FlagsMode mode = FlagsModeField::decode(instr->opcode()); |
+ if (mode != kFlags_trap) { |
+ AssembleSourcePosition(instr); |
+ } |
// Assemble architecture-specific code for the instruction. |
CodeGenResult result = AssembleArchInstruction(instr); |
if (result != kSuccess) return result; |
- FlagsMode mode = FlagsModeField::decode(instr->opcode()); |
FlagsCondition condition = FlagsConditionField::decode(instr->opcode()); |
switch (mode) { |
case kFlags_branch: { |
@@ -474,6 +476,10 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleInstruction( |
AssembleArchBoolean(instr, condition); |
break; |
} |
+ case kFlags_trap: { |
+ AssembleArchTrap(instr, condition); |
+ break; |
+ } |
case kFlags_none: { |
break; |
} |