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

Unified Diff: src/ic.h

Issue 102563004: Zonify types in compiler frontend (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased Created 7 years 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/ia32/stub-cache-ia32.cc ('k') | src/ic.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic.h
diff --git a/src/ic.h b/src/ic.h
index ffce9418a1ec66f9481d5af16bc55082be2e25a8..b8d508d82f0413877fe2cda27d2536b4ca420a99 100644
--- a/src/ic.h
+++ b/src/ic.h
@@ -150,9 +150,9 @@ class IC {
Object* object,
InlineCacheHolderFlag holder);
- static inline InlineCacheHolderFlag GetCodeCacheFlag(Type* type);
+ static inline InlineCacheHolderFlag GetCodeCacheFlag(HeapType* type);
static inline Handle<Map> GetCodeCacheHolder(InlineCacheHolderFlag flag,
- Type* type,
+ HeapType* type,
Isolate* isolate);
static bool IsCleared(Code* code) {
@@ -165,9 +165,10 @@ class IC {
// - The heap_number_map is used as a marker which includes heap numbers as
// well as smis.
// - The oddball map is only used for booleans.
- static Handle<Map> TypeToMap(Type* type, Isolate* isolate);
- static Handle<Type> MapToType(Handle<Map> type);
- static Handle<Type> CurrentTypeOf(Handle<Object> object, Isolate* isolate);
+ static Handle<Map> TypeToMap(HeapType* type, Isolate* isolate);
+ static Handle<HeapType> MapToType(Handle<Map> map);
+ static Handle<HeapType> CurrentTypeOf(
+ Handle<Object> object, Isolate* isolate);
protected:
// Get the call-site target; used for determining the state.
@@ -221,19 +222,19 @@ class IC {
return Handle<Code>::null();
}
- void UpdateMonomorphicIC(Handle<Type> type,
+ void UpdateMonomorphicIC(Handle<HeapType> type,
Handle<Code> handler,
Handle<String> name);
- bool UpdatePolymorphicIC(Handle<Type> type,
+ bool UpdatePolymorphicIC(Handle<HeapType> type,
Handle<String> name,
Handle<Code> code);
- virtual void UpdateMegamorphicCache(Type* type, Name* name, Code* code);
+ virtual void UpdateMegamorphicCache(HeapType* type, Name* name, Code* code);
void CopyICToMegamorphicCache(Handle<String> name);
- bool IsTransitionOfMonomorphicTarget(Handle<Type> type);
- void PatchCache(Handle<Type> type,
+ bool IsTransitionOfMonomorphicTarget(Handle<HeapType> type);
+ void PatchCache(Handle<HeapType> type,
Handle<String> name,
Handle<Code> code);
virtual Code::Kind kind() const {
@@ -541,7 +542,7 @@ class KeyedLoadIC: public LoadIC {
return isolate()->builtins()->KeyedLoadIC_Slow();
}
- virtual void UpdateMegamorphicCache(Type* type, Name* name, Code* code) { }
+ virtual void UpdateMegamorphicCache(HeapType* type, Name* name, Code* code) {}
private:
// Stub accessors.
@@ -745,7 +746,7 @@ class KeyedStoreIC: public StoreIC {
protected:
virtual Code::Kind kind() const { return Code::KEYED_STORE_IC; }
- virtual void UpdateMegamorphicCache(Type* type, Name* name, Code* code) { }
+ virtual void UpdateMegamorphicCache(HeapType* type, Name* name, Code* code) {}
virtual ExtraICState extra_ic_state() {
return ComputeExtraICState(strict_mode(), STANDARD_STORE);
@@ -876,13 +877,13 @@ class BinaryOpIC: public IC {
OverwriteMode mode() const { return mode_; }
Maybe<int> fixed_right_arg() const { return fixed_right_arg_; }
- Handle<Type> GetLeftType(Isolate* isolate) const {
- return KindToType(left_kind_, isolate);
+ Type* GetLeftType(Zone* zone) const {
+ return KindToType(left_kind_, zone);
}
- Handle<Type> GetRightType(Isolate* isolate) const {
- return KindToType(right_kind_, isolate);
+ Type* GetRightType(Zone* zone) const {
+ return KindToType(right_kind_, zone);
}
- Handle<Type> GetResultType(Isolate* isolate) const;
+ Type* GetResultType(Zone* zone) const;
void Print(StringStream* stream) const;
@@ -896,7 +897,7 @@ class BinaryOpIC: public IC {
Kind UpdateKind(Handle<Object> object, Kind kind) const;
static const char* KindToString(Kind kind);
- static Handle<Type> KindToType(Kind kind, Isolate* isolate);
+ static Type* KindToType(Kind kind, Zone* zone);
static bool KindMaybeSmi(Kind kind) {
return (kind >= SMI && kind <= NUMBER) || kind == GENERIC;
}
@@ -953,16 +954,16 @@ class CompareIC: public IC {
static State NewInputState(State old_state, Handle<Object> value);
- static Handle<Type> StateToType(Isolate* isolate,
- State state,
- Handle<Map> map = Handle<Map>());
+ static Type* StateToType(Zone* zone,
+ State state,
+ Handle<Map> map = Handle<Map>());
static void StubInfoToType(int stub_minor_key,
- Handle<Type>* left_type,
- Handle<Type>* right_type,
- Handle<Type>* overall_type,
+ Type** left_type,
+ Type** right_type,
+ Type** overall_type,
Handle<Map> map,
- Isolate* isolate);
+ Zone* zone);
CompareIC(Isolate* isolate, Token::Value op)
: IC(EXTRA_CALL_FRAME, isolate), op_(op) { }
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/ic.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698