Part five of this series on Flash Player 10.0 versus Flash Player 10.1 performance continues re-testing performance articles just like the first, second, third, and fourth articles did. Read on for more performance comparisons!

Introduction

This part’s performance methodology will be the same as first, second, third, and fourth articles, so let’s get right to the comparisons.

Sorting Vectors

Original Article

Method Unsorted 10.0 Pre-Sorted 10.0 Unsorted 10.1 Pre-Sorted 10.1
Vector via sort() 1603 1190 1110 814
Array via sortOn() 644 350 588 343
Vector via quickSort() 3960 3027 2932 2249
Vector via shellSort() 6142 3455 5262 2642
Vector via Array.sortOn() 925 468 879 462

Without exception, all of the sorting approaches are faster in Flash Player 10.0. Unfortunately, most of the performance gains are minor with the exceptions of quickSort and shellSort. Even so, these boosted manual sort functions are still vastly slower than the alternatives.

Increment and Decrement

Original Article

Environment Post-Increment Pre-increment Add One Post-Decrement Pre-Decrement Subtract One
Flash Player 10.0 236 236 236 236 236 236
Flash Player 10.1 202 202 202 202 202 202

There are two findings to take away from this re-test: your choice of increment/decrement style still doesn’t matter and all increments and decrements are now about 17% faster.

Array vs. Vector

Original Article

Environment Array (read) Vector (fixed, read) Vector (dynamic, read) Array (write) Vector (fixed, write) Vector (dynamic, write)
Flash Player 10.0 835 599 595 1912 698 714
Flash Player 10.1 1112 708 709 1925 808 810

Sadly, both Array and Vector got slower in Flash Player 10.1. While this is not really pronounced when writing to them, reading is about 19-33% slower. For more on this, see Map Performance in the previous article in this series.

Array vs. Vector: Part II

Original Article

Read Performance

Environment Array Vector (int) Vector (uint) Vector (Number) Vector (Boolean) Vector (String) Vector (Object)
Flash Player 10.0 38 29 (31%) 31 (23%) 30 (27%) 29 (31%) 29 (31%) 30 (27%)
Flash Player 10.1 38 30 (27%) 29 (31%) 31 (23%) 30 (27%) 29 (31%) 30 (27%)

Write Performance

Environment Array Vector (int) Vector (uint) Vector (Number) Vector (Boolean) Vector (String) Vector (Object)
Flash Player 10.0 96 37 (259%) 37 (259%) 39 (246%) 72 (33%) 90 (7%) 131 (-36%)
Flash Player 10.1 97 37 (262%) 40 (235%) 38 (255%) 75 (29%) 90 (8%) 125 (-22%)

Delete Performance

Environment Array Vector (int) Vector (uint) Vector (Number) Vector (Boolean) Vector (String) Vector (Object)
Flash Player 10.0 4544 4429 (3%) 4431 (3%) 4473 (2%) 4506 (1%) 4510 (1%) 4485 (1%)
Flash Player 10.1 4630 4596 (1%) 4546 (2%) 4591 (1%) 4628 (0%) 4592 (1%) 4597 (1%)

At these lower volumes, the performance difference in reading and writing are less apparent than in the re-test for the first part of this article. Deleting is still enormously expensive though, but relatively unchanged in proportion to Flash Player 10.0.

Inline Math.ceil() Part II

Original Article

Environment Inline (positive) Inline (positive and negative) Math.ceil()
Flash Player 10.0 777 (3.5x) 775 (3.5x) 2741
Flash Player 10.1 740 (1.8x) 745 (1.8x) 1360

It seems that Math.ceil() has received a much-needed performance boost in Flash Player 10.1; it is now twice as fast as it was in Flash Player 10.0! The inlined version, however, hasn’t been sped up at all and therefore sees its lead diminished to a mere 1.8x speedup. It is therefore still useful for performance-critical areas of code that need to take the mathematical ceiling.

One More To Come

With only three more performance articles to re-test, the next article in this series will be the last. Stay tuned for the conclusion!