| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include <assert.h> // For assert | 5 #include <assert.h> // For assert |
| 6 #include <limits.h> // For LONG_MIN, LONG_MAX. | 6 #include <limits.h> // For LONG_MIN, LONG_MAX. |
| 7 | 7 |
| 8 #if V8_TARGET_ARCH_PPC | 8 #if V8_TARGET_ARCH_PPC |
| 9 | 9 |
| 10 #include "src/base/bits.h" | 10 #include "src/base/bits.h" |
| (...skipping 552 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 563 ExternalReference::store_buffer_top(isolate()); | 563 ExternalReference::store_buffer_top(isolate()); |
| 564 mov(ip, Operand(store_buffer)); | 564 mov(ip, Operand(store_buffer)); |
| 565 LoadP(scratch, MemOperand(ip)); | 565 LoadP(scratch, MemOperand(ip)); |
| 566 // Store pointer to buffer and increment buffer top. | 566 // Store pointer to buffer and increment buffer top. |
| 567 StoreP(address, MemOperand(scratch)); | 567 StoreP(address, MemOperand(scratch)); |
| 568 addi(scratch, scratch, Operand(kPointerSize)); | 568 addi(scratch, scratch, Operand(kPointerSize)); |
| 569 // Write back new top of buffer. | 569 // Write back new top of buffer. |
| 570 StoreP(scratch, MemOperand(ip)); | 570 StoreP(scratch, MemOperand(ip)); |
| 571 // Call stub on end of buffer. | 571 // Call stub on end of buffer. |
| 572 // Check for end of buffer. | 572 // Check for end of buffer. |
| 573 mov(r0, Operand(StoreBuffer::kStoreBufferMask)); | 573 TestBitMask(scratch, StoreBuffer::kStoreBufferMask, r0); |
| 574 and_(r0, scratch, r0, SetRC); | |
| 575 | 574 |
| 576 if (and_then == kFallThroughAtEnd) { | 575 if (and_then == kFallThroughAtEnd) { |
| 577 bne(&done, cr0); | 576 bne(&done, cr0); |
| 578 } else { | 577 } else { |
| 579 DCHECK(and_then == kReturnAtEnd); | 578 DCHECK(and_then == kReturnAtEnd); |
| 580 Ret(ne, cr0); | 579 Ret(ne, cr0); |
| 581 } | 580 } |
| 582 mflr(r0); | 581 mflr(r0); |
| 583 push(r0); | 582 push(r0); |
| 584 StoreBufferOverflowStub store_buffer_overflow(isolate(), fp_mode); | 583 StoreBufferOverflowStub store_buffer_overflow(isolate(), fp_mode); |
| (...skipping 4083 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4668 } | 4667 } |
| 4669 if (mag.shift > 0) srawi(result, result, mag.shift); | 4668 if (mag.shift > 0) srawi(result, result, mag.shift); |
| 4670 ExtractBit(r0, dividend, 31); | 4669 ExtractBit(r0, dividend, 31); |
| 4671 add(result, result, r0); | 4670 add(result, result, r0); |
| 4672 } | 4671 } |
| 4673 | 4672 |
| 4674 } // namespace internal | 4673 } // namespace internal |
| 4675 } // namespace v8 | 4674 } // namespace v8 |
| 4676 | 4675 |
| 4677 #endif // V8_TARGET_ARCH_PPC | 4676 #endif // V8_TARGET_ARCH_PPC |
| OLD | NEW |