OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_CODE_STUBS_H_ | 5 #ifndef V8_CODE_STUBS_H_ |
6 #define V8_CODE_STUBS_H_ | 6 #define V8_CODE_STUBS_H_ |
7 | 7 |
8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/assembler.h" | 9 #include "src/assembler.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 956 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
967 | 967 |
968 Code::Kind GetCodeKind() const override { return Code::CALL_IC; } | 968 Code::Kind GetCodeKind() const override { return Code::CALL_IC; } |
969 | 969 |
970 InlineCacheState GetICState() const override { return GENERIC; } | 970 InlineCacheState GetICState() const override { return GENERIC; } |
971 | 971 |
972 ExtraICState GetExtraICState() const final { | 972 ExtraICState GetExtraICState() const final { |
973 return static_cast<ExtraICState>(minor_key_); | 973 return static_cast<ExtraICState>(minor_key_); |
974 } | 974 } |
975 | 975 |
976 protected: | 976 protected: |
977 int arg_count() const { | 977 int arg_count() const { return state().argc(); } |
978 DCHECK(!argc_in_register()); | |
979 return state().argc(); | |
980 } | |
981 ConvertReceiverMode convert_mode() const { return state().convert_mode(); } | 978 ConvertReceiverMode convert_mode() const { return state().convert_mode(); } |
982 TailCallMode tail_call_mode() const { return state().tail_call_mode(); } | 979 TailCallMode tail_call_mode() const { return state().tail_call_mode(); } |
983 bool argc_in_register() const { return state().argc_in_register(); } | |
984 | 980 |
985 CallICState state() const { | 981 CallICState state() const { |
986 return CallICState(static_cast<ExtraICState>(minor_key_)); | 982 return CallICState(static_cast<ExtraICState>(minor_key_)); |
987 } | 983 } |
988 | 984 |
989 // Code generation helpers. | 985 // Code generation helpers. |
990 void GenerateMiss(MacroAssembler* masm); | 986 void GenerateMiss(MacroAssembler* masm); |
991 void HandleArrayCase(MacroAssembler* masm, Label* miss); | 987 void HandleArrayCase(MacroAssembler* masm, Label* miss); |
992 | 988 |
993 private: | 989 private: |
(...skipping 1976 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2970 #undef DEFINE_HYDROGEN_CODE_STUB | 2966 #undef DEFINE_HYDROGEN_CODE_STUB |
2971 #undef DEFINE_CODE_STUB | 2967 #undef DEFINE_CODE_STUB |
2972 #undef DEFINE_CODE_STUB_BASE | 2968 #undef DEFINE_CODE_STUB_BASE |
2973 | 2969 |
2974 extern Representation RepresentationFromType(Type* type); | 2970 extern Representation RepresentationFromType(Type* type); |
2975 | 2971 |
2976 } // namespace internal | 2972 } // namespace internal |
2977 } // namespace v8 | 2973 } // namespace v8 |
2978 | 2974 |
2979 #endif // V8_CODE_STUBS_H_ | 2975 #endif // V8_CODE_STUBS_H_ |
OLD | NEW |