Index: src/compiler/ia32/instruction-selector-ia32.cc |
diff --git a/src/compiler/ia32/instruction-selector-ia32.cc b/src/compiler/ia32/instruction-selector-ia32.cc |
index beec701903ec4598f26fb3d093b7898b2ea27804..b20bc94b64f36d6ad735f5e93a9aa7be126c48f5 100644 |
--- a/src/compiler/ia32/instruction-selector-ia32.cc |
+++ b/src/compiler/ia32/instruction-selector-ia32.cc |
@@ -718,7 +718,7 @@ void InstructionSelector::VisitFloat64RoundTiesAway(Node* node) { |
} |
-void InstructionSelector::VisitCall(Node* node) { |
+void InstructionSelector::VisitCall(Node* node, BasicBlock* handler) { |
IA32OperandGenerator g(this); |
const CallDescriptor* descriptor = OpParameter<const CallDescriptor*>(node); |
@@ -745,6 +745,13 @@ void InstructionSelector::VisitCall(Node* node) { |
Emit(kIA32Push, g.NoOutput(), value); |
} |
+ // Pass label of exception handler block. |
+ CallDescriptor::Flags flags = descriptor->flags(); |
+ if (handler != nullptr) { |
+ flags |= CallDescriptor::kHasExceptionHandler; |
+ buffer.instruction_args.push_back(g.Label(handler)); |
+ } |
+ |
// Select the appropriate opcode based on the call type. |
InstructionCode opcode; |
switch (descriptor->kind()) { |
@@ -759,7 +766,7 @@ void InstructionSelector::VisitCall(Node* node) { |
UNREACHABLE(); |
return; |
} |
- opcode |= MiscField::encode(descriptor->flags()); |
+ opcode |= MiscField::encode(flags); |
// Emit the call instruction. |
InstructionOperand* first_output = |