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

Side by Side Diff: src/runtime/runtime-internal.cc

Issue 1909353002: [wasm] Make wasm info available on the stack trace (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@wasm-offset-table-3
Patch Set: last changes Created 4 years, 7 months 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 | « src/runtime/runtime-function.cc ('k') | test/cctest/wasm/test-wasm-stack.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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/runtime/runtime-utils.h" 5 #include "src/runtime/runtime-utils.h"
6 6
7 #include "src/arguments.h" 7 #include "src/arguments.h"
8 #include "src/ast/prettyprinter.h" 8 #include "src/ast/prettyprinter.h"
9 #include "src/bootstrapper.h" 9 #include "src/bootstrapper.h"
10 #include "src/conversions.h" 10 #include "src/conversions.h"
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 CONVERT_ARG_HANDLE_CHECKED(String, arg1, 2); 327 CONVERT_ARG_HANDLE_CHECKED(String, arg1, 2);
328 CONVERT_ARG_HANDLE_CHECKED(String, arg2, 3); 328 CONVERT_ARG_HANDLE_CHECKED(String, arg2, 3);
329 Handle<String> result; 329 Handle<String> result;
330 ASSIGN_RETURN_FAILURE_ON_EXCEPTION( 330 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(
331 isolate, result, 331 isolate, result,
332 MessageTemplate::FormatMessage(template_index, arg0, arg1, arg2)); 332 MessageTemplate::FormatMessage(template_index, arg0, arg1, arg2));
333 isolate->native_context()->IncrementErrorsThrown(); 333 isolate->native_context()->IncrementErrorsThrown();
334 return *result; 334 return *result;
335 } 335 }
336 336
337 #define CALLSITE_GET(NAME, RETURN) \ 337 #define CALLSITE_GET(NAME, RETURN) \
338 RUNTIME_FUNCTION(Runtime_CallSite##NAME##RT) { \ 338 RUNTIME_FUNCTION(Runtime_CallSite##NAME##RT) { \
339 HandleScope scope(isolate); \ 339 HandleScope scope(isolate); \
340 DCHECK(args.length() == 1); \ 340 DCHECK(args.length() == 1); \
341 CONVERT_ARG_HANDLE_CHECKED(JSObject, call_site_obj, 0); \ 341 CONVERT_ARG_HANDLE_CHECKED(JSObject, call_site_obj, 0); \
342 Handle<String> result; \ 342 Handle<String> result; \
343 CallSite call_site(isolate, call_site_obj); \ 343 CallSite call_site(isolate, call_site_obj); \
344 RUNTIME_ASSERT(call_site.IsValid()); \ 344 RUNTIME_ASSERT(call_site.IsJavaScript() || call_site.IsWasm()); \
345 return RETURN(call_site.NAME(), isolate); \ 345 return RETURN(call_site.NAME(), isolate); \
346 } 346 }
347 347
348 static inline Object* ReturnDereferencedHandle(Handle<Object> obj, 348 static inline Object* ReturnDereferencedHandle(Handle<Object> obj,
349 Isolate* isolate) { 349 Isolate* isolate) {
350 return *obj; 350 return *obj;
351 } 351 }
352 352
353 353
354 static inline Object* ReturnPositiveNumberOrNull(int value, Isolate* isolate) { 354 static inline Object* ReturnPositiveNumberOrNull(int value, Isolate* isolate) {
355 if (value >= 0) return *isolate->factory()->NewNumberFromInt(value); 355 if (value >= 0) return *isolate->factory()->NewNumberFromInt(value);
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
515 } 515 }
516 516
517 RUNTIME_FUNCTION(Runtime_RunMicrotasks) { 517 RUNTIME_FUNCTION(Runtime_RunMicrotasks) {
518 HandleScope scope(isolate); 518 HandleScope scope(isolate);
519 DCHECK(args.length() == 0); 519 DCHECK(args.length() == 0);
520 isolate->RunMicrotasks(); 520 isolate->RunMicrotasks();
521 return isolate->heap()->undefined_value(); 521 return isolate->heap()->undefined_value();
522 } 522 }
523 } // namespace internal 523 } // namespace internal
524 } // namespace v8 524 } // namespace v8
OLDNEW
« no previous file with comments | « src/runtime/runtime-function.cc ('k') | test/cctest/wasm/test-wasm-stack.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698