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

Unified Diff: src/code-stubs.cc

Issue 565873002: Removing ic.h from code-stubs.h (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: REBASE and mips. Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/code-stubs.h ('k') | src/code-stubs-hydrogen.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stubs.cc
diff --git a/src/code-stubs.cc b/src/code-stubs.cc
index fac530eb4c2e7e8425fa16c458b91e8e910a713e..be868ffa241b22b02c0f75002ad479e7d6adefa8 100644
--- a/src/code-stubs.cc
+++ b/src/code-stubs.cc
@@ -10,6 +10,7 @@
#include "src/factory.h"
#include "src/gdb-jit.h"
#include "src/ic/handler-compiler.h"
+#include "src/ic/ic.h"
#include "src/macro-assembler.h"
namespace v8 {
@@ -258,7 +259,7 @@ void BinaryOpICStub::GenerateAheadOfTime(Isolate* isolate) {
}
// Generate special versions of the stub.
- BinaryOpIC::State::GenerateAheadOfTime(isolate, &GenerateAheadOfTime);
+ BinaryOpICState::GenerateAheadOfTime(isolate, &GenerateAheadOfTime);
}
@@ -269,7 +270,7 @@ void BinaryOpICStub::PrintState(OStream& os) const { // NOLINT
// static
void BinaryOpICStub::GenerateAheadOfTime(Isolate* isolate,
- const BinaryOpIC::State& state) {
+ const BinaryOpICState& state) {
BinaryOpICStub stub(isolate, state);
stub.GetCode();
}
@@ -278,7 +279,7 @@ void BinaryOpICStub::GenerateAheadOfTime(Isolate* isolate,
// static
void BinaryOpICWithAllocationSiteStub::GenerateAheadOfTime(Isolate* isolate) {
// Generate special versions of the stub.
- BinaryOpIC::State::GenerateAheadOfTime(isolate, &GenerateAheadOfTime);
+ BinaryOpICState::GenerateAheadOfTime(isolate, &GenerateAheadOfTime);
}
@@ -290,7 +291,7 @@ void BinaryOpICWithAllocationSiteStub::PrintState(
// static
void BinaryOpICWithAllocationSiteStub::GenerateAheadOfTime(
- Isolate* isolate, const BinaryOpIC::State& state) {
+ Isolate* isolate, const BinaryOpICState& state) {
if (state.CouldCreateAllocationMementos()) {
BinaryOpICWithAllocationSiteStub stub(isolate, state);
stub.GetCode();
@@ -314,19 +315,19 @@ void StringAddStub::PrintBaseName(OStream& os) const { // NOLINT
InlineCacheState CompareICStub::GetICState() const {
- CompareIC::State state = Max(left(), right());
+ CompareICState::State state = Max(left(), right());
switch (state) {
- case CompareIC::UNINITIALIZED:
+ case CompareICState::UNINITIALIZED:
return ::v8::internal::UNINITIALIZED;
- case CompareIC::SMI:
- case CompareIC::NUMBER:
- case CompareIC::INTERNALIZED_STRING:
- case CompareIC::STRING:
- case CompareIC::UNIQUE_NAME:
- case CompareIC::OBJECT:
- case CompareIC::KNOWN_OBJECT:
+ case CompareICState::SMI:
+ case CompareICState::NUMBER:
+ case CompareICState::INTERNALIZED_STRING:
+ case CompareICState::STRING:
+ case CompareICState::UNIQUE_NAME:
+ case CompareICState::OBJECT:
+ case CompareICState::KNOWN_OBJECT:
return MONOMORPHIC;
- case CompareIC::GENERIC:
+ case CompareICState::GENERIC:
return ::v8::internal::GENERIC;
}
UNREACHABLE();
@@ -334,6 +335,11 @@ InlineCacheState CompareICStub::GetICState() const {
}
+Condition CompareICStub::GetCondition() const {
+ return CompareIC::ComputeCondition(op());
+}
+
+
void CompareICStub::AddToSpecialCache(Handle<Code> new_object) {
DCHECK(*known_map_ != NULL);
Isolate* isolate = new_object->GetIsolate();
@@ -376,32 +382,32 @@ bool CompareICStub::FindCodeInSpecialCache(Code** code_out) {
void CompareICStub::Generate(MacroAssembler* masm) {
switch (state()) {
- case CompareIC::UNINITIALIZED:
+ case CompareICState::UNINITIALIZED:
GenerateMiss(masm);
break;
- case CompareIC::SMI:
+ case CompareICState::SMI:
GenerateSmis(masm);
break;
- case CompareIC::NUMBER:
+ case CompareICState::NUMBER:
GenerateNumbers(masm);
break;
- case CompareIC::STRING:
+ case CompareICState::STRING:
GenerateStrings(masm);
break;
- case CompareIC::INTERNALIZED_STRING:
+ case CompareICState::INTERNALIZED_STRING:
GenerateInternalizedStrings(masm);
break;
- case CompareIC::UNIQUE_NAME:
+ case CompareICState::UNIQUE_NAME:
GenerateUniqueNames(masm);
break;
- case CompareIC::OBJECT:
+ case CompareICState::OBJECT:
GenerateObjects(masm);
break;
- case CompareIC::KNOWN_OBJECT:
+ case CompareICState::KNOWN_OBJECT:
DCHECK(*known_map_ != NULL);
GenerateKnownObjects(masm);
break;
- case CompareIC::GENERIC:
+ case CompareICState::GENERIC:
GenerateGeneric(masm);
break;
}
« no previous file with comments | « src/code-stubs.h ('k') | src/code-stubs-hydrogen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698