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

Side by Side Diff: runtime/vm/intrinsifier.h

Issue 1134623004: - Use conditional code inclusion for the dart_no_snapshot and dart executables using the MACRO DART… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 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 | Annotate | Revision Log
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 // Class for intrinsifying functions. 4 // Class for intrinsifying functions.
5 5
6 #ifndef VM_INTRINSIFIER_H_ 6 #ifndef VM_INTRINSIFIER_H_
7 #define VM_INTRINSIFIER_H_ 7 #define VM_INTRINSIFIER_H_
8 8
9 #include "vm/allocation.h" 9 #include "vm/allocation.h"
10 #include "vm/method_recognizer.h" 10 #include "vm/method_recognizer.h"
11 11
12 namespace dart { 12 namespace dart {
13 13
14 // Forward declarations. 14 // Forward declarations.
15 class Assembler; 15 class Assembler;
16 class FlowGraphCompiler; 16 class FlowGraphCompiler;
17 class Function; 17 class Function;
18 class TargetEntryInstr; 18 class TargetEntryInstr;
19 class ParsedFunction; 19 class ParsedFunction;
20 class FlowGraph; 20 class FlowGraph;
21 21
22 class Intrinsifier : public AllStatic { 22 class Intrinsifier : public AllStatic {
23 public: 23 public:
24 static void Intrinsify(const ParsedFunction& parsed_function, 24 static void Intrinsify(const ParsedFunction& parsed_function,
25 FlowGraphCompiler* compiler); 25 FlowGraphCompiler* compiler);
26 #if defined(DART_NO_SNAPSHOT)
26 static void InitializeState(); 27 static void InitializeState();
28 #endif
27 29
28 static bool GraphIntrinsify(const ParsedFunction& parsed_function, 30 static bool GraphIntrinsify(const ParsedFunction& parsed_function,
29 FlowGraphCompiler* compiler); 31 FlowGraphCompiler* compiler);
30 32
31 static intptr_t ParameterSlotFromSp(); 33 static intptr_t ParameterSlotFromSp();
32 34
33 private: 35 private:
34 static bool CanIntrinsify(const Function& function); 36 static bool CanIntrinsify(const Function& function);
35 37
36 #define DECLARE_FUNCTION(test_class_name, test_function_name, enum_name, fp) \ 38 #define DECLARE_FUNCTION(test_class_name, test_function_name, enum_name, fp) \
37 static void enum_name(Assembler* assembler); 39 static void enum_name(Assembler* assembler);
38 40
39 ALL_INTRINSICS_LIST(DECLARE_FUNCTION) 41 ALL_INTRINSICS_LIST(DECLARE_FUNCTION)
40 42
41 #undef DECLARE_FUNCTION 43 #undef DECLARE_FUNCTION
42 44
43 #define DECLARE_FUNCTION(test_class_name, test_function_name, enum_name, fp) \ 45 #define DECLARE_FUNCTION(test_class_name, test_function_name, enum_name, fp) \
44 static bool Build_##enum_name(FlowGraph* flow_graph); 46 static bool Build_##enum_name(FlowGraph* flow_graph);
45 47
46 GRAPH_INTRINSICS_LIST(DECLARE_FUNCTION) 48 GRAPH_INTRINSICS_LIST(DECLARE_FUNCTION)
47 49
48 #undef DECLARE_FUNCTION 50 #undef DECLARE_FUNCTION
49 }; 51 };
50 52
51 } // namespace dart 53 } // namespace dart
52 54
53 #endif // VM_INTRINSIFIER_H_ 55 #endif // VM_INTRINSIFIER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698