OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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 #ifndef V8_WASM_OBJECTS_H_ | 5 #ifndef V8_WASM_OBJECTS_H_ |
6 #define V8_WASM_OBJECTS_H_ | 6 #define V8_WASM_OBJECTS_H_ |
7 | 7 |
8 #include "src/debug/interface-types.h" | 8 #include "src/debug/interface-types.h" |
9 #include "src/objects-inl.h" | 9 #include "src/objects-inl.h" |
10 #include "src/trap-handler/trap-handler.h" | 10 #include "src/trap-handler/trap-handler.h" |
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
375 // TODO(clemensh): Exclude this object from serialization. | 375 // TODO(clemensh): Exclude this object from serialization. |
376 class WasmDebugInfo : public FixedArray { | 376 class WasmDebugInfo : public FixedArray { |
377 enum Fields { kInstance, kFieldCount }; | 377 enum Fields { kInstance, kFieldCount }; |
378 | 378 |
379 public: | 379 public: |
380 static Handle<WasmDebugInfo> New(Handle<WasmInstanceObject>); | 380 static Handle<WasmDebugInfo> New(Handle<WasmInstanceObject>); |
381 | 381 |
382 static bool IsDebugInfo(Object*); | 382 static bool IsDebugInfo(Object*); |
383 static WasmDebugInfo* cast(Object*); | 383 static WasmDebugInfo* cast(Object*); |
384 | 384 |
| 385 static Object* GetInterpreterArgBuffer(Handle<WasmDebugInfo>, int func_index); |
| 386 |
| 387 static void RunInterpreter(Handle<WasmDebugInfo>, int func_index); |
| 388 |
385 DECLARE_GETTER(wasm_instance, WasmInstanceObject); | 389 DECLARE_GETTER(wasm_instance, WasmInstanceObject); |
386 }; | 390 }; |
387 | 391 |
388 class WasmInstanceWrapper : public FixedArray { | 392 class WasmInstanceWrapper : public FixedArray { |
389 public: | 393 public: |
390 static Handle<WasmInstanceWrapper> New(Isolate* isolate, | 394 static Handle<WasmInstanceWrapper> New(Isolate* isolate, |
391 Handle<WasmInstanceObject> instance); | 395 Handle<WasmInstanceObject> instance); |
392 static WasmInstanceWrapper* cast(Object* fixed_array) { | 396 static WasmInstanceWrapper* cast(Object* fixed_array) { |
393 SLOW_DCHECK(IsWasmInstanceWrapper(fixed_array)); | 397 SLOW_DCHECK(IsWasmInstanceWrapper(fixed_array)); |
394 return reinterpret_cast<WasmInstanceWrapper*>(fixed_array); | 398 return reinterpret_cast<WasmInstanceWrapper*>(fixed_array); |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
440 }; | 444 }; |
441 }; | 445 }; |
442 | 446 |
443 #undef DECLARE_ACCESSORS | 447 #undef DECLARE_ACCESSORS |
444 #undef DECLARE_OPTIONAL_ACCESSORS | 448 #undef DECLARE_OPTIONAL_ACCESSORS |
445 | 449 |
446 } // namespace internal | 450 } // namespace internal |
447 } // namespace v8 | 451 } // namespace v8 |
448 | 452 |
449 #endif // V8_WASM_OBJECTS_H_ | 453 #endif // V8_WASM_OBJECTS_H_ |
OLD | NEW |