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

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

Issue 1847543002: Expose a lower bound of malloc'd memory via heap statistics (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates Created 4 years, 8 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/regexp/jsregexp.cc ('k') | src/type-cache.h » ('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 368 matching lines...) Expand 10 before | Expand all | Expand 10 after
379 return true; 379 return true;
380 } 380 }
381 } 381 }
382 return false; 382 return false;
383 } 383 }
384 384
385 385
386 Handle<String> RenderCallSite(Isolate* isolate, Handle<Object> object) { 386 Handle<String> RenderCallSite(Isolate* isolate, Handle<Object> object) {
387 MessageLocation location; 387 MessageLocation location;
388 if (ComputeLocation(isolate, &location)) { 388 if (ComputeLocation(isolate, &location)) {
389 Zone zone; 389 Zone zone(isolate->allocator());
390 base::SmartPointer<ParseInfo> info( 390 base::SmartPointer<ParseInfo> info(
391 location.function()->shared()->is_function() 391 location.function()->shared()->is_function()
392 ? new ParseInfo(&zone, location.function()) 392 ? new ParseInfo(&zone, location.function())
393 : new ParseInfo(&zone, location.script())); 393 : new ParseInfo(&zone, location.script()));
394 if (Parser::ParseStatic(info.get())) { 394 if (Parser::ParseStatic(info.get())) {
395 CallPrinter printer(isolate, location.function()->shared()->IsBuiltin()); 395 CallPrinter printer(isolate, location.function()->shared()->IsBuiltin());
396 const char* string = printer.Print(info->literal(), location.start_pos()); 396 const char* string = printer.Print(info->literal(), location.start_pos());
397 if (strlen(string) > 0) { 397 if (strlen(string) > 0) {
398 return isolate->factory()->NewStringFromAsciiChecked(string); 398 return isolate->factory()->NewStringFromAsciiChecked(string);
399 } 399 }
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
469 std::stringstream stats_stream; 469 std::stringstream stats_stream;
470 isolate->counters()->runtime_call_stats()->Print(stats_stream); 470 isolate->counters()->runtime_call_stats()->Print(stats_stream);
471 Handle<String> result = 471 Handle<String> result =
472 isolate->factory()->NewStringFromAsciiChecked(stats_stream.str().c_str()); 472 isolate->factory()->NewStringFromAsciiChecked(stats_stream.str().c_str());
473 isolate->counters()->runtime_call_stats()->Reset(); 473 isolate->counters()->runtime_call_stats()->Reset();
474 return *result; 474 return *result;
475 } 475 }
476 476
477 } // namespace internal 477 } // namespace internal
478 } // namespace v8 478 } // namespace v8
OLDNEW
« no previous file with comments | « src/regexp/jsregexp.cc ('k') | src/type-cache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698