| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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 "src/compiler/code-stub-assembler.h" | 5 #include "src/compiler/code-stub-assembler.h" |
| 6 | 6 |
| 7 #include <ostream> | 7 #include <ostream> |
| 8 | 8 |
| 9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
| 10 #include "src/compiler/graph.h" | 10 #include "src/compiler/graph.h" |
| (...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 431 if (flags & kDoubleAlignment) { | 431 if (flags & kDoubleAlignment) { |
| 432 return AllocateRawAligned(IntPtrConstant(size_in_bytes), flags, top_address, | 432 return AllocateRawAligned(IntPtrConstant(size_in_bytes), flags, top_address, |
| 433 limit_address); | 433 limit_address); |
| 434 } | 434 } |
| 435 #endif | 435 #endif |
| 436 | 436 |
| 437 return AllocateRawUnaligned(IntPtrConstant(size_in_bytes), flags, top_address, | 437 return AllocateRawUnaligned(IntPtrConstant(size_in_bytes), flags, top_address, |
| 438 limit_address); | 438 limit_address); |
| 439 } | 439 } |
| 440 | 440 |
| 441 Node* CodeStubAssembler::AllocateHeapNumber() { |
| 442 Node* result = Allocate(HeapNumber::kSize, kNone); |
| 443 StoreMapNoWriteBarrier(result, HeapNumberMapConstant()); |
| 444 return result; |
| 445 } |
| 446 |
| 447 Node* CodeStubAssembler::AllocateHeapNumberWithValue(Node* value) { |
| 448 Node* result = AllocateHeapNumber(); |
| 449 StoreHeapNumberValue(result, value); |
| 450 return result; |
| 451 } |
| 452 |
| 441 Node* CodeStubAssembler::Load(MachineType rep, Node* base) { | 453 Node* CodeStubAssembler::Load(MachineType rep, Node* base) { |
| 442 return raw_assembler_->Load(rep, base); | 454 return raw_assembler_->Load(rep, base); |
| 443 } | 455 } |
| 444 | 456 |
| 445 Node* CodeStubAssembler::Load(MachineType rep, Node* base, Node* index) { | 457 Node* CodeStubAssembler::Load(MachineType rep, Node* base, Node* index) { |
| 446 return raw_assembler_->Load(rep, base, index); | 458 return raw_assembler_->Load(rep, base, index); |
| 447 } | 459 } |
| 448 | 460 |
| 449 Node* CodeStubAssembler::Store(MachineRepresentation rep, Node* base, | 461 Node* CodeStubAssembler::Store(MachineRepresentation rep, Node* base, |
| 450 Node* value) { | 462 Node* value) { |
| (...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 903 } | 915 } |
| 904 } | 916 } |
| 905 } | 917 } |
| 906 | 918 |
| 907 bound_ = true; | 919 bound_ = true; |
| 908 } | 920 } |
| 909 | 921 |
| 910 } // namespace compiler | 922 } // namespace compiler |
| 911 } // namespace internal | 923 } // namespace internal |
| 912 } // namespace v8 | 924 } // namespace v8 |
| OLD | NEW |