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 |
11 // with the distribution. | 11 // with the distribution. |
12 // * Neither the name of Google Inc. nor the names of its | 12 // * Neither the name of Google Inc. nor the names of its |
13 // contributors may be used to endorse or promote products derived | 13 // contributors may be used to endorse or promote products derived |
14 // from this software without specific prior written permission. | 14 // from this software without specific prior written permission. |
15 // | 15 // |
16 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | 16 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |
17 // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | 17 // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT |
18 // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | 18 // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |
19 // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | 19 // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT |
20 // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | 20 // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
21 // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | 21 // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
22 // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | 22 // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
23 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 23 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
27 | 27 |
| 28 |
| 29 #include "v8.h" |
| 30 #include "macro-assembler.h" |
| 31 #include "register-allocator-inl.h" |
| 32 #include "codegen.h" |
| 33 |
| 34 namespace v8 { namespace internal { |
| 35 |
| 36 CodeGenerator::CodeGenerator(int buffer_size, |
| 37 Handle<Script> script, |
| 38 bool is_eval) |
| 39 : is_eval_(is_eval), |
| 40 script_(script), |
| 41 deferred_(8), |
| 42 masm_(new MacroAssembler(NULL, buffer_size)), |
| 43 scope_(NULL), |
| 44 frame_(NULL), |
| 45 allocator_(NULL), |
| 46 state_(NULL), |
| 47 loop_nesting_(0), |
| 48 function_return_is_shadowed_(false), |
| 49 in_spilled_code_(false) { |
| 50 } |
| 51 |
| 52 void CodeGenerator::DeclareGlobals(Handle<FixedArray> a) { |
| 53 UNIMPLEMENTED(); |
| 54 } |
| 55 |
| 56 void CodeGenerator::GenCode(FunctionLiteral* a) { |
| 57 masm_->int3(); // UNIMPLEMENTED |
| 58 } |
| 59 |
| 60 void CodeGenerator::GenerateFastCaseSwitchJumpTable(SwitchStatement* a, |
| 61 int b, |
| 62 int c, |
| 63 Label* d, |
| 64 Vector<Label*> e, |
| 65 Vector<Label> f) { |
| 66 UNIMPLEMENTED(); |
| 67 } |
| 68 |
| 69 void CodeGenerator::VisitStatements(ZoneList<Statement*>* a) { |
| 70 UNIMPLEMENTED(); |
| 71 } |
| 72 |
| 73 void CodeGenerator::VisitBlock(Block* a) { |
| 74 UNIMPLEMENTED(); |
| 75 } |
| 76 |
| 77 void CodeGenerator::VisitDeclaration(Declaration* a) { |
| 78 UNIMPLEMENTED(); |
| 79 } |
| 80 |
| 81 void CodeGenerator::VisitExpressionStatement(ExpressionStatement* a) { |
| 82 UNIMPLEMENTED(); |
| 83 } |
| 84 |
| 85 void CodeGenerator::VisitEmptyStatement(EmptyStatement* a) { |
| 86 UNIMPLEMENTED(); |
| 87 } |
| 88 |
| 89 void CodeGenerator::VisitIfStatement(IfStatement* a) { |
| 90 UNIMPLEMENTED(); |
| 91 } |
| 92 |
| 93 void CodeGenerator::VisitContinueStatement(ContinueStatement* a) { |
| 94 UNIMPLEMENTED(); |
| 95 } |
| 96 |
| 97 void CodeGenerator::VisitBreakStatement(BreakStatement* a) { |
| 98 UNIMPLEMENTED(); |
| 99 } |
| 100 |
| 101 void CodeGenerator::VisitReturnStatement(ReturnStatement* a) { |
| 102 UNIMPLEMENTED(); |
| 103 } |
| 104 |
| 105 void CodeGenerator::VisitWithEnterStatement(WithEnterStatement* a) { |
| 106 UNIMPLEMENTED(); |
| 107 } |
| 108 |
| 109 void CodeGenerator::VisitWithExitStatement(WithExitStatement* a) { |
| 110 UNIMPLEMENTED(); |
| 111 } |
| 112 |
| 113 void CodeGenerator::VisitSwitchStatement(SwitchStatement* a) { |
| 114 UNIMPLEMENTED(); |
| 115 } |
| 116 |
| 117 void CodeGenerator::VisitLoopStatement(LoopStatement* a) { |
| 118 UNIMPLEMENTED(); |
| 119 } |
| 120 |
| 121 void CodeGenerator::VisitForInStatement(ForInStatement* a) { |
| 122 UNIMPLEMENTED(); |
| 123 } |
| 124 |
| 125 void CodeGenerator::VisitTryCatch(TryCatch* a) { |
| 126 UNIMPLEMENTED(); |
| 127 } |
| 128 |
| 129 void CodeGenerator::VisitTryFinally(TryFinally* a) { |
| 130 UNIMPLEMENTED(); |
| 131 } |
| 132 |
| 133 void CodeGenerator::VisitDebuggerStatement(DebuggerStatement* a) { |
| 134 UNIMPLEMENTED(); |
| 135 } |
| 136 |
| 137 void CodeGenerator::VisitFunctionLiteral(FunctionLiteral* a) { |
| 138 UNIMPLEMENTED(); |
| 139 } |
| 140 |
| 141 void CodeGenerator::VisitFunctionBoilerplateLiteral( |
| 142 FunctionBoilerplateLiteral* a) { |
| 143 UNIMPLEMENTED(); |
| 144 } |
| 145 |
| 146 void CodeGenerator::VisitConditional(Conditional* a) { |
| 147 UNIMPLEMENTED(); |
| 148 } |
| 149 |
| 150 void CodeGenerator::VisitSlot(Slot* a) { |
| 151 UNIMPLEMENTED(); |
| 152 } |
| 153 |
| 154 void CodeGenerator::VisitVariableProxy(VariableProxy* a) { |
| 155 UNIMPLEMENTED(); |
| 156 } |
| 157 |
| 158 void CodeGenerator::VisitLiteral(Literal* a) { |
| 159 UNIMPLEMENTED(); |
| 160 } |
| 161 |
| 162 void CodeGenerator::VisitRegExpLiteral(RegExpLiteral* a) { |
| 163 UNIMPLEMENTED(); |
| 164 } |
| 165 |
| 166 void CodeGenerator::VisitObjectLiteral(ObjectLiteral* a) { |
| 167 UNIMPLEMENTED(); |
| 168 } |
| 169 |
| 170 void CodeGenerator::VisitArrayLiteral(ArrayLiteral* a) { |
| 171 UNIMPLEMENTED(); |
| 172 } |
| 173 |
| 174 void CodeGenerator::VisitCatchExtensionObject(CatchExtensionObject* a) { |
| 175 UNIMPLEMENTED(); |
| 176 } |
| 177 |
| 178 void CodeGenerator::VisitAssignment(Assignment* a) { |
| 179 UNIMPLEMENTED(); |
| 180 } |
| 181 |
| 182 void CodeGenerator::VisitThrow(Throw* a) { |
| 183 UNIMPLEMENTED(); |
| 184 } |
| 185 |
| 186 void CodeGenerator::VisitProperty(Property* a) { |
| 187 UNIMPLEMENTED(); |
| 188 } |
| 189 |
| 190 void CodeGenerator::VisitCall(Call* a) { |
| 191 UNIMPLEMENTED(); |
| 192 } |
| 193 |
| 194 void CodeGenerator::VisitCallEval(CallEval* a) { |
| 195 UNIMPLEMENTED(); |
| 196 } |
| 197 |
| 198 void CodeGenerator::VisitCallNew(CallNew* a) { |
| 199 UNIMPLEMENTED(); |
| 200 } |
| 201 |
| 202 void CodeGenerator::VisitCallRuntime(CallRuntime* a) { |
| 203 UNIMPLEMENTED(); |
| 204 } |
| 205 |
| 206 void CodeGenerator::VisitUnaryOperation(UnaryOperation* a) { |
| 207 UNIMPLEMENTED(); |
| 208 } |
| 209 |
| 210 void CodeGenerator::VisitCountOperation(CountOperation* a) { |
| 211 UNIMPLEMENTED(); |
| 212 } |
| 213 |
| 214 void CodeGenerator::VisitBinaryOperation(BinaryOperation* a) { |
| 215 UNIMPLEMENTED(); |
| 216 } |
| 217 |
| 218 void CodeGenerator::VisitCompareOperation(CompareOperation* a) { |
| 219 UNIMPLEMENTED(); |
| 220 } |
| 221 |
| 222 void CodeGenerator::VisitThisFunction(ThisFunction* a) { |
| 223 UNIMPLEMENTED(); |
| 224 } |
| 225 |
| 226 |
| 227 void CEntryStub::GenerateBody(MacroAssembler* masm, bool is_debug_break) { |
| 228 masm->int3(); // TODO(X64): UNIMPLEMENTED. |
| 229 } |
| 230 |
| 231 void JSEntryStub::GenerateBody(MacroAssembler* masm, bool is_construct) { |
| 232 masm->int3(); // TODO(X64): UNIMPLEMENTED. |
| 233 } |
| 234 |
| 235 |
| 236 |
| 237 } } // namespace v8::internal |
OLD | NEW |