OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 | 53 |
54 void Move(Location destination, Location source); | 54 void Move(Location destination, Location source); |
55 | 55 |
56 void Move(Location destination, Register source); | 56 void Move(Location destination, Register source); |
57 void Move(Location destination, Slot* source); | 57 void Move(Location destination, Slot* source); |
58 void Move(Location destination, Literal* source); | 58 void Move(Location destination, Literal* source); |
59 | 59 |
60 void Move(Register destination, Location source); | 60 void Move(Register destination, Location source); |
61 void Move(Slot* destination, Location source); | 61 void Move(Slot* destination, Location source); |
62 | 62 |
| 63 // Drop the TOS, and store source to destination. |
| 64 // If destination is TOS, just overwrite TOS with source. |
| 65 void DropAndMove(Location destination, Register source); |
| 66 |
63 void VisitDeclarations(ZoneList<Declaration*>* declarations); | 67 void VisitDeclarations(ZoneList<Declaration*>* declarations); |
64 Handle<JSFunction> BuildBoilerplate(FunctionLiteral* fun); | 68 Handle<JSFunction> BuildBoilerplate(FunctionLiteral* fun); |
65 void DeclareGlobals(Handle<FixedArray> pairs); | 69 void DeclareGlobals(Handle<FixedArray> pairs); |
66 | 70 |
67 void SetFunctionPosition(FunctionLiteral* fun); | 71 void SetFunctionPosition(FunctionLiteral* fun); |
68 void SetReturnPosition(FunctionLiteral* fun); | 72 void SetReturnPosition(FunctionLiteral* fun); |
69 void SetStatementPosition(Statement* stmt); | 73 void SetStatementPosition(Statement* stmt); |
70 void SetSourcePosition(int pos); | 74 void SetSourcePosition(int pos); |
71 | 75 |
72 // AST node visit functions. | 76 // AST node visit functions. |
73 #define DECLARE_VISIT(type) virtual void Visit##type(type* node); | 77 #define DECLARE_VISIT(type) virtual void Visit##type(type* node); |
74 AST_NODE_LIST(DECLARE_VISIT) | 78 AST_NODE_LIST(DECLARE_VISIT) |
75 #undef DECLARE_VISIT | 79 #undef DECLARE_VISIT |
76 | 80 |
77 MacroAssembler* masm_; | 81 MacroAssembler* masm_; |
78 FunctionLiteral* function_; | 82 FunctionLiteral* function_; |
79 Handle<Script> script_; | 83 Handle<Script> script_; |
80 bool is_eval_; | 84 bool is_eval_; |
81 | 85 |
82 DISALLOW_COPY_AND_ASSIGN(FastCodeGenerator); | 86 DISALLOW_COPY_AND_ASSIGN(FastCodeGenerator); |
83 }; | 87 }; |
84 | 88 |
85 | 89 |
86 } } // namespace v8::internal | 90 } } // namespace v8::internal |
87 | 91 |
88 #endif // V8_FAST_CODEGEN_H_ | 92 #endif // V8_FAST_CODEGEN_H_ |
OLD | NEW |