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

Unified Diff: src/objects.h

Issue 26539010: Revert "AllocationSites for all literals" (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 2 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/hydrogen.cc ('k') | src/objects.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index 50c739cb9e0e2d8d1157b6360e368d28516e3419..2925c54f1800c279598aaf92fc8a047615b6d42c 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -865,9 +865,8 @@ enum CompareResult {
inline void set_##name(type* value, \
WriteBarrierMode mode = UPDATE_WRITE_BARRIER); \
+
class AccessorPair;
-class AllocationSite;
-class AllocationSiteContext;
class DictionaryElementsAccessor;
class ElementsAccessor;
class Failure;
@@ -2545,13 +2544,8 @@ class JSObject: public JSReceiver {
MUST_USE_RESULT MaybeObject* SetObserved(Isolate* isolate);
// Copy object.
- static Handle<JSObject> Copy(Handle<JSObject> object,
- Handle<AllocationSite> site);
static Handle<JSObject> Copy(Handle<JSObject> object);
- static Handle<JSObject> DeepCopy(Handle<JSObject> object,
- AllocationSiteContext* site_context);
- static Handle<JSObject> DeepWalk(Handle<JSObject> object,
- AllocationSiteContext* site_context);
+ static Handle<JSObject> DeepCopy(Handle<JSObject> object);
// Casting.
static inline JSObject* cast(Object* obj);
@@ -8011,15 +8005,8 @@ class AllocationSite: public Struct {
inline void Initialize();
- bool HasNestedSites() {
- return nested_site()->IsAllocationSite();
- }
-
- // This method is expensive, it should only be called for reporting.
- bool IsNestedSite();
-
ElementsKind GetElementsKind() {
- ASSERT(!SitePointsToLiteral());
+ ASSERT(!IsLiteralSite());
return static_cast<ElementsKind>(Smi::cast(transition_info())->value());
}
@@ -8027,11 +8014,11 @@ class AllocationSite: public Struct {
set_transition_info(Smi::FromInt(static_cast<int>(kind)));
}
- bool SitePointsToLiteral() {
+ bool IsLiteralSite() {
// If transition_info is a smi, then it represents an ElementsKind
// for a constructed array. Otherwise, it must be a boilerplate
- // for an object or array literal.
- return transition_info()->IsJSArray() || transition_info()->IsJSObject();
+ // for an array literal
+ return transition_info()->IsJSArray();
}
DECLARE_PRINTER(AllocationSite)
« no previous file with comments | « src/hydrogen.cc ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698