Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(153)

Side by Side Diff: src/code-stubs.h

Issue 688533002: Add a few missing overrides found by a new clang warning. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 static void InitializeDescriptor(Isolate* isolate, uint32_t key, 193 static void InitializeDescriptor(Isolate* isolate, uint32_t key,
194 CodeStubDescriptor* desc); 194 CodeStubDescriptor* desc);
195 195
196 static MaybeHandle<Code> GetCode(Isolate* isolate, uint32_t key); 196 static MaybeHandle<Code> GetCode(Isolate* isolate, uint32_t key);
197 197
198 // Returns information for computing the number key. 198 // Returns information for computing the number key.
199 virtual Major MajorKey() const = 0; 199 virtual Major MajorKey() const = 0;
200 uint32_t MinorKey() const { return minor_key_; } 200 uint32_t MinorKey() const { return minor_key_; }
201 201
202 virtual InlineCacheState GetICState() const { return UNINITIALIZED; } 202 virtual InlineCacheState GetICState() const { return UNINITIALIZED; }
203 virtual ExtraICState GetExtraICState() const { return kNoExtraICState; } 203 virtual ExtraICState GetExtraICState() const {
204 return kNoExtraICState;
205 }
204 virtual Code::StubType GetStubType() { 206 virtual Code::StubType GetStubType() {
205 return Code::NORMAL; 207 return Code::NORMAL;
206 } 208 }
207 209
208 friend std::ostream& operator<<(std::ostream& os, const CodeStub& s) { 210 friend std::ostream& operator<<(std::ostream& os, const CodeStub& s) {
209 s.PrintName(os); 211 s.PrintName(os);
210 return os; 212 return os;
211 } 213 }
212 214
213 Isolate* isolate() const { return isolate_; } 215 Isolate* isolate() const { return isolate_; }
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
330 UNREACHABLE(); \ 332 UNREACHABLE(); \
331 return CallInterfaceDescriptor(); \ 333 return CallInterfaceDescriptor(); \
332 } 334 }
333 335
334 336
335 class PlatformCodeStub : public CodeStub { 337 class PlatformCodeStub : public CodeStub {
336 public: 338 public:
337 // Retrieve the code for the stub. Generate the code if needed. 339 // Retrieve the code for the stub. Generate the code if needed.
338 virtual Handle<Code> GenerateCode() OVERRIDE; 340 virtual Handle<Code> GenerateCode() OVERRIDE;
339 341
340 virtual Code::Kind GetCodeKind() const { return Code::STUB; } 342 virtual Code::Kind GetCodeKind() const OVERRIDE { return Code::STUB; }
341 343
342 protected: 344 protected:
343 explicit PlatformCodeStub(Isolate* isolate) : CodeStub(isolate) {} 345 explicit PlatformCodeStub(Isolate* isolate) : CodeStub(isolate) {}
344 346
345 // Generates the assembler code for the stub. 347 // Generates the assembler code for the stub.
346 virtual void Generate(MacroAssembler* masm) = 0; 348 virtual void Generate(MacroAssembler* masm) = 0;
347 349
348 DEFINE_CODE_STUB_BASE(PlatformCodeStub, CodeStub); 350 DEFINE_CODE_STUB_BASE(PlatformCodeStub, CodeStub);
349 }; 351 };
350 352
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
430 }; 432 };
431 433
432 434
433 class HydrogenCodeStub : public CodeStub { 435 class HydrogenCodeStub : public CodeStub {
434 public: 436 public:
435 enum InitializationState { 437 enum InitializationState {
436 UNINITIALIZED, 438 UNINITIALIZED,
437 INITIALIZED 439 INITIALIZED
438 }; 440 };
439 441
440 virtual Code::Kind GetCodeKind() const { return Code::STUB; } 442 virtual Code::Kind GetCodeKind() const OVERRIDE { return Code::STUB; }
441 443
442 template<class SubClass> 444 template<class SubClass>
443 static Handle<Code> GetUninitialized(Isolate* isolate) { 445 static Handle<Code> GetUninitialized(Isolate* isolate) {
444 SubClass::GenerateAheadOfTime(isolate); 446 SubClass::GenerateAheadOfTime(isolate);
445 return SubClass().GetCode(isolate); 447 return SubClass().GetCode(isolate);
446 } 448 }
447 449
448 // Retrieve the code for the stub. Generate the code if needed. 450 // Retrieve the code for the stub. Generate the code if needed.
449 virtual Handle<Code> GenerateCode() = 0; 451 virtual Handle<Code> GenerateCode() = 0;
450 452
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
846 DEFINE_PLATFORM_CODE_STUB(CallIC_Array, CallICStub); 848 DEFINE_PLATFORM_CODE_STUB(CallIC_Array, CallICStub);
847 }; 849 };
848 850
849 851
850 // TODO(verwaest): Translate to hydrogen code stub. 852 // TODO(verwaest): Translate to hydrogen code stub.
851 class FunctionPrototypeStub : public PlatformCodeStub { 853 class FunctionPrototypeStub : public PlatformCodeStub {
852 public: 854 public:
853 explicit FunctionPrototypeStub(Isolate* isolate) 855 explicit FunctionPrototypeStub(Isolate* isolate)
854 : PlatformCodeStub(isolate) {} 856 : PlatformCodeStub(isolate) {}
855 857
856 virtual Code::Kind GetCodeKind() const { return Code::HANDLER; } 858 virtual Code::Kind GetCodeKind() const OVERRIDE { return Code::HANDLER; }
857 859
858 // TODO(mvstanton): only the receiver register is accessed. When this is 860 // TODO(mvstanton): only the receiver register is accessed. When this is
859 // translated to a hydrogen code stub, a new CallInterfaceDescriptor 861 // translated to a hydrogen code stub, a new CallInterfaceDescriptor
860 // should be created that just uses that register for more efficient code. 862 // should be created that just uses that register for more efficient code.
861 virtual CallInterfaceDescriptor GetCallInterfaceDescriptor() OVERRIDE { 863 virtual CallInterfaceDescriptor GetCallInterfaceDescriptor() OVERRIDE {
862 if (FLAG_vector_ics) { 864 if (FLAG_vector_ics) {
863 return VectorLoadICDescriptor(isolate()); 865 return VectorLoadICDescriptor(isolate());
864 } 866 }
865 return LoadDescriptor(isolate()); 867 return LoadDescriptor(isolate());
866 } 868 }
867 869
868 DEFINE_PLATFORM_CODE_STUB(FunctionPrototype, PlatformCodeStub); 870 DEFINE_PLATFORM_CODE_STUB(FunctionPrototype, PlatformCodeStub);
869 }; 871 };
870 872
871 873
872 // TODO(mvstanton): Translate to hydrogen code stub. 874 // TODO(mvstanton): Translate to hydrogen code stub.
873 class LoadIndexedInterceptorStub : public PlatformCodeStub { 875 class LoadIndexedInterceptorStub : public PlatformCodeStub {
874 public: 876 public:
875 explicit LoadIndexedInterceptorStub(Isolate* isolate) 877 explicit LoadIndexedInterceptorStub(Isolate* isolate)
876 : PlatformCodeStub(isolate) {} 878 : PlatformCodeStub(isolate) {}
877 879
878 virtual Code::Kind GetCodeKind() const { return Code::HANDLER; } 880 virtual Code::Kind GetCodeKind() const OVERRIDE { return Code::HANDLER; }
879 virtual Code::StubType GetStubType() { return Code::FAST; } 881 virtual Code::StubType GetStubType() OVERRIDE { return Code::FAST; }
880 882
881 DEFINE_CALL_INTERFACE_DESCRIPTOR(Load); 883 DEFINE_CALL_INTERFACE_DESCRIPTOR(Load);
882 DEFINE_PLATFORM_CODE_STUB(LoadIndexedInterceptor, PlatformCodeStub); 884 DEFINE_PLATFORM_CODE_STUB(LoadIndexedInterceptor, PlatformCodeStub);
883 }; 885 };
884 886
885 887
886 class LoadIndexedStringStub : public PlatformCodeStub { 888 class LoadIndexedStringStub : public PlatformCodeStub {
887 public: 889 public:
888 explicit LoadIndexedStringStub(Isolate* isolate) 890 explicit LoadIndexedStringStub(Isolate* isolate)
889 : PlatformCodeStub(isolate) {} 891 : PlatformCodeStub(isolate) {}
890 892
891 virtual Code::Kind GetCodeKind() const { return Code::HANDLER; } 893 virtual Code::Kind GetCodeKind() const OVERRIDE { return Code::HANDLER; }
892 virtual Code::StubType GetStubType() { return Code::FAST; } 894 virtual Code::StubType GetStubType() OVERRIDE { return Code::FAST; }
893 895
894 DEFINE_CALL_INTERFACE_DESCRIPTOR(Load); 896 DEFINE_CALL_INTERFACE_DESCRIPTOR(Load);
895 DEFINE_PLATFORM_CODE_STUB(LoadIndexedString, PlatformCodeStub); 897 DEFINE_PLATFORM_CODE_STUB(LoadIndexedString, PlatformCodeStub);
896 }; 898 };
897 899
898 900
899 class HandlerStub : public HydrogenCodeStub { 901 class HandlerStub : public HydrogenCodeStub {
900 public: 902 public:
901 virtual Code::Kind GetCodeKind() const { return Code::HANDLER; } 903 virtual Code::Kind GetCodeKind() const OVERRIDE { return Code::HANDLER; }
902 virtual ExtraICState GetExtraICState() const { return kind(); } 904 virtual ExtraICState GetExtraICState() const OVERRIDE { return kind(); }
903 virtual InlineCacheState GetICState() const { return MONOMORPHIC; } 905 virtual InlineCacheState GetICState() const OVERRIDE { return MONOMORPHIC; }
904 906
905 virtual void InitializeDescriptor(CodeStubDescriptor* descriptor) OVERRIDE; 907 virtual void InitializeDescriptor(CodeStubDescriptor* descriptor) OVERRIDE;
906 908
907 virtual CallInterfaceDescriptor GetCallInterfaceDescriptor() OVERRIDE; 909 virtual CallInterfaceDescriptor GetCallInterfaceDescriptor() OVERRIDE;
908 910
909 protected: 911 protected:
910 explicit HandlerStub(Isolate* isolate) : HydrogenCodeStub(isolate) {} 912 explicit HandlerStub(Isolate* isolate) : HydrogenCodeStub(isolate) {}
911 913
912 virtual Code::Kind kind() const = 0; 914 virtual Code::Kind kind() const = 0;
913 915
914 DEFINE_CODE_STUB_BASE(HandlerStub, HydrogenCodeStub); 916 DEFINE_CODE_STUB_BASE(HandlerStub, HydrogenCodeStub);
915 }; 917 };
916 918
917 919
918 class LoadFieldStub: public HandlerStub { 920 class LoadFieldStub: public HandlerStub {
919 public: 921 public:
920 LoadFieldStub(Isolate* isolate, FieldIndex index) : HandlerStub(isolate) { 922 LoadFieldStub(Isolate* isolate, FieldIndex index) : HandlerStub(isolate) {
921 int property_index_key = index.GetFieldAccessStubKey(); 923 int property_index_key = index.GetFieldAccessStubKey();
922 set_sub_minor_key(LoadFieldByIndexBits::encode(property_index_key)); 924 set_sub_minor_key(LoadFieldByIndexBits::encode(property_index_key));
923 } 925 }
924 926
925 FieldIndex index() const { 927 FieldIndex index() const {
926 int property_index_key = LoadFieldByIndexBits::decode(sub_minor_key()); 928 int property_index_key = LoadFieldByIndexBits::decode(sub_minor_key());
927 return FieldIndex::FromFieldAccessStubKey(property_index_key); 929 return FieldIndex::FromFieldAccessStubKey(property_index_key);
928 } 930 }
929 931
930 protected: 932 protected:
931 virtual Code::Kind kind() const { return Code::LOAD_IC; } 933 virtual Code::Kind kind() const { return Code::LOAD_IC; }
932 virtual Code::StubType GetStubType() { return Code::FAST; } 934 virtual Code::StubType GetStubType() OVERRIDE { return Code::FAST; }
933 935
934 private: 936 private:
935 class LoadFieldByIndexBits : public BitField<int, 0, 13> {}; 937 class LoadFieldByIndexBits : public BitField<int, 0, 13> {};
936 938
937 DEFINE_HANDLER_CODE_STUB(LoadField, HandlerStub); 939 DEFINE_HANDLER_CODE_STUB(LoadField, HandlerStub);
938 }; 940 };
939 941
940 942
941 class KeyedLoadSloppyArgumentsStub : public HandlerStub { 943 class KeyedLoadSloppyArgumentsStub : public HandlerStub {
942 public: 944 public:
943 explicit KeyedLoadSloppyArgumentsStub(Isolate* isolate) 945 explicit KeyedLoadSloppyArgumentsStub(Isolate* isolate)
944 : HandlerStub(isolate) {} 946 : HandlerStub(isolate) {}
945 947
946 protected: 948 protected:
947 virtual Code::Kind kind() const { return Code::KEYED_LOAD_IC; } 949 virtual Code::Kind kind() const OVERRIDE { return Code::KEYED_LOAD_IC; }
948 virtual Code::StubType GetStubType() { return Code::FAST; } 950 virtual Code::StubType GetStubType() OVERRIDE { return Code::FAST; }
949 951
950 private: 952 private:
951 DEFINE_HANDLER_CODE_STUB(KeyedLoadSloppyArguments, HandlerStub); 953 DEFINE_HANDLER_CODE_STUB(KeyedLoadSloppyArguments, HandlerStub);
952 }; 954 };
953 955
954 956
955 class LoadConstantStub : public HandlerStub { 957 class LoadConstantStub : public HandlerStub {
956 public: 958 public:
957 LoadConstantStub(Isolate* isolate, int constant_index) 959 LoadConstantStub(Isolate* isolate, int constant_index)
958 : HandlerStub(isolate) { 960 : HandlerStub(isolate) {
959 set_sub_minor_key(ConstantIndexBits::encode(constant_index)); 961 set_sub_minor_key(ConstantIndexBits::encode(constant_index));
960 } 962 }
961 963
962 int constant_index() const { 964 int constant_index() const {
963 return ConstantIndexBits::decode(sub_minor_key()); 965 return ConstantIndexBits::decode(sub_minor_key());
964 } 966 }
965 967
966 protected: 968 protected:
967 virtual Code::Kind kind() const { return Code::LOAD_IC; } 969 virtual Code::Kind kind() const OVERRIDE { return Code::LOAD_IC; }
968 virtual Code::StubType GetStubType() { return Code::FAST; } 970 virtual Code::StubType GetStubType() OVERRIDE { return Code::FAST; }
969 971
970 private: 972 private:
971 class ConstantIndexBits : public BitField<int, 0, kSubMinorKeyBits> {}; 973 class ConstantIndexBits : public BitField<int, 0, kSubMinorKeyBits> {};
972 974
973 DEFINE_HANDLER_CODE_STUB(LoadConstant, HandlerStub); 975 DEFINE_HANDLER_CODE_STUB(LoadConstant, HandlerStub);
974 }; 976 };
975 977
976 978
977 class StringLengthStub: public HandlerStub { 979 class StringLengthStub: public HandlerStub {
978 public: 980 public:
979 explicit StringLengthStub(Isolate* isolate) : HandlerStub(isolate) {} 981 explicit StringLengthStub(Isolate* isolate) : HandlerStub(isolate) {}
980 982
981 protected: 983 protected:
982 virtual Code::Kind kind() const { return Code::LOAD_IC; } 984 virtual Code::Kind kind() const OVERRIDE { return Code::LOAD_IC; }
983 virtual Code::StubType GetStubType() { return Code::FAST; } 985 virtual Code::StubType GetStubType() OVERRIDE { return Code::FAST; }
984 986
985 DEFINE_HANDLER_CODE_STUB(StringLength, HandlerStub); 987 DEFINE_HANDLER_CODE_STUB(StringLength, HandlerStub);
986 }; 988 };
987 989
988 990
989 class StoreFieldStub : public HandlerStub { 991 class StoreFieldStub : public HandlerStub {
990 public: 992 public:
991 StoreFieldStub(Isolate* isolate, FieldIndex index, 993 StoreFieldStub(Isolate* isolate, FieldIndex index,
992 Representation representation) 994 Representation representation)
993 : HandlerStub(isolate) { 995 : HandlerStub(isolate) {
994 int property_index_key = index.GetFieldAccessStubKey(); 996 int property_index_key = index.GetFieldAccessStubKey();
995 uint8_t repr = PropertyDetails::EncodeRepresentation(representation); 997 uint8_t repr = PropertyDetails::EncodeRepresentation(representation);
996 set_sub_minor_key(StoreFieldByIndexBits::encode(property_index_key) | 998 set_sub_minor_key(StoreFieldByIndexBits::encode(property_index_key) |
997 RepresentationBits::encode(repr)); 999 RepresentationBits::encode(repr));
998 } 1000 }
999 1001
1000 FieldIndex index() const { 1002 FieldIndex index() const {
1001 int property_index_key = StoreFieldByIndexBits::decode(sub_minor_key()); 1003 int property_index_key = StoreFieldByIndexBits::decode(sub_minor_key());
1002 return FieldIndex::FromFieldAccessStubKey(property_index_key); 1004 return FieldIndex::FromFieldAccessStubKey(property_index_key);
1003 } 1005 }
1004 1006
1005 Representation representation() { 1007 Representation representation() {
1006 uint8_t repr = RepresentationBits::decode(sub_minor_key()); 1008 uint8_t repr = RepresentationBits::decode(sub_minor_key());
1007 return PropertyDetails::DecodeRepresentation(repr); 1009 return PropertyDetails::DecodeRepresentation(repr);
1008 } 1010 }
1009 1011
1010 protected: 1012 protected:
1011 virtual Code::Kind kind() const { return Code::STORE_IC; } 1013 virtual Code::Kind kind() const OVERRIDE { return Code::STORE_IC; }
1012 virtual Code::StubType GetStubType() { return Code::FAST; } 1014 virtual Code::StubType GetStubType() OVERRIDE { return Code::FAST; }
1013 1015
1014 private: 1016 private:
1015 class StoreFieldByIndexBits : public BitField<int, 0, 13> {}; 1017 class StoreFieldByIndexBits : public BitField<int, 0, 13> {};
1016 class RepresentationBits : public BitField<uint8_t, 13, 4> {}; 1018 class RepresentationBits : public BitField<uint8_t, 13, 4> {};
1017 1019
1018 DEFINE_HANDLER_CODE_STUB(StoreField, HandlerStub); 1020 DEFINE_HANDLER_CODE_STUB(StoreField, HandlerStub);
1019 }; 1021 };
1020 1022
1021 1023
1022 class StoreTransitionStub : public HandlerStub { 1024 class StoreTransitionStub : public HandlerStub {
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
1054 return PropertyDetails::DecodeRepresentation(repr); 1056 return PropertyDetails::DecodeRepresentation(repr);
1055 } 1057 }
1056 1058
1057 StoreMode store_mode() const { 1059 StoreMode store_mode() const {
1058 return StoreModeBits::decode(sub_minor_key()); 1060 return StoreModeBits::decode(sub_minor_key());
1059 } 1061 }
1060 1062
1061 virtual CallInterfaceDescriptor GetCallInterfaceDescriptor() OVERRIDE; 1063 virtual CallInterfaceDescriptor GetCallInterfaceDescriptor() OVERRIDE;
1062 1064
1063 protected: 1065 protected:
1064 virtual Code::Kind kind() const { return Code::STORE_IC; } 1066 virtual Code::Kind kind() const OVERRIDE { return Code::STORE_IC; }
1065 virtual Code::StubType GetStubType() { return Code::FAST; } 1067 virtual Code::StubType GetStubType() OVERRIDE { return Code::FAST; }
1066 1068
1067 private: 1069 private:
1068 class StoreFieldByIndexBits : public BitField<int, 0, 13> {}; 1070 class StoreFieldByIndexBits : public BitField<int, 0, 13> {};
1069 class RepresentationBits : public BitField<uint8_t, 13, 4> {}; 1071 class RepresentationBits : public BitField<uint8_t, 13, 4> {};
1070 class StoreModeBits : public BitField<StoreMode, 17, 2> {}; 1072 class StoreModeBits : public BitField<StoreMode, 17, 2> {};
1071 1073
1072 DEFINE_HANDLER_CODE_STUB(StoreTransition, HandlerStub); 1074 DEFINE_HANDLER_CODE_STUB(StoreTransition, HandlerStub);
1073 }; 1075 };
1074 1076
1075 1077
(...skipping 17 matching lines...) Expand all
1093 pattern.Add(isolate()->factory()->meta_map(), Handle<Map>(global->map())); 1095 pattern.Add(isolate()->factory()->meta_map(), Handle<Map>(global->map()));
1094 pattern.Add(isolate()->factory()->global_property_cell_map(), cell); 1096 pattern.Add(isolate()->factory()->global_property_cell_map(), cell);
1095 return CodeStub::GetCodeCopy(pattern); 1097 return CodeStub::GetCodeCopy(pattern);
1096 } else { 1098 } else {
1097 Code::FindAndReplacePattern pattern; 1099 Code::FindAndReplacePattern pattern;
1098 pattern.Add(isolate()->factory()->global_property_cell_map(), cell); 1100 pattern.Add(isolate()->factory()->global_property_cell_map(), cell);
1099 return CodeStub::GetCodeCopy(pattern); 1101 return CodeStub::GetCodeCopy(pattern);
1100 } 1102 }
1101 } 1103 }
1102 1104
1103 virtual Code::Kind kind() const { return Code::STORE_IC; } 1105 virtual Code::Kind kind() const OVERRIDE { return Code::STORE_IC; }
1104 1106
1105 bool is_constant() const { return IsConstantBits::decode(sub_minor_key()); } 1107 bool is_constant() const { return IsConstantBits::decode(sub_minor_key()); }
1106 1108
1107 bool check_global() const { return CheckGlobalBits::decode(sub_minor_key()); } 1109 bool check_global() const { return CheckGlobalBits::decode(sub_minor_key()); }
1108 1110
1109 void set_is_constant(bool value) { 1111 void set_is_constant(bool value) {
1110 set_sub_minor_key(IsConstantBits::update(sub_minor_key(), value)); 1112 set_sub_minor_key(IsConstantBits::update(sub_minor_key(), value));
1111 } 1113 }
1112 1114
1113 Representation representation() { 1115 Representation representation() {
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
1331 CompareICStub(Isolate* isolate, Token::Value op, CompareICState::State left, 1333 CompareICStub(Isolate* isolate, Token::Value op, CompareICState::State left,
1332 CompareICState::State right, CompareICState::State state) 1334 CompareICState::State right, CompareICState::State state)
1333 : PlatformCodeStub(isolate) { 1335 : PlatformCodeStub(isolate) {
1334 DCHECK(Token::IsCompareOp(op)); 1336 DCHECK(Token::IsCompareOp(op));
1335 minor_key_ = OpBits::encode(op - Token::EQ) | LeftStateBits::encode(left) | 1337 minor_key_ = OpBits::encode(op - Token::EQ) | LeftStateBits::encode(left) |
1336 RightStateBits::encode(right) | StateBits::encode(state); 1338 RightStateBits::encode(right) | StateBits::encode(state);
1337 } 1339 }
1338 1340
1339 void set_known_map(Handle<Map> map) { known_map_ = map; } 1341 void set_known_map(Handle<Map> map) { known_map_ = map; }
1340 1342
1341 virtual InlineCacheState GetICState() const; 1343 virtual InlineCacheState GetICState() const OVERRIDE;
1342 1344
1343 Token::Value op() const { 1345 Token::Value op() const {
1344 return static_cast<Token::Value>(Token::EQ + OpBits::decode(minor_key_)); 1346 return static_cast<Token::Value>(Token::EQ + OpBits::decode(minor_key_));
1345 } 1347 }
1346 1348
1347 CompareICState::State left() const { 1349 CompareICState::State left() const {
1348 return LeftStateBits::decode(minor_key_); 1350 return LeftStateBits::decode(minor_key_);
1349 } 1351 }
1350 CompareICState::State right() const { 1352 CompareICState::State right() const {
1351 return RightStateBits::decode(minor_key_); 1353 return RightStateBits::decode(minor_key_);
1352 } 1354 }
1353 CompareICState::State state() const { return StateBits::decode(minor_key_); } 1355 CompareICState::State state() const { return StateBits::decode(minor_key_); }
1354 1356
1355 private: 1357 private:
1356 virtual Code::Kind GetCodeKind() const { return Code::COMPARE_IC; } 1358 virtual Code::Kind GetCodeKind() const OVERRIDE { return Code::COMPARE_IC; }
1357 1359
1358 void GenerateSmis(MacroAssembler* masm); 1360 void GenerateSmis(MacroAssembler* masm);
1359 void GenerateNumbers(MacroAssembler* masm); 1361 void GenerateNumbers(MacroAssembler* masm);
1360 void GenerateInternalizedStrings(MacroAssembler* masm); 1362 void GenerateInternalizedStrings(MacroAssembler* masm);
1361 void GenerateStrings(MacroAssembler* masm); 1363 void GenerateStrings(MacroAssembler* masm);
1362 void GenerateUniqueNames(MacroAssembler* masm); 1364 void GenerateUniqueNames(MacroAssembler* masm);
1363 void GenerateObjects(MacroAssembler* masm); 1365 void GenerateObjects(MacroAssembler* masm);
1364 void GenerateMiss(MacroAssembler* masm); 1366 void GenerateMiss(MacroAssembler* masm);
1365 void GenerateKnownObjects(MacroAssembler* masm); 1367 void GenerateKnownObjects(MacroAssembler* masm);
1366 void GenerateGeneric(MacroAssembler* masm); 1368 void GenerateGeneric(MacroAssembler* masm);
1367 1369
1368 bool strict() const { return op() == Token::EQ_STRICT; } 1370 bool strict() const { return op() == Token::EQ_STRICT; }
1369 Condition GetCondition() const; 1371 Condition GetCondition() const;
1370 1372
1371 virtual void AddToSpecialCache(Handle<Code> new_object); 1373 virtual void AddToSpecialCache(Handle<Code> new_object) OVERRIDE;
1372 virtual bool FindCodeInSpecialCache(Code** code_out); 1374 virtual bool FindCodeInSpecialCache(Code** code_out) OVERRIDE;
1373 virtual bool UseSpecialCache() { 1375 virtual bool UseSpecialCache() OVERRIDE {
1374 return state() == CompareICState::KNOWN_OBJECT; 1376 return state() == CompareICState::KNOWN_OBJECT;
1375 } 1377 }
1376 1378
1377 class OpBits : public BitField<int, 0, 3> {}; 1379 class OpBits : public BitField<int, 0, 3> {};
1378 class LeftStateBits : public BitField<CompareICState::State, 3, 4> {}; 1380 class LeftStateBits : public BitField<CompareICState::State, 3, 4> {};
1379 class RightStateBits : public BitField<CompareICState::State, 7, 4> {}; 1381 class RightStateBits : public BitField<CompareICState::State, 7, 4> {};
1380 class StateBits : public BitField<CompareICState::State, 11, 4> {}; 1382 class StateBits : public BitField<CompareICState::State, 11, 4> {};
1381 1383
1382 Handle<Map> known_map_; 1384 Handle<Map> known_map_;
1383 1385
(...skipping 15 matching lines...) Expand all
1399 InitializationState init_state = INITIALIZED) 1401 InitializationState init_state = INITIALIZED)
1400 : HydrogenCodeStub(isolate, init_state) { 1402 : HydrogenCodeStub(isolate, init_state) {
1401 set_sub_minor_key(ic_state); 1403 set_sub_minor_key(ic_state);
1402 } 1404 }
1403 1405
1404 static Handle<Code> GetUninitialized(Isolate* isolate, 1406 static Handle<Code> GetUninitialized(Isolate* isolate,
1405 NilValue nil) { 1407 NilValue nil) {
1406 return CompareNilICStub(isolate, nil, UNINITIALIZED).GetCode(); 1408 return CompareNilICStub(isolate, nil, UNINITIALIZED).GetCode();
1407 } 1409 }
1408 1410
1409 virtual InlineCacheState GetICState() const { 1411 virtual InlineCacheState GetICState() const OVERRIDE {
1410 State state = this->state(); 1412 State state = this->state();
1411 if (state.Contains(GENERIC)) { 1413 if (state.Contains(GENERIC)) {
1412 return MEGAMORPHIC; 1414 return MEGAMORPHIC;
1413 } else if (state.Contains(MONOMORPHIC_MAP)) { 1415 } else if (state.Contains(MONOMORPHIC_MAP)) {
1414 return MONOMORPHIC; 1416 return MONOMORPHIC;
1415 } else { 1417 } else {
1416 return PREMONOMORPHIC; 1418 return PREMONOMORPHIC;
1417 } 1419 }
1418 } 1420 }
1419 1421
1420 virtual Code::Kind GetCodeKind() const { return Code::COMPARE_NIL_IC; } 1422 virtual Code::Kind GetCodeKind() const OVERRIDE {
1423 return Code::COMPARE_NIL_IC;
1424 }
1421 1425
1422 virtual ExtraICState GetExtraICState() const { return sub_minor_key(); } 1426 virtual ExtraICState GetExtraICState() const OVERRIDE {
1427 return sub_minor_key();
1428 }
1423 1429
1424 void UpdateStatus(Handle<Object> object); 1430 void UpdateStatus(Handle<Object> object);
1425 1431
1426 bool IsMonomorphic() const { return state().Contains(MONOMORPHIC_MAP); } 1432 bool IsMonomorphic() const { return state().Contains(MONOMORPHIC_MAP); }
1427 1433
1428 NilValue nil_value() const { return NilValueBits::decode(sub_minor_key()); } 1434 NilValue nil_value() const { return NilValueBits::decode(sub_minor_key()); }
1429 1435
1430 void ClearState() { 1436 void ClearState() {
1431 set_sub_minor_key(TypesBits::update(sub_minor_key(), 0)); 1437 set_sub_minor_key(TypesBits::update(sub_minor_key(), 0));
1432 } 1438 }
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
1493 // their code generation. On machines that always have gp registers (x64) we 1499 // their code generation. On machines that always have gp registers (x64) we
1494 // can generate both variants ahead of time. 1500 // can generate both variants ahead of time.
1495 static void GenerateAheadOfTime(Isolate* isolate); 1501 static void GenerateAheadOfTime(Isolate* isolate);
1496 1502
1497 private: 1503 private:
1498 bool save_doubles() const { return SaveDoublesBits::decode(minor_key_); } 1504 bool save_doubles() const { return SaveDoublesBits::decode(minor_key_); }
1499 #ifdef _WIN64 1505 #ifdef _WIN64
1500 int result_size() const { return ResultSizeBits::decode(minor_key_); } 1506 int result_size() const { return ResultSizeBits::decode(minor_key_); }
1501 #endif // _WIN64 1507 #endif // _WIN64
1502 1508
1503 bool NeedsImmovableCode(); 1509 bool NeedsImmovableCode() OVERRIDE;
1504 1510
1505 class SaveDoublesBits : public BitField<bool, 0, 1> {}; 1511 class SaveDoublesBits : public BitField<bool, 0, 1> {};
1506 class ResultSizeBits : public BitField<int, 1, 3> {}; 1512 class ResultSizeBits : public BitField<int, 1, 3> {};
1507 1513
1508 DEFINE_NULL_CALL_INTERFACE_DESCRIPTOR(); 1514 DEFINE_NULL_CALL_INTERFACE_DESCRIPTOR();
1509 DEFINE_PLATFORM_CODE_STUB(CEntry, PlatformCodeStub); 1515 DEFINE_PLATFORM_CODE_STUB(CEntry, PlatformCodeStub);
1510 }; 1516 };
1511 1517
1512 1518
1513 class JSEntryStub : public PlatformCodeStub { 1519 class JSEntryStub : public PlatformCodeStub {
1514 public: 1520 public:
1515 JSEntryStub(Isolate* isolate, StackFrame::Type type) 1521 JSEntryStub(Isolate* isolate, StackFrame::Type type)
1516 : PlatformCodeStub(isolate) { 1522 : PlatformCodeStub(isolate) {
1517 DCHECK(type == StackFrame::ENTRY || type == StackFrame::ENTRY_CONSTRUCT); 1523 DCHECK(type == StackFrame::ENTRY || type == StackFrame::ENTRY_CONSTRUCT);
1518 minor_key_ = StackFrameTypeBits::encode(type); 1524 minor_key_ = StackFrameTypeBits::encode(type);
1519 } 1525 }
1520 1526
1521 private: 1527 private:
1522 virtual void FinishCode(Handle<Code> code); 1528 virtual void FinishCode(Handle<Code> code) OVERRIDE;
1523 1529
1524 virtual void PrintName(std::ostream& os) const OVERRIDE { // NOLINT 1530 virtual void PrintName(std::ostream& os) const OVERRIDE { // NOLINT
1525 os << (type() == StackFrame::ENTRY ? "JSEntryStub" 1531 os << (type() == StackFrame::ENTRY ? "JSEntryStub"
1526 : "JSConstructEntryStub"); 1532 : "JSConstructEntryStub");
1527 } 1533 }
1528 1534
1529 StackFrame::Type type() const { 1535 StackFrame::Type type() const {
1530 return StackFrameTypeBits::decode(minor_key_); 1536 return StackFrameTypeBits::decode(minor_key_);
1531 } 1537 }
1532 1538
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
1633 }; 1639 };
1634 1640
1635 1641
1636 class CallConstructStub: public PlatformCodeStub { 1642 class CallConstructStub: public PlatformCodeStub {
1637 public: 1643 public:
1638 CallConstructStub(Isolate* isolate, CallConstructorFlags flags) 1644 CallConstructStub(Isolate* isolate, CallConstructorFlags flags)
1639 : PlatformCodeStub(isolate) { 1645 : PlatformCodeStub(isolate) {
1640 minor_key_ = FlagBits::encode(flags); 1646 minor_key_ = FlagBits::encode(flags);
1641 } 1647 }
1642 1648
1643 virtual void FinishCode(Handle<Code> code) { 1649 virtual void FinishCode(Handle<Code> code) OVERRIDE {
1644 code->set_has_function_cache(RecordCallTarget()); 1650 code->set_has_function_cache(RecordCallTarget());
1645 } 1651 }
1646 1652
1647 private: 1653 private:
1648 CallConstructorFlags flags() const { return FlagBits::decode(minor_key_); } 1654 CallConstructorFlags flags() const { return FlagBits::decode(minor_key_); }
1649 1655
1650 bool RecordCallTarget() const { 1656 bool RecordCallTarget() const {
1651 return (flags() & RECORD_CONSTRUCTOR_TARGET) != 0; 1657 return (flags() & RECORD_CONSTRUCTOR_TARGET) != 0;
1652 } 1658 }
1653 1659
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
1849 } 1855 }
1850 1856
1851 DEFINE_HYDROGEN_CODE_STUB(LoadDictionaryElement, HydrogenCodeStub); 1857 DEFINE_HYDROGEN_CODE_STUB(LoadDictionaryElement, HydrogenCodeStub);
1852 }; 1858 };
1853 1859
1854 1860
1855 class KeyedLoadGenericStub : public HydrogenCodeStub { 1861 class KeyedLoadGenericStub : public HydrogenCodeStub {
1856 public: 1862 public:
1857 explicit KeyedLoadGenericStub(Isolate* isolate) : HydrogenCodeStub(isolate) {} 1863 explicit KeyedLoadGenericStub(Isolate* isolate) : HydrogenCodeStub(isolate) {}
1858 1864
1859 virtual Code::Kind GetCodeKind() const { return Code::KEYED_LOAD_IC; } 1865 virtual Code::Kind GetCodeKind() const OVERRIDE {
1860 virtual InlineCacheState GetICState() const { return GENERIC; } 1866 return Code::KEYED_LOAD_IC;
1867 }
1868 virtual InlineCacheState GetICState() const OVERRIDE { return GENERIC; }
1861 1869
1862 // Since KeyedLoadGeneric stub doesn't miss (simply calls runtime), it 1870 // Since KeyedLoadGeneric stub doesn't miss (simply calls runtime), it
1863 // doesn't need to use the VectorLoadICDescriptor for the case when 1871 // doesn't need to use the VectorLoadICDescriptor for the case when
1864 // flag --vector-ics is true. 1872 // flag --vector-ics is true.
1865 DEFINE_CALL_INTERFACE_DESCRIPTOR(Load); 1873 DEFINE_CALL_INTERFACE_DESCRIPTOR(Load);
1866 1874
1867 DEFINE_HYDROGEN_CODE_STUB(KeyedLoadGeneric, HydrogenCodeStub); 1875 DEFINE_HYDROGEN_CODE_STUB(KeyedLoadGeneric, HydrogenCodeStub);
1868 }; 1876 };
1869 1877
1870 1878
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
1977 int offset, bool is_truncating, bool skip_fastpath = false) 1985 int offset, bool is_truncating, bool skip_fastpath = false)
1978 : PlatformCodeStub(isolate) { 1986 : PlatformCodeStub(isolate) {
1979 minor_key_ = SourceRegisterBits::encode(source.code()) | 1987 minor_key_ = SourceRegisterBits::encode(source.code()) |
1980 DestinationRegisterBits::encode(destination.code()) | 1988 DestinationRegisterBits::encode(destination.code()) |
1981 OffsetBits::encode(offset) | 1989 OffsetBits::encode(offset) |
1982 IsTruncatingBits::encode(is_truncating) | 1990 IsTruncatingBits::encode(is_truncating) |
1983 SkipFastPathBits::encode(skip_fastpath) | 1991 SkipFastPathBits::encode(skip_fastpath) |
1984 SSE3Bits::encode(CpuFeatures::IsSupported(SSE3) ? 1 : 0); 1992 SSE3Bits::encode(CpuFeatures::IsSupported(SSE3) ? 1 : 0);
1985 } 1993 }
1986 1994
1987 virtual bool SometimesSetsUpAFrame() { return false; } 1995 virtual bool SometimesSetsUpAFrame() OVERRIDE { return false; }
1988 1996
1989 private: 1997 private:
1990 Register source() const { 1998 Register source() const {
1991 return Register::from_code(SourceRegisterBits::decode(minor_key_)); 1999 return Register::from_code(SourceRegisterBits::decode(minor_key_));
1992 } 2000 }
1993 Register destination() const { 2001 Register destination() const {
1994 return Register::from_code(DestinationRegisterBits::decode(minor_key_)); 2002 return Register::from_code(DestinationRegisterBits::decode(minor_key_));
1995 } 2003 }
1996 bool is_truncating() const { return IsTruncatingBits::decode(minor_key_); } 2004 bool is_truncating() const { return IsTruncatingBits::decode(minor_key_); }
1997 bool skip_fastpath() const { return SkipFastPathBits::decode(minor_key_); } 2005 bool skip_fastpath() const { return SkipFastPathBits::decode(minor_key_); }
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
2175 class ArraySingleArgumentConstructorStub : public ArrayConstructorStubBase { 2183 class ArraySingleArgumentConstructorStub : public ArrayConstructorStubBase {
2176 public: 2184 public:
2177 ArraySingleArgumentConstructorStub( 2185 ArraySingleArgumentConstructorStub(
2178 Isolate* isolate, 2186 Isolate* isolate,
2179 ElementsKind kind, 2187 ElementsKind kind,
2180 AllocationSiteOverrideMode override_mode = DONT_OVERRIDE) 2188 AllocationSiteOverrideMode override_mode = DONT_OVERRIDE)
2181 : ArrayConstructorStubBase(isolate, kind, override_mode) { 2189 : ArrayConstructorStubBase(isolate, kind, override_mode) {
2182 } 2190 }
2183 2191
2184 private: 2192 private:
2185 virtual void PrintName(std::ostream& os) const { // NOLINT 2193 virtual void PrintName(std::ostream& os) const OVERRIDE { // NOLINT
2186 BasePrintName(os, "ArraySingleArgumentConstructorStub"); 2194 BasePrintName(os, "ArraySingleArgumentConstructorStub");
2187 } 2195 }
2188 2196
2189 DEFINE_CALL_INTERFACE_DESCRIPTOR(ArrayConstructor); 2197 DEFINE_CALL_INTERFACE_DESCRIPTOR(ArrayConstructor);
2190 DEFINE_HYDROGEN_CODE_STUB(ArraySingleArgumentConstructor, 2198 DEFINE_HYDROGEN_CODE_STUB(ArraySingleArgumentConstructor,
2191 ArrayConstructorStubBase); 2199 ArrayConstructorStubBase);
2192 }; 2200 };
2193 2201
2194 2202
2195 class ArrayNArgumentsConstructorStub : public ArrayConstructorStubBase { 2203 class ArrayNArgumentsConstructorStub : public ArrayConstructorStubBase {
2196 public: 2204 public:
2197 ArrayNArgumentsConstructorStub( 2205 ArrayNArgumentsConstructorStub(
2198 Isolate* isolate, 2206 Isolate* isolate,
2199 ElementsKind kind, 2207 ElementsKind kind,
2200 AllocationSiteOverrideMode override_mode = DONT_OVERRIDE) 2208 AllocationSiteOverrideMode override_mode = DONT_OVERRIDE)
2201 : ArrayConstructorStubBase(isolate, kind, override_mode) { 2209 : ArrayConstructorStubBase(isolate, kind, override_mode) {
2202 } 2210 }
2203 2211
2204 private: 2212 private:
2205 virtual void PrintName(std::ostream& os) const { // NOLINT 2213 virtual void PrintName(std::ostream& os) const OVERRIDE { // NOLINT
2206 BasePrintName(os, "ArrayNArgumentsConstructorStub"); 2214 BasePrintName(os, "ArrayNArgumentsConstructorStub");
2207 } 2215 }
2208 2216
2209 DEFINE_CALL_INTERFACE_DESCRIPTOR(ArrayConstructor); 2217 DEFINE_CALL_INTERFACE_DESCRIPTOR(ArrayConstructor);
2210 DEFINE_HYDROGEN_CODE_STUB(ArrayNArgumentsConstructor, 2218 DEFINE_HYDROGEN_CODE_STUB(ArrayNArgumentsConstructor,
2211 ArrayConstructorStubBase); 2219 ArrayConstructorStubBase);
2212 }; 2220 };
2213 2221
2214 2222
2215 class InternalArrayConstructorStubBase : public HydrogenCodeStub { 2223 class InternalArrayConstructorStubBase : public HydrogenCodeStub {
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
2339 ToBooleanStub(Isolate* isolate, ExtraICState state) 2347 ToBooleanStub(Isolate* isolate, ExtraICState state)
2340 : HydrogenCodeStub(isolate) { 2348 : HydrogenCodeStub(isolate) {
2341 set_sub_minor_key(TypesBits::encode(static_cast<byte>(state)) | 2349 set_sub_minor_key(TypesBits::encode(static_cast<byte>(state)) |
2342 ResultModeBits::encode(RESULT_AS_SMI)); 2350 ResultModeBits::encode(RESULT_AS_SMI));
2343 } 2351 }
2344 2352
2345 bool UpdateStatus(Handle<Object> object); 2353 bool UpdateStatus(Handle<Object> object);
2346 Types types() const { return Types(TypesBits::decode(sub_minor_key())); } 2354 Types types() const { return Types(TypesBits::decode(sub_minor_key())); }
2347 ResultMode mode() const { return ResultModeBits::decode(sub_minor_key()); } 2355 ResultMode mode() const { return ResultModeBits::decode(sub_minor_key()); }
2348 2356
2349 virtual Code::Kind GetCodeKind() const { return Code::TO_BOOLEAN_IC; } 2357 virtual Code::Kind GetCodeKind() const OVERRIDE {
2358 return Code::TO_BOOLEAN_IC;
2359 }
2350 virtual void PrintState(std::ostream& os) const OVERRIDE; // NOLINT 2360 virtual void PrintState(std::ostream& os) const OVERRIDE; // NOLINT
2351 2361
2352 virtual bool SometimesSetsUpAFrame() { return false; } 2362 virtual bool SometimesSetsUpAFrame() OVERRIDE { return false; }
2353 2363
2354 static Handle<Code> GetUninitialized(Isolate* isolate) { 2364 static Handle<Code> GetUninitialized(Isolate* isolate) {
2355 return ToBooleanStub(isolate, UNINITIALIZED).GetCode(); 2365 return ToBooleanStub(isolate, UNINITIALIZED).GetCode();
2356 } 2366 }
2357 2367
2358 virtual ExtraICState GetExtraICState() const { return types().ToIntegral(); } 2368 virtual ExtraICState GetExtraICState() const OVERRIDE {
2369 return types().ToIntegral();
2370 }
2359 2371
2360 virtual InlineCacheState GetICState() const { 2372 virtual InlineCacheState GetICState() const OVERRIDE {
2361 if (types().IsEmpty()) { 2373 if (types().IsEmpty()) {
2362 return ::v8::internal::UNINITIALIZED; 2374 return ::v8::internal::UNINITIALIZED;
2363 } else { 2375 } else {
2364 return MONOMORPHIC; 2376 return MONOMORPHIC;
2365 } 2377 }
2366 } 2378 }
2367 2379
2368 private: 2380 private:
2369 ToBooleanStub(Isolate* isolate, InitializationState init_state) 2381 ToBooleanStub(Isolate* isolate, InitializationState init_state)
2370 : HydrogenCodeStub(isolate, init_state) { 2382 : HydrogenCodeStub(isolate, init_state) {
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
2462 DEFINE_NULL_CALL_INTERFACE_DESCRIPTOR(); 2474 DEFINE_NULL_CALL_INTERFACE_DESCRIPTOR();
2463 DEFINE_PLATFORM_CODE_STUB(StubFailureTrampoline, PlatformCodeStub); 2475 DEFINE_PLATFORM_CODE_STUB(StubFailureTrampoline, PlatformCodeStub);
2464 }; 2476 };
2465 2477
2466 2478
2467 class ProfileEntryHookStub : public PlatformCodeStub { 2479 class ProfileEntryHookStub : public PlatformCodeStub {
2468 public: 2480 public:
2469 explicit ProfileEntryHookStub(Isolate* isolate) : PlatformCodeStub(isolate) {} 2481 explicit ProfileEntryHookStub(Isolate* isolate) : PlatformCodeStub(isolate) {}
2470 2482
2471 // The profile entry hook function is not allowed to cause a GC. 2483 // The profile entry hook function is not allowed to cause a GC.
2472 virtual bool SometimesSetsUpAFrame() { return false; } 2484 virtual bool SometimesSetsUpAFrame() OVERRIDE { return false; }
2473 2485
2474 // Generates a call to the entry hook if it's enabled. 2486 // Generates a call to the entry hook if it's enabled.
2475 static void MaybeCallEntryHook(MacroAssembler* masm); 2487 static void MaybeCallEntryHook(MacroAssembler* masm);
2476 2488
2477 private: 2489 private:
2478 static void EntryHookTrampoline(intptr_t function, 2490 static void EntryHookTrampoline(intptr_t function,
2479 intptr_t stack_pointer, 2491 intptr_t stack_pointer,
2480 Isolate* isolate); 2492 Isolate* isolate);
2481 2493
2482 // ProfileEntryHookStub is called at the start of a function, so it has the 2494 // ProfileEntryHookStub is called at the start of a function, so it has the
2483 // same register set. 2495 // same register set.
2484 DEFINE_CALL_INTERFACE_DESCRIPTOR(CallFunction) 2496 DEFINE_CALL_INTERFACE_DESCRIPTOR(CallFunction)
2485 DEFINE_PLATFORM_CODE_STUB(ProfileEntryHook, PlatformCodeStub); 2497 DEFINE_PLATFORM_CODE_STUB(ProfileEntryHook, PlatformCodeStub);
2486 }; 2498 };
2487 2499
2488 2500
2489 class StoreBufferOverflowStub : public PlatformCodeStub { 2501 class StoreBufferOverflowStub : public PlatformCodeStub {
2490 public: 2502 public:
2491 StoreBufferOverflowStub(Isolate* isolate, SaveFPRegsMode save_fp) 2503 StoreBufferOverflowStub(Isolate* isolate, SaveFPRegsMode save_fp)
2492 : PlatformCodeStub(isolate) { 2504 : PlatformCodeStub(isolate) {
2493 minor_key_ = SaveDoublesBits::encode(save_fp == kSaveFPRegs); 2505 minor_key_ = SaveDoublesBits::encode(save_fp == kSaveFPRegs);
2494 } 2506 }
2495 2507
2496 static void GenerateFixedRegStubsAheadOfTime(Isolate* isolate); 2508 static void GenerateFixedRegStubsAheadOfTime(Isolate* isolate);
2497 virtual bool SometimesSetsUpAFrame() { return false; } 2509 virtual bool SometimesSetsUpAFrame() OVERRIDE { return false; }
2498 2510
2499 private: 2511 private:
2500 bool save_doubles() const { return SaveDoublesBits::decode(minor_key_); } 2512 bool save_doubles() const { return SaveDoublesBits::decode(minor_key_); }
2501 2513
2502 class SaveDoublesBits : public BitField<bool, 0, 1> {}; 2514 class SaveDoublesBits : public BitField<bool, 0, 1> {};
2503 2515
2504 DEFINE_NULL_CALL_INTERFACE_DESCRIPTOR(); 2516 DEFINE_NULL_CALL_INTERFACE_DESCRIPTOR();
2505 DEFINE_PLATFORM_CODE_STUB(StoreBufferOverflow, PlatformCodeStub); 2517 DEFINE_PLATFORM_CODE_STUB(StoreBufferOverflow, PlatformCodeStub);
2506 }; 2518 };
2507 2519
(...skipping 18 matching lines...) Expand all
2526 2538
2527 #undef DEFINE_CALL_INTERFACE_DESCRIPTOR 2539 #undef DEFINE_CALL_INTERFACE_DESCRIPTOR
2528 #undef DEFINE_PLATFORM_CODE_STUB 2540 #undef DEFINE_PLATFORM_CODE_STUB
2529 #undef DEFINE_HANDLER_CODE_STUB 2541 #undef DEFINE_HANDLER_CODE_STUB
2530 #undef DEFINE_HYDROGEN_CODE_STUB 2542 #undef DEFINE_HYDROGEN_CODE_STUB
2531 #undef DEFINE_CODE_STUB 2543 #undef DEFINE_CODE_STUB
2532 #undef DEFINE_CODE_STUB_BASE 2544 #undef DEFINE_CODE_STUB_BASE
2533 } } // namespace v8::internal 2545 } } // namespace v8::internal
2534 2546
2535 #endif // V8_CODE_STUBS_H_ 2547 #endif // V8_CODE_STUBS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698