Looking at the world of media: from music to RIA.

Flash Player Internals: Motto’s and Percentages (part one)

October 25th, 2007 Posted in ActionScript, Flash Player, max 2007

rune_flash.gifDuring the Adobe Max Conference I had the chance to sit in on “Flash Player Internals” session put on by Jim Corbett and Lee Thomason. Of all the sessions I attended at Max, this was by far the best and most informative for me. It was deep, fast and packed with little nuggets that I had heard in passing but never had fully explained. I am going to try and recap the session as best as I can and if you see any incorrect data please let me know!

You break it you buy it

First off, Jim and Lee dropped the Flash Player motto on us: “No breaking the web”. This is a really important concept for developers as they evolve apps over time. As a lot of oldschool Flash devs know there are a lot of hacks we used to take advantage of. Accessing objects via hidden flags so we can get to the data that we really need. The issue is that some of these hacks were bugs in the player that we used to our advantage. What happens when the Flash Player team finds and then fixes the bug we built upon?

For example, we built our SWF in Flash 6 and used a hack to make our application work. In Flash 7 they fix the bug/hack. This would mean that if our SWF was run in Flash Player 7 the app would break… and this violates the Flash Player teams motto.

So, what they have done is made a kind of progressive fallback sandbox. If it worked in Flash Player 6 and your movie was made for Flash Player 6 then your SWF will be run in the FP6 version of the sandbox and your hack will work. If the developer wants to leverage the fix in Flash Player 7, then the SWF needs to be recompiled for that version.

This ability goes all the way back to the first Flash version. I am making the assumption this is based on major releases and not dot releases. I also assume that this is only for hacks that are not considered a security risk. I really wish I had a chance to ask about that… but my brain was full by the time the session was done.

How deep is deep?

One of the questions clients almost always ask is: “How deep is the Flash Player x.x penetration?”. If you go to the Adobe website you will see that Flash Player 9 has 93.3% of the mature market (as of Sept. 2007). Okay, but the trick is what about the .x? Does 9.0.47 really have 93.3%? When “Moviestar” (the newest player dot release code name) rolls out when will it have the full share of the pie? Jim and Lee dropped some great estimation numbers on us. These are based on the percentage of adoption from the release date of the new dot release (or player too).

@3 months = 30 – 40% @6 months = 55 – 65 @9 months = 80 – 85% @12 months = 90+%

What it gets down to is that if you need the newest dot release you need to consider the penetration estimates just like you would with a new full version update. For a great breakdown of how this works check out Emmy Huang’s blog about the topic (where I re-poached the values since I couldn’t type fast enough to get them all).

Okay, so that’s post one and I just scratched the surface… next up will be Byte Code, Control Tags, AVMs… oh my!

Update: Read Part Two: Byte Code, Control Tags, Renderers… oh my! Read Part Three: The ActionScript Virtual Machine Read Part Four: Just-in-time (JIT) compilation