| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 967 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 978 return code; | 978 return code; |
| 979 } | 979 } |
| 980 | 980 |
| 981 | 981 |
| 982 Handle<Code> StubCache::ComputeCallInitialize(int argc, RelocInfo::Mode mode) { | 982 Handle<Code> StubCache::ComputeCallInitialize(int argc, RelocInfo::Mode mode) { |
| 983 return ComputeCallInitialize(argc, mode, Code::CALL_IC); | 983 return ComputeCallInitialize(argc, mode, Code::CALL_IC); |
| 984 } | 984 } |
| 985 | 985 |
| 986 | 986 |
| 987 Handle<Code> StubCache::ComputeKeyedCallInitialize(int argc) { | 987 Handle<Code> StubCache::ComputeKeyedCallInitialize(int argc) { |
| 988 return ComputeCallInitialize(argc, RelocInfo::CODE_TARGET, Code::KEYED_CALL_IC
); | 988 return ComputeCallInitialize(argc, RelocInfo::CODE_TARGET, |
| 989 Code::KEYED_CALL_IC); |
| 989 } | 990 } |
| 990 | 991 |
| 991 | 992 |
| 992 Handle<Code> StubCache::ComputeCallPreMonomorphic( | 993 Handle<Code> StubCache::ComputeCallPreMonomorphic( |
| 993 int argc, | 994 int argc, |
| 994 Code::Kind kind, | 995 Code::Kind kind, |
| 995 Code::ExtraICState extra_state) { | 996 Code::ExtraICState extra_state) { |
| 996 Code::Flags flags = | 997 Code::Flags flags = |
| 997 Code::ComputeFlags(kind, PREMONOMORPHIC, extra_state, NORMAL, argc); | 998 Code::ComputeFlags(kind, PREMONOMORPHIC, extra_state, NORMAL, argc); |
| 998 Handle<NumberDictionary> cache = isolate_->factory()->non_monomorphic_cache(); | 999 Handle<NumberDictionary> cache = isolate_->factory()->non_monomorphic_cache(); |
| (...skipping 616 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1615 Code::Kind kind = Code::ExtractKindFromFlags(flags); | 1616 Code::Kind kind = Code::ExtractKindFromFlags(flags); |
| 1616 USE(kind); | 1617 USE(kind); |
| 1617 PROFILE(isolate(), | 1618 PROFILE(isolate(), |
| 1618 CodeCreateEvent(CALL_LOGGER_TAG(kind, CALL_DEBUG_BREAK_TAG), | 1619 CodeCreateEvent(CALL_LOGGER_TAG(kind, CALL_DEBUG_BREAK_TAG), |
| 1619 code, code->arguments_count())); | 1620 code, code->arguments_count())); |
| 1620 return result; | 1621 return result; |
| 1621 } | 1622 } |
| 1622 | 1623 |
| 1623 | 1624 |
| 1624 Handle<Code> StubCompiler::CompileCallDebugPrepareStepIn(Code::Flags flags) { | 1625 Handle<Code> StubCompiler::CompileCallDebugPrepareStepIn(Code::Flags flags) { |
| 1625 CALL_HEAP_FUNCTION(isolate(), | 1626 CALL_HEAP_FUNCTION( |
| 1626 (set_failure(NULL), TryCompileCallDebugPrepareStepIn(flags)
), | 1627 isolate(), |
| 1627 Code); | 1628 (set_failure(NULL), TryCompileCallDebugPrepareStepIn(flags)), |
| 1629 Code); |
| 1628 } | 1630 } |
| 1629 | 1631 |
| 1630 | 1632 |
| 1631 MaybeObject* StubCompiler::TryCompileCallDebugPrepareStepIn(Code::Flags flags) { | 1633 MaybeObject* StubCompiler::TryCompileCallDebugPrepareStepIn(Code::Flags flags) { |
| 1632 HandleScope scope(isolate()); | 1634 HandleScope scope(isolate()); |
| 1633 // Use the same code for the the step in preparations as we do for | 1635 // Use the same code for the the step in preparations as we do for |
| 1634 // the miss case. | 1636 // the miss case. |
| 1635 int argc = Code::ExtractArgumentsCountFromFlags(flags); | 1637 int argc = Code::ExtractArgumentsCountFromFlags(flags); |
| 1636 Code::Kind kind = Code::ExtractKindFromFlags(flags); | 1638 Code::Kind kind = Code::ExtractKindFromFlags(flags); |
| 1637 if (kind == Code::CALL_IC) { | 1639 if (kind == Code::CALL_IC) { |
| (...skipping 294 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1932 expected_receiver_type_ = | 1934 expected_receiver_type_ = |
| 1933 FunctionTemplateInfo::cast(signature->receiver()); | 1935 FunctionTemplateInfo::cast(signature->receiver()); |
| 1934 } | 1936 } |
| 1935 } | 1937 } |
| 1936 | 1938 |
| 1937 is_simple_api_call_ = true; | 1939 is_simple_api_call_ = true; |
| 1938 } | 1940 } |
| 1939 | 1941 |
| 1940 | 1942 |
| 1941 } } // namespace v8::internal | 1943 } } // namespace v8::internal |
| OLD | NEW |