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

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

Issue 1882763002: Add usage and collision details to the hash table data structure in order to determine effectivenes… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: self-review-comments 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 | « runtime/vm/precompiler.h ('k') | runtime/vm/symbols.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 (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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/precompiler.h" 5 #include "vm/precompiler.h"
6 6
7 #include "vm/aot_optimizer.h" 7 #include "vm/aot_optimizer.h"
8 #include "vm/assembler.h" 8 #include "vm/assembler.h"
9 #include "vm/ast_printer.h" 9 #include "vm/ast_printer.h"
10 #include "vm/branch_optimizer.h" 10 #include "vm/branch_optimizer.h"
(...skipping 1040 matching lines...) Expand 10 before | Expand all | Expand 10 after
1051 } 1051 }
1052 } 1052 }
1053 } 1053 }
1054 } 1054 }
1055 } 1055 }
1056 1056
1057 1057
1058 class NameFunctionsTraits { 1058 class NameFunctionsTraits {
1059 public: 1059 public:
1060 static const char* Name() { return "NameFunctionsTraits"; } 1060 static const char* Name() { return "NameFunctionsTraits"; }
1061 static bool ReportStats() { return false; }
1061 1062
1062 static bool IsMatch(const Object& a, const Object& b) { 1063 static bool IsMatch(const Object& a, const Object& b) {
1063 return a.IsString() && b.IsString() && 1064 return a.IsString() && b.IsString() &&
1064 String::Cast(a).Equals(String::Cast(b)); 1065 String::Cast(a).Equals(String::Cast(b));
1065 } 1066 }
1066 static uword Hash(const Object& obj) { 1067 static uword Hash(const Object& obj) {
1067 return String::Cast(obj).Hash(); 1068 return String::Cast(obj).Hash();
1068 } 1069 }
1069 static RawObject* NewKey(const String& str) { 1070 static RawObject* NewKey(const String& str) {
1070 return str.raw(); 1071 return str.raw();
(...skipping 1613 matching lines...) Expand 10 before | Expand all | Expand 10 after
2684 CompilationPipeline::New(thread->zone(), function); 2685 CompilationPipeline::New(thread->zone(), function);
2685 2686
2686 ASSERT(FLAG_precompiled_mode); 2687 ASSERT(FLAG_precompiled_mode);
2687 const bool optimized = function.IsOptimizable(); // False for natives. 2688 const bool optimized = function.IsOptimizable(); // False for natives.
2688 return PrecompileFunctionHelper(pipeline, function, optimized); 2689 return PrecompileFunctionHelper(pipeline, function, optimized);
2689 } 2690 }
2690 2691
2691 #endif // DART_PRECOMPILER 2692 #endif // DART_PRECOMPILER
2692 2693
2693 } // namespace dart 2694 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/precompiler.h ('k') | runtime/vm/symbols.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698