| Index: src/x64/lithium-codegen-x64.cc
|
| diff --git a/src/x64/lithium-codegen-x64.cc b/src/x64/lithium-codegen-x64.cc
|
| index 508ce5c1693f4c0102ba02301e3a412ec43aa4b4..38787af02beff8b258b12834a50d6f5191e8be98 100644
|
| --- a/src/x64/lithium-codegen-x64.cc
|
| +++ b/src/x64/lithium-codegen-x64.cc
|
| @@ -1619,7 +1619,7 @@ void LCodeGen::DoDateField(LDateField* instr) {
|
| __ j(not_equal, &runtime, Label::kNear);
|
| __ movq(result, FieldOperand(object, JSDate::kValueOffset +
|
| kPointerSize * index->value()));
|
| - __ jmp(&done);
|
| + __ jmp(&done, Label::kNear);
|
| }
|
| __ bind(&runtime);
|
| __ PrepareCallCFunction(2);
|
| @@ -2439,7 +2439,7 @@ void LCodeGen::DoInstanceOfKnownGlobal(LInstanceOfKnownGlobal* instr) {
|
| Register object = ToRegister(instr->value());
|
|
|
| // A Smi is not an instance of anything.
|
| - __ JumpIfSmi(object, &false_result);
|
| + __ JumpIfSmi(object, &false_result, Label::kNear);
|
|
|
| // This is the inlined call site instanceof cache. The two occurences of the
|
| // hole value will be patched to the last map/result pair generated by the
|
| @@ -2461,7 +2461,7 @@ void LCodeGen::DoInstanceOfKnownGlobal(LInstanceOfKnownGlobal* instr) {
|
| __ bind(&end_of_patched_code);
|
| ASSERT(true);
|
| #endif
|
| - __ jmp(&done);
|
| + __ jmp(&done, Label::kNear);
|
|
|
| // The inlined call site cache did not match. Check for null and string
|
| // before calling the deferred code.
|
| @@ -2516,9 +2516,9 @@ void LCodeGen::DoDeferredInstanceOfKnownGlobal(LInstanceOfKnownGlobal* instr,
|
| __ testq(kScratchRegister, kScratchRegister);
|
| Label load_false;
|
| Label done;
|
| - __ j(not_zero, &load_false);
|
| + __ j(not_zero, &load_false, Label::kNear);
|
| __ LoadRoot(rax, Heap::kTrueValueRootIndex);
|
| - __ jmp(&done);
|
| + __ jmp(&done, Label::kNear);
|
| __ bind(&load_false);
|
| __ LoadRoot(rax, Heap::kFalseValueRootIndex);
|
| __ bind(&done);
|
| @@ -3419,7 +3419,7 @@ void LCodeGen::DoMathFloor(LMathFloor* instr) {
|
| __ testq(output_reg, Immediate(1));
|
| DeoptimizeIf(not_zero, instr->environment());
|
| __ Set(output_reg, 0);
|
| - __ jmp(&done);
|
| + __ jmp(&done, Label::kNear);
|
| __ bind(&positive_sign);
|
| }
|
|
|
| @@ -3456,7 +3456,7 @@ void LCodeGen::DoMathRound(LMathRound* instr) {
|
| __ movq(kScratchRegister, one_half, RelocInfo::NONE64);
|
| __ movq(xmm_scratch, kScratchRegister);
|
| __ ucomisd(xmm_scratch, input_reg);
|
| - __ j(above, &below_one_half);
|
| + __ j(above, &below_one_half, Label::kNear);
|
|
|
| // CVTTSD2SI rounds towards zero, since 0.5 <= x, we use floor(0.5 + x).
|
| __ addsd(xmm_scratch, input_reg);
|
| @@ -3465,13 +3465,13 @@ void LCodeGen::DoMathRound(LMathRound* instr) {
|
| __ cmpl(output_reg, Immediate(0x80000000));
|
| __ RecordComment("D2I conversion overflow");
|
| DeoptimizeIf(equal, instr->environment());
|
| - __ jmp(&done);
|
| + __ jmp(&done, Label::kNear);
|
|
|
| __ bind(&below_one_half);
|
| __ movq(kScratchRegister, minus_one_half, RelocInfo::NONE64);
|
| __ movq(xmm_scratch, kScratchRegister);
|
| __ ucomisd(xmm_scratch, input_reg);
|
| - __ j(below_equal, &round_to_zero);
|
| + __ j(below_equal, &round_to_zero, Label::kNear);
|
|
|
| // CVTTSD2SI rounds towards zero, we use ceil(x - (-0.5)) and then
|
| // compare and compensate.
|
| @@ -3490,7 +3490,7 @@ void LCodeGen::DoMathRound(LMathRound* instr) {
|
| // No overflow because we already ruled out minint.
|
| __ bind(&restore);
|
| __ movq(input_reg, kScratchRegister); // Restore input_reg.
|
| - __ jmp(&done);
|
| + __ jmp(&done, Label::kNear);
|
|
|
| __ bind(&round_to_zero);
|
| // We return 0 for the input range [+0, 0.5[, or [-0.5, 0.5[ if
|
| @@ -3563,7 +3563,7 @@ void LCodeGen::DoPower(LPower* instr) {
|
| __ CallStub(&stub);
|
| } else if (exponent_type.IsTagged()) {
|
| Label no_deopt;
|
| - __ JumpIfSmi(exponent, &no_deopt);
|
| + __ JumpIfSmi(exponent, &no_deopt, Label::kNear);
|
| __ CmpObjectType(exponent, HEAP_NUMBER_TYPE, rcx);
|
| DeoptimizeIf(not_equal, instr->environment());
|
| __ bind(&no_deopt);
|
| @@ -3827,13 +3827,13 @@ void LCodeGen::DoCallNewArray(LCallNewArray* instr) {
|
| // look at the first argument
|
| __ movq(rcx, Operand(rsp, 0));
|
| __ testq(rcx, rcx);
|
| - __ j(zero, &packed_case);
|
| + __ j(zero, &packed_case, Label::kNear);
|
|
|
| ElementsKind holey_kind = GetHoleyElementsKind(kind);
|
| ArraySingleArgumentConstructorStub stub(holey_kind, context_mode,
|
| override_mode);
|
| CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr);
|
| - __ jmp(&done);
|
| + __ jmp(&done, Label::kNear);
|
| __ bind(&packed_case);
|
| }
|
|
|
| @@ -4129,7 +4129,7 @@ void LCodeGen::DoStoreKeyedFixedDoubleArray(LStoreKeyed* instr) {
|
| Label have_value;
|
|
|
| __ ucomisd(value, value);
|
| - __ j(parity_odd, &have_value); // NaN.
|
| + __ j(parity_odd, &have_value, Label::kNear); // NaN.
|
|
|
| __ Set(kScratchRegister, BitCast<uint64_t>(
|
| FixedDoubleArray::canonical_not_the_hole_nan_as_double()));
|
| @@ -4582,7 +4582,7 @@ void LCodeGen::EmitNumberUntagD(Register input_reg,
|
| __ movsd(result_reg, FieldOperand(input_reg, HeapNumber::kValueOffset));
|
|
|
| if (can_convert_undefined_to_nan) {
|
| - __ j(not_equal, &convert);
|
| + __ j(not_equal, &convert, Label::kNear);
|
| } else {
|
| DeoptimizeIf(not_equal, env);
|
| }
|
| @@ -4880,12 +4880,12 @@ void LCodeGen::DoCheckMaps(LCheckMaps* instr) {
|
| Label success;
|
| for (int i = 0; i < map_set.size() - 1; i++) {
|
| Handle<Map> map = map_set.at(i).handle();
|
| - __ CompareMap(reg, map, &success);
|
| - __ j(equal, &success);
|
| + __ CompareMap(reg, map);
|
| + __ j(equal, &success, Label::kNear);
|
| }
|
|
|
| Handle<Map> map = map_set.at(map_set.size() - 1).handle();
|
| - __ CompareMap(reg, map, &success);
|
| + __ CompareMap(reg, map);
|
| if (instr->hydrogen()->has_migration_target()) {
|
| __ j(not_equal, deferred->entry());
|
| } else {
|
| @@ -4918,7 +4918,7 @@ void LCodeGen::DoClampTToUint8(LClampTToUint8* instr) {
|
| XMMRegister xmm_scratch = double_scratch0();
|
| Label is_smi, done, heap_number;
|
|
|
| - __ JumpIfSmi(input_reg, &is_smi);
|
| + __ JumpIfSmi(input_reg, &is_smi, Label::kNear);
|
|
|
| // Check for heap number
|
| __ Cmp(FieldOperand(input_reg, HeapObject::kMapOffset),
|
| @@ -5075,7 +5075,7 @@ void LCodeGen::DoRegExpLiteral(LRegExpLiteral* instr) {
|
| int size = JSRegExp::kSize + JSRegExp::kInObjectFieldCount * kPointerSize;
|
| Label allocated, runtime_allocate;
|
| __ Allocate(size, rax, rcx, rdx, &runtime_allocate, TAG_OBJECT);
|
| - __ jmp(&allocated);
|
| + __ jmp(&allocated, Label::kNear);
|
|
|
| __ bind(&runtime_allocate);
|
| __ push(rbx);
|
| @@ -5408,9 +5408,9 @@ void LCodeGen::DoForInCacheArray(LForInCacheArray* instr) {
|
| Label load_cache, done;
|
| __ EnumLength(result, map);
|
| __ Cmp(result, Smi::FromInt(0));
|
| - __ j(not_equal, &load_cache);
|
| + __ j(not_equal, &load_cache, Label::kNear);
|
| __ LoadRoot(result, Heap::kEmptyFixedArrayRootIndex);
|
| - __ jmp(&done);
|
| + __ jmp(&done, Label::kNear);
|
| __ bind(&load_cache);
|
| __ LoadInstanceDescriptors(map, result);
|
| __ movq(result,
|
| @@ -5438,7 +5438,7 @@ void LCodeGen::DoLoadFieldByIndex(LLoadFieldByIndex* instr) {
|
| Label out_of_object, done;
|
| __ SmiToInteger32(index, index);
|
| __ cmpl(index, Immediate(0));
|
| - __ j(less, &out_of_object);
|
| + __ j(less, &out_of_object, Label::kNear);
|
| __ movq(object, FieldOperand(object,
|
| index,
|
| times_pointer_size,
|
|
|