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

Side by Side Diff: src/wasm/wasm-objects.h

Issue 2509323002: [wasm] Implement frame printing for debug (Closed)
Patch Set: What's wrong about constexpr?? Created 4 years, 1 month 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
OLDNEW
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/objects-inl.h" 8 #include "src/objects-inl.h"
9 #include "src/wasm/managed.h" 9 #include "src/wasm/managed.h"
10 10
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
252 WCM_PROPERTY_TABLE(DECLARATION) 252 WCM_PROPERTY_TABLE(DECLARATION)
253 #undef DECLARATION 253 #undef DECLARATION
254 254
255 static bool IsWasmCompiledModule(Object* obj); 255 static bool IsWasmCompiledModule(Object* obj);
256 256
257 void PrintInstancesChain(); 257 void PrintInstancesChain();
258 258
259 static void RecreateModuleWrapper(Isolate* isolate, 259 static void RecreateModuleWrapper(Isolate* isolate,
260 Handle<FixedArray> compiled_module); 260 Handle<FixedArray> compiled_module);
261 261
262 // Extract a function name from the given wasm instance. 262 // Get the function name of the function identified by the given index.
263 // Returns a null handle if the function is unnamed or the name is not a valid 263 // Returns a null handle if the function is unnamed or the name is not a valid
264 // UTF-8 string. 264 // UTF-8 string.
265 static MaybeHandle<String> GetFunctionName( 265 static MaybeHandle<String> GetFunctionName(
266 Handle<WasmCompiledModule> compiled_module, uint32_t func_index); 266 Handle<WasmCompiledModule> compiled_module, uint32_t func_index);
267 267
268 // Get the raw bytes of the function name of the function identified by the
269 // given index.
270 // Meant to be used for debugging or frame printing.
271 // Does not allocate, hence gc-safe.
272 Vector<const uint8_t> GetRawFunctionName(uint32_t func_index);
273
268 private: 274 private:
269 void InitId(); 275 void InitId();
270 276
271 DISALLOW_IMPLICIT_CONSTRUCTORS(WasmCompiledModule); 277 DISALLOW_IMPLICIT_CONSTRUCTORS(WasmCompiledModule);
272 }; 278 };
273 279
274 class WasmDebugInfo : public FixedArray { 280 class WasmDebugInfo : public FixedArray {
275 public: 281 public:
276 enum class Fields { kFieldCount }; 282 enum class Fields { kFieldCount };
277 283
(...skipping 27 matching lines...) Expand all
305 int func_index, int byte_offset); 311 int func_index, int byte_offset);
306 }; 312 };
307 313
308 #undef DECLARE_ACCESSORS 314 #undef DECLARE_ACCESSORS
309 #undef DECLARE_OPTIONAL_ACCESSORS 315 #undef DECLARE_OPTIONAL_ACCESSORS
310 316
311 } // namespace internal 317 } // namespace internal
312 } // namespace v8 318 } // namespace v8
313 319
314 #endif // V8_WASM_OBJECTS_H_ 320 #endif // V8_WASM_OBJECTS_H_
OLDNEW
« src/frames.cc ('K') | « src/frames.cc ('k') | src/wasm/wasm-objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698