1. 11 Sep, 2013 1 commit
  2. 02 Sep, 2013 1 commit
  3. 22 Aug, 2013 1 commit
  4. 24 Jul, 2013 1 commit
  5. 20 Jun, 2013 1 commit
  6. 14 Jun, 2013 1 commit
  7. 13 Jun, 2013 1 commit
  8. 06 Jun, 2013 1 commit
  9. 31 May, 2013 1 commit
  10. 08 May, 2013 1 commit
  11. 07 May, 2013 1 commit
  12. 26 Apr, 2013 1 commit
  13. 25 Mar, 2013 1 commit
  14. 04 Mar, 2013 2 commits
  15. 28 Feb, 2013 1 commit
  16. 27 Feb, 2013 1 commit
  17. 26 Feb, 2013 1 commit
    • mstarzinger@chromium.org's avatar
      Make __proto__ a foreign callback on Object.prototype. · ce1e10f5
      mstarzinger@chromium.org authored
      This moves the __proto__ property to Object.prototype and turns it into
      a callback property actually present in the descriptor array as opposed
      to a hack in the properties lookup. For now it still is a "magic" data
      property using foreign callbacks and not an accessor property visible to
      JavaScript.
      
      The second effect of this change is that JSON.parse() no longer treats
      the __proto__ property specially, it will be defined as any other data
      property. Note that object literals still have their special handling.
      
      R=rossberg@chromium.org
      BUG=v8:621,v8:1949,v8:2441
      TEST=mjsunit,cctest,test262
      
      Review URL: https://codereview.chromium.org/12212011
      
      git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13728 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
      ce1e10f5
  18. 13 Dec, 2012 1 commit
  19. 13 Nov, 2012 1 commit
  20. 07 Nov, 2012 1 commit
  21. 12 Sep, 2012 1 commit
    • verwaest@chromium.org's avatar
      Sharing of descriptor arrays. · ebd3241b
      verwaest@chromium.org authored
      This CL adds multiple things:
      Transition arrays do not directly point at their descriptor array anymore, but rather do so via an indirect pointer (a JSGlobalPropertyCell).
      
      An ownership bit is added to maps indicating whether it owns its own descriptor array or not.
      
      Maps owning a descriptor array can pass on ownership if a transition from that map is generated; but only if the descriptor array stays exactly the same; or if a descriptor is added.
      
      Maps that don't have ownership get ownership back if their direct child to which ownership was passed is cleared in ClearNonLiveTransitions.
      
      To detect which descriptors in an array are valid, each map knows its own NumberOfOwnDescriptors. Since the descriptors are sorted in order of addition, if we search and find a descriptor with index bigger than this number, it is not valid for the given map.
      
      We currently still build up an enumeration cache (although this may disappear). The enumeration cache is always built for the entire descriptor array, even if not all descriptors are owned by the map. Once a descriptor array has an enumeration cache for a given map; this invariant will always be true, even if the descriptor array was extended. The extended array will inherit the enumeration cache from the smaller descriptor array. If a map with more descriptors needs an enumeration cache, it's EnumLength will still be set to invalid, so it will have to recompute the enumeration cache. This new cache will also be valid for smaller maps since they have their own enumlength; and use this to loop over the cache. If the EnumLength is still invalid, but there is already a cache present that is big enough; we just initialize the EnumLength field for the map.
      
      When we apply ClearNonLiveTransitions and descriptor ownership is passed back to a parent map, the descriptor array is trimmed in-place and resorted. At the same time, the enumeration cache is trimmed in-place.
      
      Only transition arrays contain descriptor arrays. If we transition to a map and pass ownership of the descriptor array along, the child map will not store the descriptor array it owns. Rather its parent will keep the pointer. So for every leaf-map, we find the descriptor array by following the back pointer, reading out the transition array, and fetching the descriptor array from the JSGlobalPropertyCell. If a map has a transition array, we fetch it from there. If a map has undefined as its back-pointer and has no transition array; it is considered to have an empty descriptor array.
      
      When we modify properties, we cannot share the descriptor array. To accommodate this, the child map will get its own transition array; even if there are not necessarily any transitions leaving from the child map. This is necessary since it's the only way to store its own descriptor array.
      
      Review URL: https://chromiumcodereview.appspot.com/10909007
      
      git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12492 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
      ebd3241b
  22. 27 Aug, 2012 1 commit
    • verwaest@chromium.org's avatar
      Make order of addition the primary order of descriptor arrays. · efb53e14
      verwaest@chromium.org authored
      The order by name is maintained as secondary order by using unused bits in the property details.
      
      This is preliminary work towards sharing descriptors arrays.
      
      The change allows us
      - to get rid of the LastAdded bits in the map, binding it to the number of valid descriptors for the given map
      - to avoid resorting by enumeration index to create the cache
      - (maybe in the future, depending on performance) to get rid of the enumeration cache altogether.
      
      Although generally the number_of_descriptors equals the NumberOfOwnDescriptors in the current version, this is preliminary work towards sharing    descriptors, where maps may have more descriptors than are valid for the map.
      
      Review URL: https://chromiumcodereview.appspot.com/10879013
      
      git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12385 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
      efb53e14
  23. 18 Jul, 2012 1 commit
  24. 16 Jul, 2012 1 commit
  25. 12 Jul, 2012 2 commits
  26. 11 Jul, 2012 1 commit
  27. 06 Jul, 2012 1 commit
  28. 05 Jul, 2012 1 commit
    • verwaest@chromium.org's avatar
      Separating transitions from descriptors. · d7a5b7d5
      verwaest@chromium.org authored
      In this design maps contain descriptor arrays, which in turn can contain transition arrays. If transitions are needed when no descriptor array is present, a descriptor array without real descriptors is inserted just so it can point at the transition array.
      
      The transition array does not contain details about the field it transitions to. In order to weed out transitions to FIELDs from CONSTANT_FUNCTION (what used to be MAP_TRANSITION vs CONSTANT_TRANSITION), the transition needs to be followed and the details need to be looked up in the target map. CALLBACKS transitions are still easy to recognize since the transition targets are stored as an AccessorPair containing the maps, rather than the maps directly.
      
      Currently AccessorPairs containing a transition and an accessor are shared between the descriptor array and the transition array. This simplifies lookup since we only have to look in one of both arrays. This will change in subsequent revisions, when descriptor arrays will become shared between multiple maps, since transitions cannot be shared.
      
      Review URL: https://chromiumcodereview.appspot.com/10697015
      
      git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11994 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
      d7a5b7d5
  29. 25 Jun, 2012 2 commits
  30. 21 Jun, 2012 1 commit
  31. 11 Jun, 2012 1 commit
  32. 17 Apr, 2012 1 commit
  33. 06 Mar, 2012 1 commit
  34. 02 Mar, 2012 1 commit
    • svenpanne@chromium.org's avatar
      Re-land CL 9466047. · 5033b9b6
      svenpanne@chromium.org authored
      Main change from the original CL: Call::ComputeTarget does not use IsProperty
      anymore, because this would potentially need a holder, which we don't have
      here. Using Map::LookupInDescriptors with a NULL holder is a bit fishy in
      general, because one has to be *extremely* careful when using its LookupResult.
      
      The original CL made Chrome's NetInternalsTest.netInternalsTourTabs browser test
      fail, but it's a mystery how this could happen: We should never reach
      Call::ComputeTarget via Call::RecordTypeFeedback with a CALLBACKS property,
      because we never consider calls to them monomorphic, which is in turn because of
      the stub cache leaving them in the pre-monomorphic state. Therefore, I don't
      have a clue how to write a regression test for this...
      
      As an additional tiny bonus, the --trace-opt output for deoptimizations has been
      improved.
      
      Review URL: https://chromiumcodereview.appspot.com/9584003
      
      git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10906 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
      5033b9b6
  35. 29 Feb, 2012 1 commit
  36. 28 Feb, 2012 1 commit
    • svenpanne@chromium.org's avatar
      Handle CALLBACKS correctly in IsProperty functions. · 18ba2216
      svenpanne@chromium.org authored
      With transitions in AccessorPairs, it is not enough to look at the PropertyType
      alone to decide whether we look at a property or not: For objects with
      JavaScript accessors, we have to look into the AccessorPair itself and see if
      one of its 2 parts is actually a JavaScript accessor. Therefore, a predicate
      with a PropertyType argument alone doesn't make sense anymore, we might need the
      associated value, too.
      
      Things are complicated by the fact that the holder in a LookupResult can be
      NULL, so we must be careful to retrieve its value only when it is really
      needed. To achieve the needed call-by-name semantics, a new Entry is introduced,
      which is basically a closure over a DescriptorArray and an index into this array
      (C++0x to the rescue!). GCC is clever enough to inline this class, so we pay no
      runtime penalty for this abstraction.
      
      It's all a bit ugly, but this is caused by the current structure of Descriptor,
      DescriptorArray and LookupResult: Things would be much easier if DescriptorArray
      were, well, an array of Descriptors, and LookupResult were a 'Maybe Descriptor'
      (in Haskell-terms).
      
      Review URL: https://chromiumcodereview.appspot.com/9466047
      
      git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10847 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
      18ba2216
  37. 06 Feb, 2012 1 commit