Lines Matching refs:__
55 #define __ masm. macro
78 __ push(rbx); in CreateTranscendentalFunction()
79 __ push(rdi); in CreateTranscendentalFunction()
80 __ movq(rbx, xmm0); in CreateTranscendentalFunction()
81 __ push(rbx); in CreateTranscendentalFunction()
82 __ fld_d(Operand(rsp, 0)); in CreateTranscendentalFunction()
85 __ fstp_d(Operand(rsp, 0)); in CreateTranscendentalFunction()
86 __ pop(rbx); in CreateTranscendentalFunction()
87 __ movq(xmm0, rbx); in CreateTranscendentalFunction()
88 __ pop(rdi); in CreateTranscendentalFunction()
89 __ pop(rbx); in CreateTranscendentalFunction()
90 __ Ret(); in CreateTranscendentalFunction()
113 __ sqrtsd(xmm0, xmm0); in CreateSqrtFunction()
114 __ Ret(); in CreateSqrtFunction()
147 __ movsd(Operand(rsp, kPointerSize * 2), xmm1); in CreateModuloFunction()
148 __ movsd(Operand(rsp, kPointerSize), xmm0); in CreateModuloFunction()
149 __ fld_d(Operand(rsp, kPointerSize * 2)); in CreateModuloFunction()
150 __ fld_d(Operand(rsp, kPointerSize)); in CreateModuloFunction()
155 __ fwait(); in CreateModuloFunction()
156 __ fnstsw_ax(); in CreateModuloFunction()
158 __ testb(rax, Immediate(5)); in CreateModuloFunction()
159 __ j(zero, &no_exceptions); in CreateModuloFunction()
160 __ fnclex(); in CreateModuloFunction()
161 __ bind(&no_exceptions); in CreateModuloFunction()
167 __ bind(&partial_remainder_loop); in CreateModuloFunction()
168 __ fprem(); in CreateModuloFunction()
169 __ fwait(); in CreateModuloFunction()
170 __ fnstsw_ax(); in CreateModuloFunction()
171 __ testl(rax, Immediate(0x400 /* C2 */)); in CreateModuloFunction()
174 __ j(not_zero, &partial_remainder_loop); in CreateModuloFunction()
181 __ testb(rax, Immediate(5)); in CreateModuloFunction()
182 __ j(zero, &valid_result); in CreateModuloFunction()
183 __ fstp(0); // Drop result in st(0). in CreateModuloFunction()
185 __ movq(rcx, kNaNValue, RelocInfo::NONE); in CreateModuloFunction()
186 __ movq(Operand(rsp, kPointerSize), rcx); in CreateModuloFunction()
187 __ movsd(xmm0, Operand(rsp, kPointerSize)); in CreateModuloFunction()
188 __ jmp(&return_result); in CreateModuloFunction()
191 __ bind(&valid_result); in CreateModuloFunction()
192 __ fstp_d(Operand(rsp, kPointerSize)); in CreateModuloFunction()
193 __ movsd(xmm0, Operand(rsp, kPointerSize)); in CreateModuloFunction()
196 __ bind(&return_result); in CreateModuloFunction()
197 __ fstp(0); // Unload y. in CreateModuloFunction()
200 __ testb(rax, Immediate(0x3f /* Any Exception*/)); in CreateModuloFunction()
201 __ j(not_zero, &clear_exceptions); in CreateModuloFunction()
202 __ ret(0); in CreateModuloFunction()
203 __ bind(&clear_exceptions); in CreateModuloFunction()
204 __ fnclex(); in CreateModuloFunction()
205 __ ret(0); in CreateModuloFunction()
216 #undef __
221 #define __ ACCESS_MASM(masm) macro
233 __ movq(FieldOperand(rdx, HeapObject::kMapOffset), rbx); in GenerateSmiOnlyToObject()
234 __ RecordWriteField(rdx, in GenerateSmiOnlyToObject()
258 __ movq(r8, FieldOperand(rdx, JSObject::kElementsOffset)); in GenerateSmiOnlyToDouble()
259 __ CompareRoot(r8, Heap::kEmptyFixedArrayRootIndex); in GenerateSmiOnlyToDouble()
260 __ j(equal, &only_change_map); in GenerateSmiOnlyToDouble()
264 __ SmiToInteger32(r9, FieldOperand(r8, FixedDoubleArray::kLengthOffset)); in GenerateSmiOnlyToDouble()
265 __ CompareRoot(FieldOperand(r8, HeapObject::kMapOffset), in GenerateSmiOnlyToDouble()
267 __ j(equal, &new_backing_store); in GenerateSmiOnlyToDouble()
272 __ JumpIfNotInNewSpace(r8, rdi, &new_backing_store); in GenerateSmiOnlyToDouble()
274 __ movq(r14, r8); // Destination array equals source array. in GenerateSmiOnlyToDouble()
280 __ LoadRoot(rdi, Heap::kFixedDoubleArrayMapRootIndex); in GenerateSmiOnlyToDouble()
281 __ movq(FieldOperand(r14, HeapObject::kMapOffset), rdi); in GenerateSmiOnlyToDouble()
283 __ bind(&allocated); in GenerateSmiOnlyToDouble()
285 __ movq(FieldOperand(rdx, HeapObject::kMapOffset), rbx); in GenerateSmiOnlyToDouble()
286 __ RecordWriteField(rdx, in GenerateSmiOnlyToDouble()
300 __ movq(r15, BitCast<int64_t, uint64_t>(kHoleNanInt64), RelocInfo::NONE); in GenerateSmiOnlyToDouble()
302 __ jmp(&entry); in GenerateSmiOnlyToDouble()
305 __ bind(&new_backing_store); in GenerateSmiOnlyToDouble()
306 __ lea(rdi, Operand(r9, times_pointer_size, FixedArray::kHeaderSize)); in GenerateSmiOnlyToDouble()
307 __ AllocateInNewSpace(rdi, r14, r11, r15, fail, TAG_OBJECT); in GenerateSmiOnlyToDouble()
309 __ LoadRoot(rdi, Heap::kFixedDoubleArrayMapRootIndex); in GenerateSmiOnlyToDouble()
310 __ movq(FieldOperand(r14, HeapObject::kMapOffset), rdi); in GenerateSmiOnlyToDouble()
312 __ movq(FieldOperand(rdx, JSObject::kElementsOffset), r14); in GenerateSmiOnlyToDouble()
313 __ movq(r11, r14); in GenerateSmiOnlyToDouble()
314 __ RecordWriteField(rdx, in GenerateSmiOnlyToDouble()
322 __ Integer32ToSmi(r11, r9); in GenerateSmiOnlyToDouble()
323 __ movq(FieldOperand(r14, FixedDoubleArray::kLengthOffset), r11); in GenerateSmiOnlyToDouble()
324 __ jmp(&allocated); in GenerateSmiOnlyToDouble()
326 __ bind(&only_change_map); in GenerateSmiOnlyToDouble()
328 __ movq(FieldOperand(rdx, HeapObject::kMapOffset), rbx); in GenerateSmiOnlyToDouble()
329 __ RecordWriteField(rdx, in GenerateSmiOnlyToDouble()
336 __ jmp(&done); in GenerateSmiOnlyToDouble()
339 __ bind(&loop); in GenerateSmiOnlyToDouble()
340 __ movq(rbx, in GenerateSmiOnlyToDouble()
344 __ JumpIfNotSmi(rbx, &convert_hole); in GenerateSmiOnlyToDouble()
345 __ SmiToInteger32(rbx, rbx); in GenerateSmiOnlyToDouble()
346 __ cvtlsi2sd(xmm0, rbx); in GenerateSmiOnlyToDouble()
347 __ movsd(FieldOperand(r14, r9, times_8, FixedDoubleArray::kHeaderSize), in GenerateSmiOnlyToDouble()
349 __ jmp(&entry); in GenerateSmiOnlyToDouble()
350 __ bind(&convert_hole); in GenerateSmiOnlyToDouble()
353 __ CompareRoot(rbx, Heap::kTheHoleValueRootIndex); in GenerateSmiOnlyToDouble()
354 __ Assert(equal, "object found in smi-only array"); in GenerateSmiOnlyToDouble()
357 __ movq(FieldOperand(r14, r9, times_8, FixedDoubleArray::kHeaderSize), r15); in GenerateSmiOnlyToDouble()
358 __ bind(&entry); in GenerateSmiOnlyToDouble()
359 __ decq(r9); in GenerateSmiOnlyToDouble()
360 __ j(not_sign, &loop); in GenerateSmiOnlyToDouble()
362 __ bind(&done); in GenerateSmiOnlyToDouble()
379 __ movq(r8, FieldOperand(rdx, JSObject::kElementsOffset)); in GenerateDoubleToObject()
380 __ CompareRoot(r8, Heap::kEmptyFixedArrayRootIndex); in GenerateDoubleToObject()
381 __ j(equal, &only_change_map); in GenerateDoubleToObject()
383 __ push(rax); in GenerateDoubleToObject()
385 __ movq(r8, FieldOperand(rdx, JSObject::kElementsOffset)); in GenerateDoubleToObject()
386 __ SmiToInteger32(r9, FieldOperand(r8, FixedDoubleArray::kLengthOffset)); in GenerateDoubleToObject()
389 __ lea(rdi, Operand(r9, times_pointer_size, FixedArray::kHeaderSize)); in GenerateDoubleToObject()
390 __ AllocateInNewSpace(rdi, r11, r14, r15, &gc_required, TAG_OBJECT); in GenerateDoubleToObject()
392 __ LoadRoot(rdi, Heap::kFixedArrayMapRootIndex); in GenerateDoubleToObject()
393 __ movq(FieldOperand(r11, HeapObject::kMapOffset), rdi); in GenerateDoubleToObject()
394 __ Integer32ToSmi(r14, r9); in GenerateDoubleToObject()
395 __ movq(FieldOperand(r11, FixedArray::kLengthOffset), r14); in GenerateDoubleToObject()
398 __ movq(rsi, BitCast<int64_t, uint64_t>(kHoleNanInt64), RelocInfo::NONE); in GenerateDoubleToObject()
399 __ LoadRoot(rdi, Heap::kTheHoleValueRootIndex); in GenerateDoubleToObject()
402 __ jmp(&entry); in GenerateDoubleToObject()
405 __ bind(&gc_required); in GenerateDoubleToObject()
406 __ pop(rax); in GenerateDoubleToObject()
407 __ movq(rsi, Operand(rbp, StandardFrameConstants::kContextOffset)); in GenerateDoubleToObject()
408 __ jmp(fail); in GenerateDoubleToObject()
411 __ bind(&loop); in GenerateDoubleToObject()
412 __ movq(r14, FieldOperand(r8, in GenerateDoubleToObject()
418 __ cmpq(r14, rsi); in GenerateDoubleToObject()
419 __ j(equal, &convert_hole); in GenerateDoubleToObject()
422 __ AllocateHeapNumber(rax, r15, &gc_required); in GenerateDoubleToObject()
424 __ movq(FieldOperand(rax, HeapNumber::kValueOffset), r14); in GenerateDoubleToObject()
425 __ movq(FieldOperand(r11, in GenerateDoubleToObject()
430 __ movq(r15, r9); in GenerateDoubleToObject()
431 __ RecordWriteArray(r11, in GenerateDoubleToObject()
437 __ jmp(&entry, Label::kNear); in GenerateDoubleToObject()
440 __ bind(&convert_hole); in GenerateDoubleToObject()
441 __ movq(FieldOperand(r11, in GenerateDoubleToObject()
447 __ bind(&entry); in GenerateDoubleToObject()
448 __ decq(r9); in GenerateDoubleToObject()
449 __ j(not_sign, &loop); in GenerateDoubleToObject()
452 __ movq(FieldOperand(rdx, JSObject::kElementsOffset), r11); in GenerateDoubleToObject()
453 __ RecordWriteField(rdx, in GenerateDoubleToObject()
460 __ pop(rax); in GenerateDoubleToObject()
461 __ movq(rsi, Operand(rbp, StandardFrameConstants::kContextOffset)); in GenerateDoubleToObject()
463 __ bind(&only_change_map); in GenerateDoubleToObject()
465 __ movq(FieldOperand(rdx, HeapObject::kMapOffset), rbx); in GenerateDoubleToObject()
466 __ RecordWriteField(rdx, in GenerateDoubleToObject()
482 __ movq(result, FieldOperand(string, HeapObject::kMapOffset)); in Generate()
483 __ movzxbl(result, FieldOperand(result, Map::kInstanceTypeOffset)); in Generate()
487 __ testb(result, Immediate(kIsIndirectStringMask)); in Generate()
488 __ j(zero, &check_sequential, Label::kNear); in Generate()
492 __ testb(result, Immediate(kSlicedNotConsMask)); in Generate()
493 __ j(zero, &cons_string, Label::kNear); in Generate()
497 __ SmiToInteger32(result, FieldOperand(string, SlicedString::kOffsetOffset)); in Generate()
498 __ addq(index, result); in Generate()
499 __ movq(string, FieldOperand(string, SlicedString::kParentOffset)); in Generate()
500 __ jmp(&indirect_string_loaded, Label::kNear); in Generate()
507 __ bind(&cons_string); in Generate()
508 __ CompareRoot(FieldOperand(string, ConsString::kSecondOffset), in Generate()
510 __ j(not_equal, call_runtime); in Generate()
511 __ movq(string, FieldOperand(string, ConsString::kFirstOffset)); in Generate()
513 __ bind(&indirect_string_loaded); in Generate()
514 __ movq(result, FieldOperand(string, HeapObject::kMapOffset)); in Generate()
515 __ movzxbl(result, FieldOperand(result, Map::kInstanceTypeOffset)); in Generate()
521 __ bind(&check_sequential); in Generate()
523 __ testb(result, Immediate(kStringRepresentationMask)); in Generate()
524 __ j(zero, &seq_string, Label::kNear); in Generate()
531 __ testb(result, Immediate(kIsIndirectStringMask)); in Generate()
532 __ Assert(zero, "external string expected, but not found"); in Generate()
536 __ testb(result, Immediate(kShortExternalStringTag)); in Generate()
537 __ j(not_zero, call_runtime); in Generate()
540 __ testb(result, Immediate(kStringEncodingMask)); in Generate()
541 __ movq(result, FieldOperand(string, ExternalString::kResourceDataOffset)); in Generate()
542 __ j(not_equal, &ascii_external, Label::kNear); in Generate()
544 __ movzxwl(result, Operand(result, index, times_2, 0)); in Generate()
545 __ jmp(&done, Label::kNear); in Generate()
546 __ bind(&ascii_external); in Generate()
548 __ movzxbl(result, Operand(result, index, times_1, 0)); in Generate()
549 __ jmp(&done, Label::kNear); in Generate()
553 __ bind(&seq_string); in Generate()
556 __ testb(result, Immediate(kStringEncodingMask)); in Generate()
557 __ j(not_zero, &ascii, Label::kNear); in Generate()
562 __ movzxwl(result, FieldOperand(string, in Generate()
566 __ jmp(&done, Label::kNear); in Generate()
570 __ bind(&ascii); in Generate()
571 __ movzxbl(result, FieldOperand(string, in Generate()
575 __ bind(&done); in Generate()
578 #undef __