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 2489 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2500 } | 2500 } |
2501 | 2501 |
2502 | 2502 |
2503 void FullCodeGenerator::EmitGetFromCache(ZoneList<Expression*>* args) { | 2503 void FullCodeGenerator::EmitGetFromCache(ZoneList<Expression*>* args) { |
2504 ASSERT_EQ(2, args->length()); | 2504 ASSERT_EQ(2, args->length()); |
2505 | 2505 |
2506 ASSERT_NE(NULL, args->at(0)->AsLiteral()); | 2506 ASSERT_NE(NULL, args->at(0)->AsLiteral()); |
2507 int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->handle()))->value(); | 2507 int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->handle()))->value(); |
2508 | 2508 |
2509 Handle<FixedArray> jsfunction_result_caches( | 2509 Handle<FixedArray> jsfunction_result_caches( |
2510 Top::global_context()->jsfunction_result_caches()); | 2510 Isolate::Current()->global_context()->jsfunction_result_caches()); |
2511 if (jsfunction_result_caches->length() <= cache_id) { | 2511 if (jsfunction_result_caches->length() <= cache_id) { |
2512 __ Abort("Attempt to use undefined cache."); | 2512 __ Abort("Attempt to use undefined cache."); |
2513 __ LoadRoot(r0, Heap::kUndefinedValueRootIndex); | 2513 __ LoadRoot(r0, Heap::kUndefinedValueRootIndex); |
2514 Apply(context_, r0); | 2514 Apply(context_, r0); |
2515 return; | 2515 return; |
2516 } | 2516 } |
2517 | 2517 |
2518 VisitForValue(args->at(1), kAccumulator); | 2518 VisitForValue(args->at(1), kAccumulator); |
2519 | 2519 |
2520 Register key = r0; | 2520 Register key = r0; |
(...skipping 631 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3152 __ mov(r1, Operand(r1, ASR, 1)); // Un-smi-tag value. | 3152 __ mov(r1, Operand(r1, ASR, 1)); // Un-smi-tag value. |
3153 __ add(pc, r1, Operand(masm_->CodeObject())); | 3153 __ add(pc, r1, Operand(masm_->CodeObject())); |
3154 } | 3154 } |
3155 | 3155 |
3156 | 3156 |
3157 #undef __ | 3157 #undef __ |
3158 | 3158 |
3159 } } // namespace v8::internal | 3159 } } // namespace v8::internal |
3160 | 3160 |
3161 #endif // V8_TARGET_ARCH_ARM | 3161 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |