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

Side by Side Diff: runtime/vm/object.cc

Issue 1352483002: Add benchmark output to compiler stats. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: cleanup Created 5 years, 3 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
« runtime/vm/benchmark_test.cc ('K') | « runtime/vm/isolate.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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/object.h" 5 #include "vm/object.h"
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/assembler.h" 9 #include "vm/assembler.h"
10 #include "vm/cpu.h" 10 #include "vm/cpu.h"
(...skipping 8564 matching lines...) Expand 10 before | Expand all | Expand 10 after
8575 const TokenStream& tkns = TokenStream::Handle(zone, tokens()); 8575 const TokenStream& tkns = TokenStream::Handle(zone, tokens());
8576 if (!tkns.IsNull()) { 8576 if (!tkns.IsNull()) {
8577 // Already tokenized. 8577 // Already tokenized.
8578 return; 8578 return;
8579 } 8579 }
8580 // Get the source, scan and allocate the token stream. 8580 // Get the source, scan and allocate the token stream.
8581 VMTagScope tagScope(thread, VMTag::kCompileScannerTagId); 8581 VMTagScope tagScope(thread, VMTag::kCompileScannerTagId);
8582 CSTAT_TIMER_SCOPE(thread, scanner_timer); 8582 CSTAT_TIMER_SCOPE(thread, scanner_timer);
8583 const String& src = String::Handle(zone, Source()); 8583 const String& src = String::Handle(zone, Source());
8584 Scanner scanner(src, private_key); 8584 Scanner scanner(src, private_key);
8585 set_tokens(TokenStream::Handle(zone, 8585 const Scanner::GrowableTokenStream& ts = scanner.GetStream();
8586 TokenStream::New(scanner.GetStream(), 8586 INC_STAT(thread, num_tokens_scanned, ts.length());
8587 private_key))); 8587 set_tokens(TokenStream::Handle(zone, TokenStream::New(ts, private_key)));
8588 INC_STAT(thread, src_length, src.Length()); 8588 INC_STAT(thread, src_length, src.Length());
8589 } 8589 }
8590 8590
8591 8591
8592 void Script::SetLocationOffset(intptr_t line_offset, 8592 void Script::SetLocationOffset(intptr_t line_offset,
8593 intptr_t col_offset) const { 8593 intptr_t col_offset) const {
8594 ASSERT(line_offset >= 0); 8594 ASSERT(line_offset >= 0);
8595 ASSERT(col_offset >= 0); 8595 ASSERT(col_offset >= 0);
8596 StoreNonPointer(&raw_ptr()->line_offset_, line_offset); 8596 StoreNonPointer(&raw_ptr()->line_offset_, line_offset);
8597 StoreNonPointer(&raw_ptr()->col_offset_, col_offset); 8597 StoreNonPointer(&raw_ptr()->col_offset_, col_offset);
(...skipping 12837 matching lines...) Expand 10 before | Expand all | Expand 10 after
21435 return tag_label.ToCString(); 21435 return tag_label.ToCString();
21436 } 21436 }
21437 21437
21438 21438
21439 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const { 21439 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const {
21440 Instance::PrintJSONImpl(stream, ref); 21440 Instance::PrintJSONImpl(stream, ref);
21441 } 21441 }
21442 21442
21443 21443
21444 } // namespace dart 21444 } // namespace dart
OLDNEW
« runtime/vm/benchmark_test.cc ('K') | « runtime/vm/isolate.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698