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/signature.h" | 5 #include "src/signature.h" |
6 | 6 |
7 #include "src/bit-vector.h" | 7 #include "src/bit-vector.h" |
8 #include "src/flags.h" | 8 #include "src/flags.h" |
9 #include "src/handles.h" | 9 #include "src/handles.h" |
10 #include "src/zone/zone-containers.h" | 10 #include "src/zone/zone-containers.h" |
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
544 local_type_vec_[index] == type) { | 544 local_type_vec_[index] == type) { |
545 // Do a whole run of like-typed locals at a time. | 545 // Do a whole run of like-typed locals at a time. |
546 ssa_env->locals[index++] = node; | 546 ssa_env->locals[index++] = node; |
547 } | 547 } |
548 } | 548 } |
549 } | 549 } |
550 ssa_env->control = start; | 550 ssa_env->control = start; |
551 ssa_env->effect = start; | 551 ssa_env->effect = start; |
552 SetEnv("initial", ssa_env); | 552 SetEnv("initial", ssa_env); |
553 if (builder_) { | 553 if (builder_) { |
554 builder_->StackCheck(position()); | 554 // The function-prologue stack check is associated with position 0, which |
| 555 // is never a position of any instruction in the function. |
| 556 builder_->StackCheck(0); |
555 } | 557 } |
556 } | 558 } |
557 | 559 |
558 TFNode* DefaultValue(ValueType type) { | 560 TFNode* DefaultValue(ValueType type) { |
559 switch (type) { | 561 switch (type) { |
560 case kWasmI32: | 562 case kWasmI32: |
561 return builder_->Int32Constant(0); | 563 return builder_->Int32Constant(0); |
562 case kWasmI64: | 564 case kWasmI64: |
563 return builder_->Int64Constant(0); | 565 return builder_->Int64Constant(0); |
564 case kWasmF32: | 566 case kWasmF32: |
(...skipping 1506 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2071 BitVector* AnalyzeLoopAssignmentForTesting(Zone* zone, size_t num_locals, | 2073 BitVector* AnalyzeLoopAssignmentForTesting(Zone* zone, size_t num_locals, |
2072 const byte* start, const byte* end) { | 2074 const byte* start, const byte* end) { |
2073 FunctionBody body = {nullptr, nullptr, start, end}; | 2075 FunctionBody body = {nullptr, nullptr, start, end}; |
2074 WasmFullDecoder decoder(zone, body); | 2076 WasmFullDecoder decoder(zone, body); |
2075 return decoder.AnalyzeLoopAssignmentForTesting(start, num_locals); | 2077 return decoder.AnalyzeLoopAssignmentForTesting(start, num_locals); |
2076 } | 2078 } |
2077 | 2079 |
2078 } // namespace wasm | 2080 } // namespace wasm |
2079 } // namespace internal | 2081 } // namespace internal |
2080 } // namespace v8 | 2082 } // namespace v8 |
OLD | NEW |