Expert to Expert - Erik Meijer and Lars Bak: Inside V8 - A Javascript Virtual Machine
- Posted: Apr 29, 2009 at 9:29 AM
- 58,829 Views
- 19 Comments
Loading User Information from Channel 9
Something went wrong getting user information from Channel 9
Loading User Information from MSDN
Something went wrong getting user information from MSDN
Loading Visual Studio Achievements
Something went wrong getting the Visual Studio Achievements
Right click “Save as…”
Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation,
please create a new thread in our Forums,
or
Contact Us and let us know.
Follow the Discussion
Oops, something didn't work.
What does this mean?
Following an item on Channel 9 allows you to watch for new content and comments that you are interested in. You need to be signed in to Channel 9 to use this feature.What does this mean?
Following an item on Channel 9 allows you to watch for new content and comments that you are interested in and view them all on your notifications page.sign up for email notifications?
Good to see the good ol javascript is still alive and kicking and to see people still developing and optimizing for it.
And Erik is as always excellent,.. nice shirt again Erik
You shouldnt mix all those colors in the washer
That is neat. Perhaps Microsoft will adopt V8 for their gadget engine in Windows or perhaps even IE?
Lars is an engineer's engineer. The work he has done is impressive and more than worthy of an appearance on C9's Expert to Expert regardless of the fact that he works for a competitor in the industry...
Perhaps you think Channel 9 is just Microsoft Marketing?
C
Go Obama....err Charles !
It's not change.
I like to believe Channel 9 has always been this way.
On the flip side, at one point Lars said why not compile F# to C#, instead of MSIL. I say you are then hampered by the semantics of C#. Quite a few functional languages compile to C and they all suffer from the tailcall problem and have to generate really unnatural C code (the well-known "trampoline" solution). One advantage of an IL is it can expose features that higher-level languages do not. C# has no concept of a "tailcall", but IL allows it.
Another argument is that an IL is really an "API ", just a weird one. Programs on either side of the API can change, but as long as the API and its behavior is stable, they can change independently. The same would be true if you generated C# but I would argue that is the kind of API I don't want to code to.
Anyways, great discussion as always!
p.s. Erik how can you say only Haskell compilers are written in pure Haskell? For shame!
it would have been really interesting to hear what lars thougt of the DLR and sort of what the differences are (some are obvious ofcourse but you know what i mean) maybe if google doesnt throw lars in a dungeon somewhere for talking about this stuff, you could invite him back and have an E2E with jim hugunin
conceptually this interview is really awsome. a guy from google is on a microsoft community site talking about the internals of one of chromes most touted features
slightly of topic, who shot this by the way? charles you where standing of the the side, yet the camera panned to you, so someone else had to be shooting.. or did eric movie it using only his mighty brainwaves?
C
C
Fun discourse. Debate is a great part of conversation - otherwise it's just an hour of bobbing heads and smiling faces. Boring...
C
if(point.class == Point){ // it's a point so the x component is the first in memory return point[0]; }else{ // use the slow path for other objects location = point.class.lookup("x"); return point[location]; }Is this how V8 does attribute lookup? Does V8 adapt this generated code at runtime? What happens with this code: Will this check the point class twice, or is V8 smart enough to check it only once?Other than that it was really interesting.
wow damn good and smart discusion. Even though I am a layman, the discusion on validating @ source code level sound+seem damn cool.
As a layman, I am wondering will V8 be optimized for other scripting language? If they do that will chrome be as huge as an OS? anyway maybe we do not even need a browser application anymore. Too bad there are many political issues to settle if that is to become a reality in the desktop world (hope the mobile world will be free of that ^^).
Erik and Charles are sharp and smart.
I also like Justin comments on IL being a weird API.
Keep up all the good work Channel 9 and all the computer science geek. Cheers.
============================================================================
(XML--> learn --> produce / transform New XML --> learn --> produce or transform New XML .... oh no!!!)
Towards the end of the talk, there was some discussion about the decision to compile JavaScript directly to machine code versus using an intermediate bytecode/language.
I think that one of the biggest differences in this case is the nature of how JavaScript itself is usually deployed and executed by clients. Being that V8 is targeted toward executing JavaScript that is usually already deployed somewhere on the web, it must expect that its input is JavaScript code. For better or for worse, JavaScript code is what is living out there on the web, and not some intermediate bytecode/language.
If there was more upfront control regarding the development and deployment of the code itself, it would probably make more sense to use some intermediate bytecode/language. I think that the big advantage to using an intermediate bytecode/language is not so much for the virtual machine, but really for the developer's experience while creating the code itself. It allows for easier/faster syntax checking, IDE features (code navigation, auto completion, etc), and to some extent can hide implementation details from an end user when it is deployed remotely.
Anyway, although this work is no doubt interesting, I can't help but wonder why we aren't pooling our efforts into generalizing more mature virtual machines (such as the JVM, etc.) instead of creating new and specialized ones like V8. The open nature of some VMs, such as the JVM, allow them to be slimmed down, generalized, and then tuned for different execution profiles (Java Server, Java Client, JavaScript, Python, etc), yet still take advantage of all the work that has already been devoted to these projects.
easily one of the most interesting chats i've seen for a long time - i love this level of conversation and would really like to see more of this kind of interaction between ms and google here or elsewhere.
ms _is_ doing very interesting research projects - google _is releasing_ very interesting research projects. i want the research arm of ms take more of a lead in actual production systems . it's abundantly clear that we would all benifit from ms sales keeping out of what makes it to production.
Remove this comment
Remove this thread
close