| 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-containers.h" | 10 #include "src/zone-containers.h" | 
| (...skipping 1086 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 1097 | 1097 | 
| 1098   void PushIf(SsaEnv* end_env, SsaEnv* false_env) { | 1098   void PushIf(SsaEnv* end_env, SsaEnv* false_env) { | 
| 1099     int stack_depth = static_cast<int>(stack_.size()); | 1099     int stack_depth = static_cast<int>(stack_.size()); | 
| 1100     control_.push_back( | 1100     control_.push_back( | 
| 1101         {pc_, stack_depth, end_env, false_env, nullptr, kAstStmt, false}); | 1101         {pc_, stack_depth, end_env, false_env, nullptr, kAstStmt, false}); | 
| 1102   } | 1102   } | 
| 1103 | 1103 | 
| 1104   int DecodeLoadMem(LocalType type, MachineType mem_type) { | 1104   int DecodeLoadMem(LocalType type, MachineType mem_type) { | 
| 1105     MemoryAccessOperand operand(this, pc_); | 1105     MemoryAccessOperand operand(this, pc_); | 
| 1106     Value index = Pop(0, kAstI32); | 1106     Value index = Pop(0, kAstI32); | 
| 1107     TFNode* node = | 1107     TFNode* node = BUILD(LoadMem, type, mem_type, index.node, operand.offset, | 
| 1108         BUILD(LoadMem, type, mem_type, index.node, operand.offset, position()); | 1108                          operand.alignment, position()); | 
| 1109     Push(type, node); | 1109     Push(type, node); | 
| 1110     return 1 + operand.length; | 1110     return 1 + operand.length; | 
| 1111   } | 1111   } | 
| 1112 | 1112 | 
| 1113   int DecodeStoreMem(LocalType type, MachineType mem_type) { | 1113   int DecodeStoreMem(LocalType type, MachineType mem_type) { | 
| 1114     MemoryAccessOperand operand(this, pc_); | 1114     MemoryAccessOperand operand(this, pc_); | 
| 1115     Value val = Pop(1, type); | 1115     Value val = Pop(1, type); | 
| 1116     Value index = Pop(0, kAstI32); | 1116     Value index = Pop(0, kAstI32); | 
| 1117     BUILD(StoreMem, mem_type, index.node, operand.offset, val.node, position()); | 1117     BUILD(StoreMem, mem_type, index.node, operand.offset, operand.alignment, | 
|  | 1118           val.node, position()); | 
| 1118     Push(type, val.node); | 1119     Push(type, val.node); | 
| 1119     return 1 + operand.length; | 1120     return 1 + operand.length; | 
| 1120   } | 1121   } | 
| 1121 | 1122 | 
| 1122   void DoReturn() { | 1123   void DoReturn() { | 
| 1123     int count = static_cast<int>(sig_->return_count()); | 1124     int count = static_cast<int>(sig_->return_count()); | 
| 1124     TFNode** buffer = nullptr; | 1125     TFNode** buffer = nullptr; | 
| 1125     if (build()) buffer = builder_->Buffer(count); | 1126     if (build()) buffer = builder_->Buffer(count); | 
| 1126 | 1127 | 
| 1127     // Pop return values off the stack in reverse order. | 1128     // Pop return values off the stack in reverse order. | 
| (...skipping 518 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 1646 BitVector* AnalyzeLoopAssignmentForTesting(Zone* zone, size_t num_locals, | 1647 BitVector* AnalyzeLoopAssignmentForTesting(Zone* zone, size_t num_locals, | 
| 1647                                            const byte* start, const byte* end) { | 1648                                            const byte* start, const byte* end) { | 
| 1648   FunctionBody body = {nullptr, nullptr, nullptr, start, end}; | 1649   FunctionBody body = {nullptr, nullptr, nullptr, start, end}; | 
| 1649   SR_WasmDecoder decoder(zone, nullptr, body); | 1650   SR_WasmDecoder decoder(zone, nullptr, body); | 
| 1650   return decoder.AnalyzeLoopAssignmentForTesting(start, num_locals); | 1651   return decoder.AnalyzeLoopAssignmentForTesting(start, num_locals); | 
| 1651 } | 1652 } | 
| 1652 | 1653 | 
| 1653 }  // namespace wasm | 1654 }  // namespace wasm | 
| 1654 }  // namespace internal | 1655 }  // namespace internal | 
| 1655 }  // namespace v8 | 1656 }  // namespace v8 | 
| OLD | NEW | 
|---|