Feeds

Google's JavaScript assassin: Web languages are harder than VMs

Dart daddy Lars Bak: JavaScript? I have no problem with it

Combat fraud and increase customer satisfaction

'I have no problem with JavaScript'

Bak reckons Dart is ideal for Gmail. Google's email service has 1MB of source code that must be read before starting, but Dart’s structure lets the VM take a snapshot that’s stored in the browser, which can be booted up in one-tenth of the time it takes to load the full code from scratch. “That’s hard to do in JavaScript because in setting up the program you have to execute the source code; that source code has side effects and those side effects cannot be snapshotted,” Bak said.

Dart helps on things like 3D gaming. A detailed structure of objects means the VM doesn’t have to take time running floating point connections to run new objects, which puts extra pressure on the garbage collector.

Bak now reckons Dart runs 30 per cent faster on Google's V8 than JavaScript under the Richards operating system kernel simulation benchmark and under the DeltaBlue benchmark – two standards used at Google. The goal is for Dart to become twice as fast.

Technology is one thing but overcoming the industry’s politics is a factor, too.

Bak's team has two hurdles to clear. Firstly, Apple, Microsoft, Mozilla and Opera will need to be convinced of the technical merits of Dart. But secondly, they will also need to be persuaded that Dart is not a cuckoo's egg that Google is trying to lay in their browser nests to take over the internet, that it's not a means to plonk them on a Mountainview roadmap or shoehorn them into helping Google’s search, advertising and web properties to the detriment of their own.

That memo on replacing JavaScript won’t help - it was strongly worded stuff. Googler Mark Miller in 2010 wrote: “The goal of the Dash [the initial name for Dart] effort is ultimately to replace JavaScript as the lingua franca of web development on the open web platform,” he said.

“This is not taking anything away from JavaScript... we have to make sure the web really competes well. With the mobile ecosystem we have to do a lot of innovation in the browser,” Bak said.

“While Dash is catching on with other browsers, we will promote it as the language for serious web development on the web platform," Miller continued in his October 2010 internal memo.

Google was promising to play nicely and be a good member of the JavaScript team, evangelising it in public for the next version of JavaScript – codenamed Harmony. Behind the scenes, though, it would evangelise Dash among web developers and browser makers and push for standardisation "and adoption across the board".

The memo leaked as Google revealed Dart at the Goto Conference in 2011.

Bak says Dart makes programmers more efficient for the web and notes that neither he, nor Google, has "a problem" with JavaScript. He points to his history on V8 as proof of his commitment - and Google's - to the language.

"This is not taking anything away from JavaScript... we have to make sure the web really competes well. With the mobile ecosystem we have to do a lot of innovation in the browser," Bak says. "I have no problems with JavaScript."

He does have a point: V8 helped push browser-makers in to competing on JavaScript rendering speeds, producing a battle of the benchmarks between 2009 and 2011 so tech companies could all claim to have the "fastest" browser on the web. Today, JavaScript is running faster in the browser than at any time.

V8 helped change the web development strategy of the world’s largest software company – Microsoft. As Mozilla and the WebKit team were working to become the fastest JavaScript engines on the web and Microsoft risked being branded the web's slowest browser, the kiss of death among devs who are the gatekeepers to what gets built and used in software.

C++ or ColdFusion - Dart's future

When Microsoft released IE9, it dumped more than a decade of history of forcing devs to build one version of their sites for Microsoft's browser and another version for everybody else. For its new browser, Redmond went with a standards-compliant and streamlined JavaScript engine, Chakra. Chakra helped Microsoft run that benchmark race.

Fate is a shifting force in programming languages. C++, Java and PHP are today riding high, but for how long? Others that were once big - such as ColdFusion from Macromedia and Adobe for rapid web application development - are now in terminal decline.

JavaScript was standardised as ECMAScript in 1997 - as ColdFusion was on the rise - but it was only within the last half decade that it come into its own. This is because devs were finally recognising JavaScript's power as a client-side language that came with the familiarity of C and Java, but without the problem - thanks to the ECMAScript standard - of being tied in to a single vendor's runtime or roadmap.

Now, there are moves afoot to extend it further on the server with Node.js.

Bak is confident Dart has a long future at the top and feels working for the internet's largest search and ad company will help propel it. Yet Dart must gain credibility inside and outside the Googleplex. It also remains in desperate need of a finished VM: the "snapshotting" that would allow Dart to spin up services such as Gmail more quickly than can be done in JavaScript is dependent upon the shiny new VM.

But, as we know, VMs are Bak's territory; it's languages that are tricky.

“Most people talk of a long adopt period – more than five years. We have working on this for two years and we already have good community. It looks pretty good, I’m very optimistic right now,“ Bak says. “This [Google] is the right place to do these projects.” ®

Combat fraud and increase customer satisfaction

More from The Register

next story
Ubuntu 14.04 LTS: Great changes, but sssh don't mention the...
Why HELLO Amazon! You weren't here last time
This time it's 'Personal': new Office 365 sub covers just two devices
Redmond also brings Office into Google's back yard
Next Windows obsolescence panic is 450 days from … NOW!
The clock is ticking louder for Windows Server 2003 R2 users
Half of Twitter's 'active users' are SILENT STALKERS
Nearly 50% have NEVER tweeted a word
OpenBSD founder wants to bin buggy OpenSSL library, launches fork
One Heartbleed vuln was too many for Theo de Raadt
Got Windows 8.1 Update yet? Get ready for YET ANOTHER ONE – rumor
Leaker claims big release due this fall as Microsoft herds us into the CLOUD
Microsoft TIER SMEAR changes app prices whether devs ask or not
Some go up, some go down, Redmond goes silent
Batten down the hatches, Ubuntu 14.04 LTS due in TWO DAYS
Admins dab straining server brows in advance of Trusty Tahr's long-term support landing
Red Hat to ship RHEL 7 release candidate with a taste of container tech
Grab 'near-final' version of next Enterprise Linux next week
prev story

Whitepapers

Mobile application security study
Download this report to see the alarming realities regarding the sheer number of applications vulnerable to attack, as well as the most common and easily addressable vulnerability errors.
3 Big data security analytics techniques
Applying these Big Data security analytics techniques can help you make your business safer by detecting attacks early, before significant damage is done.
The benefits of software based PBX
Why you should break free from your proprietary PBX and how to leverage your existing server hardware.
Securing web applications made simple and scalable
In this whitepaper learn how automated security testing can provide a simple and scalable way to protect your web applications.
Combat fraud and increase customer satisfaction
Based on their experience using HP ArcSight Enterprise Security Manager for IT security operations, Finansbank moved to HP ArcSight ESM for fraud management.