Closed Bug 532440 Opened 15 years ago Closed 14 years ago

The high cost of Vector construction

Categories

(Tamarin Graveyard :: Virtual Machine, defect, P2)

x86
macOS
defect

Tracking

(Not tracked)

VERIFIED DUPLICATE of bug 532690
Q3 11 - Serrano

People

(Reporter: dschaffe, Assigned: tharwood)

References

Details

(Whiteboard: PACMAN)

in tamarin-redux/test/performance/v8.5/optimized/splay.as the PayloadData object contains an array of 10 digits.  I changed the type from Array to Vector.<int> and saw a ~450 point slowdown (3450->3000).  I used the initializer new <int>[0,1,2,3,4,5,6,7,8,9] syntax.  The intializer was faster than created an empty vector and doing push(0,1,2,3,4,5,6,7,8,9).  Changing from Array to Vector should provide a speedup.
Flags: flashplayer-triage+
Flags: flashplayer-qrb?
Assignee: nobody → tharwood
Status: NEW → ASSIGNED
Flags: flashplayer-qrb? → flashplayer-qrb+
Priority: -- → P2
Target Milestone: --- → flash10.1
Depends on: 532690
Spent the day Sharking this app and a derivative ArrayVsVector deathmatch testcase.  The difference in speed does come from the differing construction cost of array vs. the cost of Vector.  The cost of creating a Vector is so high that it contributes substantially to even a test run where very few Vectors are created; Vector objects are also created in contexts where it's easy to forget that they're in play, e.g., splice().
Retargeting to 10.2 milestone.
Target Milestone: flash10.1 → flash10.2
Summary: in v8 benchmark splay using Vector.<int> in PayloadData instead of Array is slower → The high cost of Vector construction
Probably the same as bug #532690.
Whiteboard: PACMAN
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → DUPLICATE
bulk verifying resolved !fixed issues
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.