Archive for 2008

Macworld 2009 Predictions

Tuesday, December 30th, 2008

Macworld 2009 is just 6 days away. It’s a Philnote instead of a Stevenote, and Apple’s last Macworld. Let’s get to it.

Apple Tablet | Netbook

  • Multi-touch one piece form factor - Sources, dating back to 2005, have spoken of a one piece form factor tablet running Mac OS X. The guts may have changed since 2004-2005, but the form factor is likely the same.

  • 720 x 480 screen - Widescreen for movie playback. Easy to source these components. The real question is pixel density, which depends on the form factor.

  • ARM + GPU processors - ARM processors are fast; more power efficient (longer battery life); can be supplied by multiple chip vendors including Apple’s new semi-conductor division; and Apple’s already got a OS X and app stack tuned for this form factor. A GPU is necessary for hardware accelerated web browsing and the graphics intensive apps and user experience. I’d love to believe that this is an Intel machine, but Apple and Intel’s partnership has been tentative this past year and with the chip division purchase, the roadmap seems clear.

  • OS X variant - If it has an ARM chipset, it won’t be full Mac OS X. Existing apps might work with a re-compile. It’ll play iPhone games, though. I could be wrong. Many things have pointed to sizing Mac OS X and iPhone OS X to converge, but I’d give it another 12 months.

  • $599 - Steve only shows up to earnings calls to spread dis-information (lie) and gauge market reaction (smart) prior to releasing new products. He did this for the iPod Nano, the iPhone, and he’ll do it again for the Apple tablet. “We don’t know how to make a computer for $500″. Fine. “All this for just $599″. (Plus a $699 upgrade)

  • Q1 2009 - Debunking today’s Fall 2009 timing rumor. Reliable sources at Apple also told me just prior to the iPhone 3G launch that it would not ship until 9 months later. They work on hardware, they cited realistic technical challenges getting a 3G chip in place. I’m betting it’s bunk.

  • Name? - iBook, MacBook Touch. No idea. Some combination of Mac, i, Book, Pad, or Touch. “Notepad” would be hilarious, but unlikely.

  • Is it a MacBook? - I’d like to call an audible on whether this is a full MacBook multi-touch notebook or an Apple tablet. An Apple tablet makes the most sense now. In 2005, this product was a full blown MacBook.

Mac Mini 3.0

Apple will merge Mac Mini and Apple TV together, dropping one of the lines.

Safari 4.0

  • 3D - Hardware accelerated 3D Web graphics with CSS Visual Effects. The specs exist, they’re implemented on iPhone, and definitely coming to Mac.
  • Video - You can already do alpha blended, transparent, reflected video playback on WebKit nightlies.
  • Speed - Benchmarks showing how much faster Safari 4 is over Safari 3 (also in a WebKit nightly near you).
  • UI - Apple is cooking some interesting UI upgrades, which I’m looking forward to.

One Last Thing

While this is a Philnote, I believe that the introduction of a major new product will still guest star Jobs.

Technorati Tags: , , , ,

Final Apple Macworld Keynote

Tuesday, December 16th, 2008

Whoa.

Apple® today announced that this year is the last year the company will exhibit at Macworld Expo. Philip Schiller, Apple’s senior vice president of Worldwide Product Marketing, will deliver the opening keynote for this year’s Macworld Conference & Expo, and it will be Apple’s last keynote at the show.

Link: Apple Press Release

Technorati Tags: , ,

Nokia Finally Answers the iPhone

Tuesday, December 2nd, 2008

When Lilia Martinez-Coburn, my colleague at hi5, first told me about the upcoming Nokia N97, I was skeptical. I’ll eat my words today.

Nokia is certainly rising to the challenge and seems to be on track to be a BMW to Apple’s Mercedes-Benz in the new “internet in your pocket” generation of mobile phones. Consider these key ingredients:

  • Cinematic UX - Finally, someone has successfully xeroxed Apple’s Core Animation’s GPU + implicit animation model and who better than Nokia. The implicit animation model is key in making great UX with minimal pain and bugs. I suspect the UX polish is focused on the main “phone top” idle screen, but it’s a great showing.
  • Web Browser - It’s WebKit and Nokia already has a decent port.
  • Industrial design - N97’s form factor is great. Nokia is no slouch when it comes to ID, and they’re very close here. N97’s a fair amount thicker, but not too shabby.
  • A twist - a physical keyboard and Flash + video support. Apple’s mobile web efforts have promise, but people sure do ask for Flash a lot.

But there are details that we won’t know until the N97 ships and are key to making sure Nokia doesn’t pull a “Prada”. Those are:

  • Performance - Touch interfaces need to have minimal to no latency. Graphics needs to be fast, and I have no doubt a GPU is sitting in that N97. Hopefully S60 5th Edition is up to speed here.
  • Software Ecosystem - Will Nokia provide an app store? Will there be refinements to S60 to let 3rd party developers finally make great apps? And can these developers make money? Nokia certainly is integrating with partners on the social networking front. But …
  • Nokia Maps? - Well, I’m certainly skeptical of Nokia’s ability to out innovate Google on mapping technology, but I wish them the best of luck. Competition is always good, and I hope Nokia finds the game changer in building their own mapping service.

I have two closing thoughts for now - 1) MacWorld is in January. I can’t wait to see that Apple tablet. 2) Finally, a new “internet communicator” with potential… though it hasn’t shipped yet.

2009 is going to be an interesting year.

Update: Additional coverage from Engadget, Robert Scoble, Gizmodo

Technorati Tags: , ,

Building CoverFlow for Safari on iPhone

Thursday, November 6th, 2008

Did you know that 3D graphics and animation is possible with Safari on iPhone?

If you have an iPhone, try out the CoverFlow (zflow) demo live with a live Flickr feed.

This CoverFlow demo is part of a new open source project I’ve started, CSS-VFX. The idea with CSS-VFX is to demonstrate all the cool things that are possible with Apple’s CSS Visual Effects extensions.

How does it work?

The zflow demo in CSS-VFX uses the Apple CSS Visual Effects extensions for hardware accelerated (on iPhone!) 3D perspective correct transforms and easily animated transitions. HTML 5 Canvas is used for simulating reflections.

  • zflow starts by loading each image from the images array. When each image is loaded, we scale the image to fit in a square region, and apply 3D CSS transforms to scale it in place.
  • Reflections - zflow then takes the scaled image and creates a Canvas element that contains a gradient alpha mask of the image’s reflection (using a “reflect” function to do this) and positions the canvas element in place.
  • Touch Controller - zflow creates a TouchController object, who’s job is to field touch events from Mobile Safari and calculate an appropriate offset.
  • Clicking - zflow detects when no move events have been made, and zooms + rotates the focused image forward by setting a “CSS Transition”ed 3D transform on the focused image. Clicking again transitions the image back.
  • Inertia - zflow achieves inertia by setting the “transition timing function” of the “tray” to an “ease-out” function, which slows things down. On the touch end event, we calculate the projected velocity and set the tray’s target position to that location. CSS Transitions handles the decay in velocity as the transition timing function executes — slowing the tray down gradually.

What’s next?

I hope that CSS-VFX can become a series of graphics gems that clearly illustrate how to use CSS Visual Effects, as well as talk about some of the corner cases and best practices to get the best performance. If you come up with something you’d like to include, please let me know. I’ll be tinkering with a few more gems myself, just watch the project for more as time goes on.

And tell a friend, I can’t wait to see what everyone else does with these great new features in Safari on iPhone.

Where to learn more

The CSS-VFX open source project is a good place to start. You can just use the zflow code in your own iPhone web pages (there’s docs on how to do that); and deep dive into the innerworkings of zflow to understand what exactly is going on.

Also, check out Apple’s proposed extensions: CSS 3D Transforms, CSS Transitions, and CSS Animation. They provide full specifications on what’s possible. Of course, there are a few gotchas when using these in practice, and I hope to document these as things progress.

Technorati Tags: , , , ,

SquirrelFish Extreme: Fastest JavaScript Engine Yet

Friday, September 19th, 2008

After reading the WebKit SquirrelFish Extreme announcement, I figured it’s time to revisit the JavaScript engine / web browser race once again.

In short: SquirrelFish Extreme is fastest by a whopping 35% over its nearest competitor, making WebKit the fastest browser once again. Let’s see how the numbers come out.

SunSpider Benchmark Comparison of JavaScript Engines

SunSpider running from the command line (to ensure the test is as pure as possible) was used for this test. My test system is a 2.4GHz iMac.*

These graphs are shown in runs per minute for clarity. Longer bars are better.

The raw timings are:

Detailed timings are linked above.

Of course, browsers are not purely executing JavaScript - DOM and rendering speeds are performance considerations as well. For this, we turn to Mozilla’s Dromaeo benchmark.

Dromaeo on Windows

As you can see, Firefox and WebKit smoke Google Chrome on this benchmark. WebKit comes out slightly ahead, so we need another benchmark to clear things up. Once again, Dromaeo, but on OS X now.

The full timings for these benchmarks are here:

Dromaeo on Mac OS X

Full timings for these benchmarks are here:

  • Firefox Nightly on OS X - 6648.20ms (Total)
  • WebKit Nightly on OS X - 4387.20ms (Total)
  • 2ec49a94393913f2d00d4ab3861e8a11 SquirrelFish Extreme wins this evolutionary cycle. Stay tuned for more coverage as Google, WebKit and Mozilla prepare their next moves. 453886ec046b4b6f8785cd363d9e6c9a Download and build WebKit trunk, Firefox trunk, and V8 trunk: Building SquirrelFish Extreme: from JavaScriptCore, make release Building V8: scons sample=shell Building Tracemonkey: from js/src, run make -f Makefile.ref BUILD_OPT=1 Run the SunSpider harness from WebKitTools/SunSpider: SquirrelFish Extreme: ./sunspider --shell=../../WebKit/WebKitBuild/Release/jsc V8: ./sunspider --shell=../../v8-edge/shell --args=-expose-gc TraceMonkey: ./sunspider --shell=../../tracemonkey/js/src/Darwin_OPT.OBJ/js --args="-j" 60879a65570ab03a81f7fb98b446ce26
    • The Windows benchmarks ran on different test hardware from the Mac OS X and engine benchmarks.

    Technorati Tags: , , , , , , , ,

iPhone - Just Like Developing For Nintendo

Sunday, September 14th, 2008

DOOM and GLOOM! The blogosphere is whining about Apple’s recent App Store rejections. (Surprisingly, even John Gruber.) Only Mikey has a contrarian view, but sadly always has Facebook on the brain.

Look, developing for iPhone is just like developing for a Nintendo console.

Nintendo owns the hardware. Nintendo owns the distribution mechanism. Nintendo doesn’t publish rules on what you can and cannot build.

And they do just fine. Many developers still develop great stuff for Nintendo DS and Wii. Why? It’s successful and profitable. And Nintendo is far more of a pain in the ass than Apple.

Common sense says: You’re not going to develop an Italian plumber 2D platform scroller for a Nintendo DS. Even if you were thinking about it, you’d talk to Apple about it first.

Should Apple get a free pass then? No.

Does this mean App Store is doomed? It hasn’t doomed Nintendo (not yet anyway).

Will Apple innovate over Nintendo and reverse their decision? Yes, and I’m sure it’s coming soon.

Technorati Tags: , , , ,

Skia Source Code Released

Tuesday, September 2nd, 2008

Hitching a ride on the Google Chrome / Chromium release today, the Skia graphics rendering engine that is the graphics heart of Android and Google Chrome (when there’s no GPU around) and part of the Skia acquisition was released today. Skia’s GL source code was briefly leaked in early 2007.

http://src.chromium.org/viewvc/chrome/trunk/src/skia/

Skia does have some similarities to Openwave’s (now Purple Labs) V7 vector graphics engine. (as they both come from Mike Reed’s companies) But that’s purely a coincidence, I’m sure. ;-)

If you’re doing work in mobile vector graphics or image rendering on constrained mobile devices, you really should check out the source code and have a look. Skia is quite elegant in its simplicity and power, a great combination.

Now if only we know how TAT worked …

Technorati Tags: , , , ,

WebKit, the New Linux

Tuesday, September 2nd, 2008

What do Apple, Google, Adobe, Nokia and RIM have in common?

WebKit.

WebKit is in iPhones, Android phones, Google Chrome, Mac OS X, Nokia S60, Blackberries, and Adobe AIR. For every tech gadget that the blogosphere drools over, WebKit is there.

And more hotness is coming.

These companies are fierce mobile sector competitors. Yet they all use WebKit. Linux is the only thing that even comes close to such widespread adoption in this sector.

That’s a big deal.

Now take a look at the members of the Android Open Handset Alliance. These companies are a who’s who in the mobile sector. KDDI. DoCoMo. Samsung. Motorola. Qualcomm.

That’s a huge deal.

Why? WebKit is smallest, fastest, simplest, and it’s an easily hackable browser kernel.

(Does that mean WebKit is the iPhone killer? (Wait a sec…))

And Google is about to contribute stuff to make it even faster. Gotta love that open source.

As for WebKit’s competitors?

Definitely Opera for now. Opera is a mobile juggernaut.

Perhaps Mozilla, once they have a browser core that’s small and simple enough.

I still have hope. The Mobile Web Wars would be pretty boring otherwise. ;-)

Technorati Tags: , , , , , ,

SquirrelFish is faster than Tamarin

Tuesday, June 3rd, 2008

WebKit and Tamarin Comparison

Smaller bars are better.

Wow.

I compared WebKit’s new SquirrelFish bytecode JavaScript interpreter against Tamarin, the JIT JavaScript engine currently in Flash 9 and in development for Firefox.

On the SunSpider JavaScript benchmark, SquirrelFish is at least 1.9 times faster than Tamarin with tracing turned on; 1.8 times faster than vanilla Tamarin, the same engine used in Flash 9. When you add type annotations to Tamarin (SquirrelFish doesn’t support them), Tamarin gets a little faster, but is still slower than SquirrelFish on these benchmarks.

Keep in mind, SquirrelFish’s reported times include source compilation, while Tamarin is executing pre-compiled bytecode outside the test.

First Impressions

  1. I can imagine the “performance per watt” power consumption for SquirrelFish is also much lower. Good for my iPhone’s battery life.
  2. I think I’m wrong about the importance of JITs. At least until SquirrelFish has gone through a few rounds of optimizations.
  3. ECMAScript 4 type annotations can clearly help in performance critical code, but most of the web executes in untyped, vanilla JavaScript.

Notes on my tests: Running SunSpider, tamarin-tracing, tamarin-central, and SquirrelFish all pulled from source on 2008-06-02. I ran the test on a 2.4 Ghz iMac. Raw numbers from the comparison runs are available here.

Running your own version of the tests

To reproduce these tests, build WebKit, build tamarin-tracing and tamarin-central from Mozilla.org, and install the Flex SDK for a bytecode compiler. Then,

  1. Set up your environment as follows: DYLD_FRAMEWORK_PATH="~/jsbench/WebKit/WebKitBuild/Release" ASC="~/jsbench/asc.jar" GLOBALABC="~/jsbench/tamarin-tracing/core/builtin_full.abc"
  2. Create a “timer.js” file that adds getTimer to the SunSpider benchmark: function getTimer() { return new Date(); }
  3. Create a “jscore” script that will run the original SunSpider AS source files instead of the ABC bytecode files: #!/bin/sh ~/jsbench/WebKit/WebKitBuild/Release/testkjs -f ~/jsbench/timer.js -f `echo $1 | sed s/abc/as/`
  4. And call the runtests.py script in the SunSpider test/performance sub-directory: ./runtests.py --avm ~/research/jsbench/jscore --avm2 ~/research/jsbench/tracing-avmshell ./runtests.py --avm ~/research/jsbench/jscore --avm2 ~/research/jsbench/central-avmshell

Technorati Tags: , , , , ,