Am 24.01.2012, 16:41 Uhr, schrieb F i L <[email protected]>:
Stewart Gordon wrote:
Moreover, it seems that getting a new scripting language implemented in
web browsers isn't going to be easy. But it seems that language-to-JS
compilers would work as long as the language's concepts are readily and
efficiently implementable in JS.
Stewart Gordon wrote:
Moreover, it seems that getting a new scripting language implemented in
web browsers isn't going to be easy. But it seems that language-to-JS
compilers would work as long as the language's concepts are readily and
efficiently implementable in JS.
Problem with efficiency is, in the best of cases, Javascript is 15-30x
slower than native C code; and only after a lot of fine-tuning and on
the newest browsers. Modzilla and Google engineers have been hacking
away at performance issues for years, but the problem is Ecmascript's
spec is the real limiting factor. The spec does update, but when major
browsers vendors like Microsoft simply ignore implantation proposals
(like SVG) and fight against spec improvements (like Ecmascript 4.0) new
features can hardly be used at large, considering 30-40% of web traffic
is still Internet Explorer.
This is why I mentioned Google's Native Client (NaCL), which if you
don't already know, is a *plugin* for running sandboxed native code (@
95% efficiency) over the web with the same security limits as
Javascript. The world needs Operating Systems that work like browsers
IMO, and I think D would fit in nicely here.
I find the performance not so much the limiting factor as the lack of
compact arrays to cache data. My JavaScript applications quickly become
RAM hoggers. I'm not so keen on turning browsers into operating systems
though. It is very difficult on the one hand to write such a browser,
which shrinks the market, and we already have a good selection of
operating systems and desktop environments, together with transparent
storage of personal data, temporary files and configuration. Not to
mention installers/uninstallers and the rest of the software
infrastructure. Sun invented Java Web Start. Isn't that a technology that
can serve the same purpose, without running the application in a browser
tab?