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

Side by Side Diff: src/assembler.h

Issue 19562003: Add support for IncrementCounter in Hydrogen. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: And another try Created 7 years, 4 months 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
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/hydrogen.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 666 matching lines...) Expand 10 before | Expand all | Expand 10 after
677 // AccessorGetterCallback callback) 677 // AccessorGetterCallback callback)
678 PROFILING_GETTER_CALL_NEW 678 PROFILING_GETTER_CALL_NEW
679 }; 679 };
680 680
681 static void SetUp(); 681 static void SetUp();
682 static void InitializeMathExpData(); 682 static void InitializeMathExpData();
683 static void TearDownMathExpData(); 683 static void TearDownMathExpData();
684 684
685 typedef void* ExternalReferenceRedirector(void* original, Type type); 685 typedef void* ExternalReferenceRedirector(void* original, Type type);
686 686
687 ExternalReference() : address_(NULL) {}
688
687 ExternalReference(Builtins::CFunctionId id, Isolate* isolate); 689 ExternalReference(Builtins::CFunctionId id, Isolate* isolate);
688 690
689 ExternalReference(ApiFunction* ptr, Type type, Isolate* isolate); 691 ExternalReference(ApiFunction* ptr, Type type, Isolate* isolate);
690 692
691 ExternalReference(Builtins::Name name, Isolate* isolate); 693 ExternalReference(Builtins::Name name, Isolate* isolate);
692 694
693 ExternalReference(Runtime::FunctionId id, Isolate* isolate); 695 ExternalReference(Runtime::FunctionId id, Isolate* isolate);
694 696
695 ExternalReference(const Runtime::Function* f, Isolate* isolate); 697 ExternalReference(const Runtime::Function* f, Isolate* isolate);
696 698
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
822 824
823 static ExternalReference math_exp_constants(int constant_index); 825 static ExternalReference math_exp_constants(int constant_index);
824 static ExternalReference math_exp_log_table(); 826 static ExternalReference math_exp_log_table();
825 827
826 static ExternalReference page_flags(Page* page); 828 static ExternalReference page_flags(Page* page);
827 829
828 static ExternalReference ForDeoptEntry(Address entry); 830 static ExternalReference ForDeoptEntry(Address entry);
829 831
830 static ExternalReference cpu_features(); 832 static ExternalReference cpu_features();
831 833
832 Address address() const {return reinterpret_cast<Address>(address_);} 834 Address address() const { return reinterpret_cast<Address>(address_); }
833 835
834 #ifdef ENABLE_DEBUGGER_SUPPORT 836 #ifdef ENABLE_DEBUGGER_SUPPORT
835 // Function Debug::Break() 837 // Function Debug::Break()
836 static ExternalReference debug_break(Isolate* isolate); 838 static ExternalReference debug_break(Isolate* isolate);
837 839
838 // Used to check if single stepping is enabled in generated code. 840 // Used to check if single stepping is enabled in generated code.
839 static ExternalReference debug_step_in_fp_address(Isolate* isolate); 841 static ExternalReference debug_step_in_fp_address(Isolate* isolate);
840 #endif 842 #endif
841 843
842 #ifndef V8_INTERPRETED_REGEXP 844 #ifndef V8_INTERPRETED_REGEXP
(...skipping 18 matching lines...) Expand all
861 static void set_redirector(Isolate* isolate, 863 static void set_redirector(Isolate* isolate,
862 ExternalReferenceRedirector* redirector) { 864 ExternalReferenceRedirector* redirector) {
863 // We can't stack them. 865 // We can't stack them.
864 ASSERT(isolate->external_reference_redirector() == NULL); 866 ASSERT(isolate->external_reference_redirector() == NULL);
865 isolate->set_external_reference_redirector( 867 isolate->set_external_reference_redirector(
866 reinterpret_cast<ExternalReferenceRedirectorPointer*>(redirector)); 868 reinterpret_cast<ExternalReferenceRedirectorPointer*>(redirector));
867 } 869 }
868 870
869 static ExternalReference stress_deopt_count(Isolate* isolate); 871 static ExternalReference stress_deopt_count(Isolate* isolate);
870 872
873 bool operator==(const ExternalReference& other) const {
874 return address_ == other.address_;
875 }
876
877 bool operator!=(const ExternalReference& other) const {
878 return !(*this == other);
879 }
880
871 private: 881 private:
872 explicit ExternalReference(void* address) 882 explicit ExternalReference(void* address)
873 : address_(address) {} 883 : address_(address) {}
874 884
875 static void* Redirect(Isolate* isolate, 885 static void* Redirect(Isolate* isolate,
876 void* address, 886 void* address,
877 Type type = ExternalReference::BUILTIN_CALL) { 887 Type type = ExternalReference::BUILTIN_CALL) {
878 ExternalReferenceRedirector* redirector = 888 ExternalReferenceRedirector* redirector =
879 reinterpret_cast<ExternalReferenceRedirector*>( 889 reinterpret_cast<ExternalReferenceRedirector*>(
880 isolate->external_reference_redirector()); 890 isolate->external_reference_redirector());
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
1064 public: 1074 public:
1065 NullCallWrapper() { } 1075 NullCallWrapper() { }
1066 virtual ~NullCallWrapper() { } 1076 virtual ~NullCallWrapper() { }
1067 virtual void BeforeCall(int call_size) const { } 1077 virtual void BeforeCall(int call_size) const { }
1068 virtual void AfterCall() const { } 1078 virtual void AfterCall() const { }
1069 }; 1079 };
1070 1080
1071 } } // namespace v8::internal 1081 } } // namespace v8::internal
1072 1082
1073 #endif // V8_ASSEMBLER_H_ 1083 #endif // V8_ASSEMBLER_H_
OLDNEW
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/hydrogen.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698