Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(190)

Side by Side Diff: test/unittests/wasm/wasm-module-builder-unittest.cc

Issue 2594993002: [wasm] Rename wasm::LocalType to wasm::ValueType and kAst* to kWasm* (Closed)
Patch Set: Fix inspector tests Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « test/unittests/wasm/module-decoder-unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "test/unittests/test-utils.h" 5 #include "test/unittests/test-utils.h"
6 6
7 #include "src/v8.h" 7 #include "src/v8.h"
8 8
9 #include "src/wasm/function-body-decoder.h" 9 #include "src/wasm/function-body-decoder.h"
10 #include "src/wasm/wasm-module-builder.h" 10 #include "src/wasm/wasm-module-builder.h"
11 11
12 #include "test/common/wasm/test-signatures.h" 12 #include "test/common/wasm/test-signatures.h"
13 13
14 namespace v8 { 14 namespace v8 {
15 namespace internal { 15 namespace internal {
16 namespace wasm { 16 namespace wasm {
17 17
18 class WasmModuleBuilderTest : public TestWithZone { 18 class WasmModuleBuilderTest : public TestWithZone {
19 protected: 19 protected:
20 void AddLocal(WasmFunctionBuilder* f, LocalType type) { 20 void AddLocal(WasmFunctionBuilder* f, ValueType type) {
21 uint16_t index = f->AddLocal(type); 21 uint16_t index = f->AddLocal(type);
22 f->EmitGetLocal(index); 22 f->EmitGetLocal(index);
23 } 23 }
24 }; 24 };
25 25
26 TEST_F(WasmModuleBuilderTest, Regression_647329) { 26 TEST_F(WasmModuleBuilderTest, Regression_647329) {
27 // Test crashed with asan. 27 // Test crashed with asan.
28 ZoneBuffer buffer(zone()); 28 ZoneBuffer buffer(zone());
29 const size_t kSize = ZoneBuffer::kInitialSize * 3 + 4096 + 100; 29 const size_t kSize = ZoneBuffer::kInitialSize * 3 + 4096 + 100;
30 byte data[kSize]; 30 byte data[kSize];
31 buffer.write(data, kSize); 31 buffer.write(data, kSize);
32 } 32 }
33 33
34 } // namespace wasm 34 } // namespace wasm
35 } // namespace internal 35 } // namespace internal
36 } // namespace v8 36 } // namespace v8
OLDNEW
« no previous file with comments | « test/unittests/wasm/module-decoder-unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698