| Index: src/ppc/lithium-ppc.cc
|
| diff --git a/src/ppc/lithium-ppc.cc b/src/ppc/lithium-ppc.cc
|
| index 2ad66455e6f02844e8ac894ae2ead5008778514c..4f15a60d5de9a45ca51a664b05782aa09ec95b04 100644
|
| --- a/src/ppc/lithium-ppc.cc
|
| +++ b/src/ppc/lithium-ppc.cc
|
| @@ -1098,10 +1098,18 @@ LInstruction* LChunkBuilder::DoCallWithDescriptor(HCallWithDescriptor* instr) {
|
|
|
| LOperand* target = UseRegisterOrConstantAtStart(instr->target());
|
| ZoneList<LOperand*> ops(instr->OperandCount(), zone());
|
| + // Target
|
| ops.Add(target, zone());
|
| - for (int i = 1; i < instr->OperandCount(); i++) {
|
| - LOperand* op =
|
| - UseFixed(instr->OperandAt(i), descriptor.GetParameterRegister(i - 1));
|
| + // Context
|
| + LOperand* op = UseFixed(instr->OperandAt(1), cp);
|
| + ops.Add(op, zone());
|
| + // Other register parameters
|
| + for (int i = LCallWithDescriptor::kImplicitRegisterParameterCount;
|
| + i < instr->OperandCount(); i++) {
|
| + op =
|
| + UseFixed(instr->OperandAt(i),
|
| + descriptor.GetRegisterParameter(
|
| + i - LCallWithDescriptor::kImplicitRegisterParameterCount));
|
| ops.Add(op, zone());
|
| }
|
|
|
| @@ -2451,7 +2459,7 @@ LInstruction* LChunkBuilder::DoParameter(HParameter* instr) {
|
| CallInterfaceDescriptor descriptor =
|
| info()->code_stub()->GetCallInterfaceDescriptor();
|
| int index = static_cast<int>(instr->index());
|
| - Register reg = descriptor.GetEnvironmentParameterRegister(index);
|
| + Register reg = descriptor.GetRegisterParameter(index);
|
| return DefineFixed(result, reg);
|
| }
|
| }
|
|
|