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

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

Issue 1873283003: Provide a mechanism for naming a hash table so that it can be used in DumpStats to identify the tab… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: 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 1039 matching lines...) Expand 10 before | Expand all | Expand 10 after
1050 } 1050 }
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"; }
1061
1060 static bool IsMatch(const Object& a, const Object& b) { 1062 static bool IsMatch(const Object& a, const Object& b) {
1061 return a.IsString() && b.IsString() && 1063 return a.IsString() && b.IsString() &&
1062 String::Cast(a).Equals(String::Cast(b)); 1064 String::Cast(a).Equals(String::Cast(b));
1063 } 1065 }
1064 static uword Hash(const Object& obj) { 1066 static uword Hash(const Object& obj) {
1065 return String::Cast(obj).Hash(); 1067 return String::Cast(obj).Hash();
1066 } 1068 }
1067 static RawObject* NewKey(const String& str) { 1069 static RawObject* NewKey(const String& str) {
1068 return str.raw(); 1070 return str.raw();
1069 } 1071 }
(...skipping 1612 matching lines...) Expand 10 before | Expand all | Expand 10 after
2682 CompilationPipeline::New(thread->zone(), function); 2684 CompilationPipeline::New(thread->zone(), function);
2683 2685
2684 ASSERT(FLAG_precompiled_mode); 2686 ASSERT(FLAG_precompiled_mode);
2685 const bool optimized = function.IsOptimizable(); // False for natives. 2687 const bool optimized = function.IsOptimizable(); // False for natives.
2686 return PrecompileFunctionHelper(pipeline, function, optimized); 2688 return PrecompileFunctionHelper(pipeline, function, optimized);
2687 } 2689 }
2688 2690
2689 #endif // DART_PRECOMPILER 2691 #endif // DART_PRECOMPILER
2690 2692
2691 } // namespace dart 2693 } // 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