| OLD | NEW |
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 168 | 168 |
| 169 ASSERT(allocator_ == NULL); | 169 ASSERT(allocator_ == NULL); |
| 170 RegisterAllocator register_allocator(this); | 170 RegisterAllocator register_allocator(this); |
| 171 allocator_ = ®ister_allocator; | 171 allocator_ = ®ister_allocator; |
| 172 ASSERT(frame_ == NULL); | 172 ASSERT(frame_ == NULL); |
| 173 frame_ = new VirtualFrame(); | 173 frame_ = new VirtualFrame(); |
| 174 cc_reg_ = al; | 174 cc_reg_ = al; |
| 175 | 175 |
| 176 // Adjust for function-level loop nesting. | 176 // Adjust for function-level loop nesting. |
| 177 ASSERT_EQ(0, loop_nesting_); | 177 ASSERT_EQ(0, loop_nesting_); |
| 178 loop_nesting_ = info->loop_nesting(); | 178 loop_nesting_ = info->is_in_loop() ? 1 : 0; |
| 179 | 179 |
| 180 { | 180 { |
| 181 CodeGenState state(this); | 181 CodeGenState state(this); |
| 182 | 182 |
| 183 // Entry: | 183 // Entry: |
| 184 // Stack: receiver, arguments | 184 // Stack: receiver, arguments |
| 185 // lr: return address | 185 // lr: return address |
| 186 // fp: caller's frame pointer | 186 // fp: caller's frame pointer |
| 187 // sp: stack pointer | 187 // sp: stack pointer |
| 188 // r1: called JS function | 188 // r1: called JS function |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 332 // If the return target has dangling jumps to it, then we have not | 332 // If the return target has dangling jumps to it, then we have not |
| 333 // yet generated the return sequence. This can happen when (a) | 333 // yet generated the return sequence. This can happen when (a) |
| 334 // control does not flow off the end of the body so we did not | 334 // control does not flow off the end of the body so we did not |
| 335 // compile an artificial return statement just above, and (b) there | 335 // compile an artificial return statement just above, and (b) there |
| 336 // are return statements in the body but (c) they are all shadowed. | 336 // are return statements in the body but (c) they are all shadowed. |
| 337 function_return_.Bind(); | 337 function_return_.Bind(); |
| 338 GenerateReturnSequence(); | 338 GenerateReturnSequence(); |
| 339 } | 339 } |
| 340 | 340 |
| 341 // Adjust for function-level loop nesting. | 341 // Adjust for function-level loop nesting. |
| 342 ASSERT(loop_nesting_ == info->loop_nesting()); | 342 ASSERT(loop_nesting_ == info->is_in_loop()? 1 : 0); |
| 343 loop_nesting_ = 0; | 343 loop_nesting_ = 0; |
| 344 | 344 |
| 345 // Code generation state must be reset. | 345 // Code generation state must be reset. |
| 346 ASSERT(!has_cc()); | 346 ASSERT(!has_cc()); |
| 347 ASSERT(state_ == NULL); | 347 ASSERT(state_ == NULL); |
| 348 ASSERT(loop_nesting() == 0); | 348 ASSERT(loop_nesting() == 0); |
| 349 ASSERT(!function_return_is_shadowed_); | 349 ASSERT(!function_return_is_shadowed_); |
| 350 function_return_.Unuse(); | 350 function_return_.Unuse(); |
| 351 DeleteFrame(); | 351 DeleteFrame(); |
| 352 | 352 |
| (...skipping 6951 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7304 BinaryOpIC::GetName(runtime_operands_type_)); | 7304 BinaryOpIC::GetName(runtime_operands_type_)); |
| 7305 return name_; | 7305 return name_; |
| 7306 } | 7306 } |
| 7307 | 7307 |
| 7308 | 7308 |
| 7309 #undef __ | 7309 #undef __ |
| 7310 | 7310 |
| 7311 } } // namespace v8::internal | 7311 } } // namespace v8::internal |
| 7312 | 7312 |
| 7313 #endif // V8_TARGET_ARCH_ARM | 7313 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |