×

Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

The Next Browser Scripting Language Is — C?

ScuttleMonkey posted more than 5 years ago | from the a-home-for-all-of-that-old-code dept.

Programming 375

mad.frog writes to tell us that in a recent talk by Adobe's Scott Petersen he demonstrated a new toolchain that he has been working on (and soon to be open-sourced) that allows C code to be run by the Tamarin virtual machine. "The toolchain includes lots of other details, such as a custom POSIX system call API and a C multimedia library that provides access to Flash. And there's some things that Petersen had to add to Tamarin, such as a native byte array that maps directly to RAM, thereby allowing the VM's "emulation" of memory to have only a minor overhead over the real thing. The end result is the ability to run a wide variety of existing C code in Flash at acceptable speeds. Petersen demonstrated a version of Quake running in a Flash app, as well as a C-based Nintendo emulator running Zelda; both were eminently playable, and included sound effects and music."

cancel ×
This is a preview of your comment

No Comment Title Entered

Anonymous Coward 1 minute ago

No Comment Entered

375 comments

Browser-based OS (4, Funny)

rustalot42684 (1055008) | more than 5 years ago | (#24087597)

Now we can finally get this "web operating system" thing I've heard so much about...

Re:Browser-based OS (1)

Darkness404 (1287218) | more than 5 years ago | (#24087637)

And perhaps this will make open-source web apps possible and needed.

Re:Browser-based OS (0)

rustalot42684 (1055008) | more than 5 years ago | (#24087671)

well, it says it's going to be "open-sourced" but it's not clear that that even means anything because afaik it's based on flash.

Re:Browser-based OS (2, Informative)

rustalot42684 (1055008) | more than 5 years ago | (#24087709)

Er, disregard that, I was wrong

Re:Browser-based OS (-1)

Anonymous Coward | more than 5 years ago | (#24088327)

best karma whore i've seen in a while. make an incorrect post, then reply to yourself saying you were wrong and get modded informative on both of them. well done sir, well done.

Re:Browser-based OS (1, Informative)

trolltalk.com (1108067) | more than 5 years ago | (#24088393)

It's not a browser-based OS - it's just a mapping of c source code to an interpreter running in flash.

So it will be slowwww. In other words, it will turn your dual-core into a 386.

Also, who the f*ck puts black text on a dark-brown background? If you don't want us to read the article, just say so ...

Re:Browser-based OS (1)

Darkness404 (1287218) | more than 5 years ago | (#24087923)

Well, I was talking about the C applications not the framework they are based on.

Re:Browser-based OS (2, Insightful)

rustalot42684 (1055008) | more than 5 years ago | (#24088045)

Right, I got that. My point was that it's not really a very good idea to build open-source programs which are dependent on some proprietary library/toolkit/framework/etc, especially when the proprietary part is very large and complex (eg Java), or when a free alternative exists but the original remains patent-encumbered (Mono). If the underlying framework is proprietary, the freedom of the other software is made irrelevant by the fact that the owners of the framework have total control over it. Things can resolve themselves, however; see the KDE free Qt foundation as an example.

Re:Browser-based OS (5, Informative)

Hairy Heron (1296923) | more than 5 years ago | (#24088485)

especially when the proprietary part is very large and complex (eg Java)

You're about 3 years out of date on calling Java proprietary, kiddo. In case you forgot, it's been GPLed for over a year now.

Re:Browser-based OS (5, Insightful)

Hatta (162192) | more than 5 years ago | (#24087875)

Well this just underscores how silly the whole web-application thing is. An application running on a browser is a silly idea for the same reason an OS running on a browser is. We already have operating systems to run programs on. Give us native programs, not some horrid mishmash of technologies.

Re:Browser-based OS (4, Insightful)

Yold (473518) | more than 5 years ago | (#24088035)

What the hell are you talking about? Web applications have some really good uses in the real-world (read business world). Instead of updating every computer in the office with a new version of some data management app, it is deployed once.

Native programs are optimized for speed, Web Applications are optimized for Rapid Application Development. Remember visual basic? Thats what web apps do nowadays, and trust me, its better.

As for "your horrid mishmash of technologies" statement, I agree that AJAX is overused, but believe me it is very nice to be able to do stuff on the server side (think form validation), and then not have to redo on the client-side in javascript.

Re:Browser-based OS (4, Insightful)

rustalot42684 (1055008) | more than 5 years ago | (#24088187)

Instead of updating every computer in the office with a new version of some data management app, it is deployed once.

Or you could have a sensible package system which does updates (eg, one of the Linux package managers), or have the program itself do the updates (eg, Firefox). Your problem is solved.

A commonly mentioned benefit of web apps is portability, but this isn't really true either because of the variety (and inconsistency) of web browsers. What I think is a better approach is something like the solution we see with Qt, where you write your program once, then compile it for different platforms, and it looks native every time. You get the speed and the portability and the UI consistency and the tech support only needs to support one program.

I agree with you, however, that web apps are the new Visual Basic. They're slow, crappy, and often insecure.

Re:Browser-based OS (0, Redundant)

Yold (473518) | more than 5 years ago | (#24088479)

There are some very talented web-developers, and there are some very intuitive web applications. But yes, there are many slow, crappy, and insecure ones out there too.

Linux doesn't work well in the business world for ordinary users. Trust me. It doesn't. They need stuff that is windows only.

Prototype solves a lot of the DOM incompatibilities between IE/Firefox.

My point is, web apps do RAD very well. Native apps give you flexibility. But such flexibility is not required for run-of-the-mill data management apps. I don't want to write something to manage updates, the very nature of a web app eliminates the need to do that. If I am going to write something at home, I'll do it in C. But I'd rather do a project as quickly as possible, it gives me more time to post on Slashdot ;)

Re:Browser-based OS (3, Insightful)

Hatta (162192) | more than 5 years ago | (#24088213)

Web applications have some really good uses in the real-world (read business world). Instead of updating every computer in the office with a new version of some data management app, it is deployed once.

Oh come on, it's not that hard to push an application onto every computer in the office. This is a cop out.

Native programs are optimized for speed, Web Applications are optimized for Rapid Application Development. Remember visual basic? Thats what web apps do nowadays, and trust me, its better.

Then use python with wxwidgets or something. Every bit as easy and portable, a lot faster and safer.

As for "your horrid mishmash of technologies" statement, I agree that AJAX is overused, but believe me it is very nice to be able to do stuff on the server side (think form validation), and then not have to redo on the client-side in javascript.

Frankly, you should be doing everything on the server side.

Re:Browser-based OS (5, Insightful)

Yold (473518) | more than 5 years ago | (#24088351)

#1, Yes, it is hard to push out an application to every University computer when you are at one w/ 50,000 students.

#2, see #1

#3, everything is done on the server-side, and prior to AJAX, it was redone in Javascript on the clientside for a more responsive user interface. Now, both the client and server use the server-side procedure.

Re:Browser-based OS (1)

hitmark (640295) | more than 5 years ago | (#24088505)

or one could go back to big irons, and issue the work force wifi/3G equiped "terminals"...

Re:Browser-based OS (4, Funny)

Anonymous Coward | more than 5 years ago | (#24088065)

You need an operating system to run programs? Bah! Real programmers aren't afraid of programming directly to the hardware.

This whole operating system fad won't last. Who wants to waste so many resources just to simplify development and portability? If we don't stop this operating system fad quickly, the next thing you'll see is people developing virtual machines so that girly programmers won't have to have to test their applications across various platforms. And then they'll start integrating these virtual machines into normal applications! What are they thinking? That memory and processor speeds are growing exponentially?

Re:Browser-based OS (4, Funny)

sjames (1099) | more than 5 years ago | (#24088431)

Sonny, back in the day we didn't need a machine to test our code. We ran it in our heads as we punched it into the cards. Sure, there were a few new guys who used pencil and paper to help them, but if they didn't shape up in a month or so, we ran them out of the industry.

Now get off my lawn!

Re:Browser-based OS (1)

peragrin (659227) | more than 5 years ago | (#24088123)

Oh come on now can't you see the money flow.

MSFT can charge for Vista and Internet Explorer separately.

Of course the question one has to ask if a browser that is free can run applications as well as the underlining OS can what purpose does the OS serve?

The secret to network aware applications is to move them to the browser? guess that is one way to push standards.

Re:Browser-based OS (5, Insightful)

bestinshow (985111) | more than 5 years ago | (#24088175)

Not really. I do agree that native applications are nicer than web applications, especially if you compare, e.g., Google Docs to Office, or even WordPad.

However what we have discovered is that (1) web applications are easier to write, and (2) it's nice having a consistent platform to develop to, even if that platform is mildly ridiculous (HTML + CSS + JavaScript + Browser-Workarounds + JavaScript canvas thing). Getting stuff to display and layout on this platform is easy, and simple to prettify, far easier than most native platforms have been in the past. There are also a dozen different ways to write the server side of things, and I think for many developers it is nice to be forced to split up the client interface from the meat of the system.

Of course, things are going too far. What should be happening is the simplification of native application programming, with a common platform, etc, without the overhead of having to run a Javascript or HTML rendering engine, and native full-speed canvases. I think that Apple is getting there, QT and KDE4 may be getting there but I haven't really looked into that platform. Java should have gotten there but early design mistakes (AWT, Swing) have killed that off, and SWT is a last-generation UI library. Maybe something like Fenggui on Java might help this platform, but I think Java's dead on the home desktop (and extremely alive and profitable on the server).

Re:Browser-based OS (5, Funny)

Whatanut (203397) | more than 5 years ago | (#24088103)

If you run a browser based OS... and install a browser in it. And then use that to run a browser based OS, why... we could have infinite amounts of computing power! Or space time will tear itself apart. Either way, I'm making popcorn.

Re:Browser-based OS (1)

ultranova (717540) | more than 5 years ago | (#24088299)

Now we can finally get this "web operating system" thing I've heard so much about...

Well, Linux is written in C, so...

And once we have C... (5, Funny)

Anonymous Coward | more than 5 years ago | (#24087631)

We can write PHP! And then browser security will be top notch.

Sound and Music? (1)

malfist (1152363) | more than 5 years ago | (#24087677)

Is it just me but isn't music also sound effects?

Re:Sound and Music? (4, Informative)

2nd Post! (213333) | more than 5 years ago | (#24087739)

Nope. SFX is generally event driven (hit a key, hear the sword swing) where music is not (enter an area and music plays continuously in the background).

SFX requires timing, latency, and speed to be accurate. Music requires bandwidth and a minimum level of continuous CPU cycles.

Both have different needs so you can have one without the other (when you are talking emulation).

Guitar Hero and Lumines (4, Informative)

tepples (727027) | more than 5 years ago | (#24087993)

Nope. SFX is generally event driven (hit a key, hear the sword swing) where music is not (enter an area and music plays continuously in the background).

SFX requires timing, latency, and speed to be accurate. Music requires bandwidth and a minimum level of continuous CPU cycles.

Both have different needs so you can have one without the other (when you are talking emulation).

In Parappa the Rapper, Beatmania, Guitar Freaks, Drummania, Keyboard Mania, Frequency, Amplitude, Taiko Drum Master, Donkey Konga, Guitar Hero, Rock Band, and even scenes in the Mario Party and WarioWare series, the player triggers sound effects at specific times, and these sound effects represent music that the player is performing. If the background music becomes desynchronized from the sound effects that represent music, the emulated environment becomes unusable. Even games that aren't directly about performing music, such as Rez, Lumines, and some scenes in Super Mario RPG, indicate the timing of various game world events using the music.

Re:Sound and Music? (0)

Anonymous Coward | more than 5 years ago | (#24087759)

Not to get too off topic, but no. There are different mechanisms in an average game engine to constantly stream a sound (i.e. music) and to do event based, often environment affected sound (sound effects).

what? (5, Funny)

thermian (1267986) | more than 5 years ago | (#24087687)

You mean my preferred language has just become cool?

Ok, this is either great news or the world is about to end.

I think I'll go stand in a doorway for an hour or two, just to be on the safe side.

Re:what? (5, Funny)

eviloverlordx (99809) | more than 5 years ago | (#24087779)

I heard that COBOL is next on the TODO list.

Don't laugh. (0)

Anonymous Coward | more than 5 years ago | (#24087901)

I heard that COBOL is next on the TODO list.

Don't laugh too hard. All those COBOL guys are retiring now and there's still a shit load of stuff out on COBOL - including NEW software. COBOL guys aren't hurting, that's for sure.

Re:what? (0)

Anonymous Coward | more than 5 years ago | (#24088231)

if they announce turbo pascal is next, i'm gonna shit.

Re:what? (0)

Anonymous Coward | more than 5 years ago | (#24088359)

I heard that COBOL is next on the TODO list.

Ha.

Re:what? (4, Interesting)

dgatwood (11270) | more than 5 years ago | (#24088121)

I'd use C for everything if its string handling weren't so utterly broken. It makes sense from a pure performance, near-the-hardware perspective to handle strings the way it does, but what is desperately needed is POSIX standardization of stracat/stracpy. That one change would make it trivial to eliminate 99% of all buffer overflows in typical apps (and, ideally, kernel code)....

char *stracpy(char *src)
Returns a copy of a string in a newly allocated buffer large enough to hold the result.
char *stracat(char *string1, char *string2 ...)
Returns a newly allocated string that contains the concatenation of two or more strings.

Sure, I could write my own, and pretty much everybody on the planet has done it at least once in their lives, but it seems ridiculous that such obvious operations require hand holding. Outside of embedded platforms where malloc is expensive, dynamically allocating a new buffer for concatenations should be the norm. For situations where performance takes a big hit because you can't afford to copy the source string every time, you could also add this API:

strbuf_t strbufalloc(char *src [, size_t size_hint])
Returns a copy of a string in a newly allocated buffer large enough to hold the result. The optional second parameter size_hint allows you to specify a suggested size for the buffer.
strbuf *strbufcat(strbuf_t string1, strbuf_t string2 ...)
Returns a newly allocated string that contains the concatenation of two or more strings. The value of string1 must be a string buffer (strbuf_t). The value of string2 may be either a strbuf_t or char **.

Wherein strbuf is opaquely defined as:

struct strbuf_private {
char *content; // null-terminated string
size_t length;
void *private_history_data;
};

struct strbuf;
typedef struct strbuf *strbuf_t;

and the routines automatically realloc the internal char * buffer as needed to grow the size to hold incoming content and likely future content based on historical data about prior operations on the structure, the algorithm for which would be an implementation detail outside the scope of the standard. That said, for the rare cases where a simple copy hurts performance badly enough for most folks to care, chances are your application knows its own growth policy better than the OS could guess anyway, so you probably should just roll your own buffer management code. The important bits to add to the standard are those first two functions (stracpy and stracat).

Re:what? (0)

Anonymous Coward | more than 5 years ago | (#24088225)

Also, may I just say that wow, the Slashdot CSS for dl/dt/dd is broken horribly....

Internet-C reborn? (3, Interesting)

dyfet (154716) | more than 5 years ago | (#24087689)

There used to be a project, many years ago, which was I believe called itself something like "Internet-C". It used gcc with a pseudo-code backend to produce portable binaries which could then be ran from a plugin or through an emulator. Since gcc was tuned for register based archectures and 68k was already an existing backend, I think the pseudo-machine code he used was based at least loosely on the 68k one.

Re:Internet-C reborn? (1)

twiddlingbits (707452) | more than 5 years ago | (#24087879)

I did some work back in the early 80's where I wrote a benchmarking algorithm in C then used gcc to generate intermediate code then ran the intermediate code thru another tool to produce binaries for X86, 68K and PowerPC architectures. It all ran under VxWorks for an OS so I didn't need an emulator and it wasn't on the bare hardware either. Pretty nifty stuff at the time, we had DoD funding to look at the performance of commercial chips versus the 1750 processor and C versus Ada. IIRC, a lot of this work helped baseline the processor and language choices for the JSF avionics suite. Stuff we got now runs rings around this.

Right... (1, Troll)

Colin Smith (2679) | more than 5 years ago | (#24087697)

You realise that all the OS layers, networking layers, web browsers, scripting languages are primarily to try to get away from C?

 

Re:Right... (0)

Anonymous Coward | more than 5 years ago | (#24087749)

And now we are free to cast them aside and return to our love of allocating our own memory.

Re:Right... (5, Insightful)

Nyall (646782) | more than 5 years ago | (#24087797)

primary? ummm... I thought the primary point of layers is so that you can do a lot with only a few simple function calls

Re:Right... (1)

HolyCrapSCOsux (700114) | more than 5 years ago | (#24087805)

How so? That's like saying sushi bars are there to try to get away from fishing.

Re:Right... (4, Insightful)

camperdave (969942) | more than 5 years ago | (#24087961)

How so? That's like saying sushi bars are there to try to get away from fishing.

Well, it must work because I've never had to catch a fish to eat sushi.

Re:Right... (0)

Anonymous Coward | more than 5 years ago | (#24087833)

Which simply means that we can't.

This confirms it C is Death! (3, Funny)

SmallFurryCreature (593017) | more than 5 years ago | (#24087849)

The more you run away from it, the closer you get to it. So now things are as inevitable as Death, Taxes and C.

A frightful three-some indeed.

Re:Right... (1)

gbjbaanb (229885) | more than 5 years ago | (#24087885)

yeah, and look at the mess that happens when you make a language so easy to use a web designer starts to code with it :-)

Oh, and all those OS layers, networking layers, web browsers and scripting languages are written in C. It must have something going for it.

Re:Right... (3, Informative)

twiddlingbits (707452) | more than 5 years ago | (#24087943)

And you realize all the overhead this created? It's why we needed dual core 3GHz 64 bit processors. C code, properly written is very tight and fast. Too many layers complicates the issue and introduces more chances of error. If you are looking inside Unix you'll find out the OS is written in C (and some assembler). You can have a GUI/Windows and still have C code..it's called X/MOTIF and has been around a long time, works well and is very fast. I'm pretty sure the current Linux GUIs owe a lot to to Motif.

Crazy thoughts..... (3, Interesting)

jmorris42 (1458) | more than 5 years ago | (#24088241)

> You realise that all the OS layers, networking layers, web browsers,
> scripting languages are primarily to try to get away from C?

So? You are missing the bigger point. All of those layers and scripting languages you speak of are written in C. So C working in Flash means all of that other stuff can be brought over. Perl + Flash? Python + Flash? Ruby? The mind boggles at the possibilities.

Of course since nobody will want to stuff all of Perl + half of CPAN down the pipe every time an applet loads we will end up with predownloaded versions cached for use. Let the package war begin, will flash binary packages be maintained with .deb or .rpm... I can see Windows users fighting Package Kit or Synaptic to manage the cruft needed so that "web apps" can work. We could end up with an entire GNU/Flash[1] distribution lurking on every Windows PC.

[1] I object to the GNU/Linux misnaming abomination but this time it really will be a "GNU" distribution since Linux won't be involved. At least until we get a formal 'distribution' being shipped by Adobe.

Re:Right... (1)

internerdj (1319281) | more than 5 years ago | (#24088489)

Well the next step is C++ and Java. Then we can write OS layers, networking layers, web browsers, and scripting languages that run on top of OS layers, networking layers, web browsers and scripting languages because RAM is now cheap...

Adobe is almost as innovative as Microsoft (0)

Anonymous Coward | more than 5 years ago | (#24087723)

Adobe just invented CGI! Good work, guys.

Security? (0)

Anonymous Coward | more than 5 years ago | (#24087725)

in other news, the amount of spyware-infected computers increased by 500%

Where did they get the Zelda on PC? (4, Insightful)

Anonymous Coward | more than 5 years ago | (#24087753)

Is that a pirate copy? Just curious...

Re:Where did they get the Zelda on PC? (1)

PlatyPaul (690601) | more than 5 years ago | (#24087939)

Well, according to Nintendo [nintendo.com] , it must be [nintendo.com] .

Also feel free to check this out [northwestern.edu] . It's not fantastic, but it's not bad.

Re:Where did they get the Zelda on PC? (1)

howdoesth (1132949) | more than 5 years ago | (#24088337)

So according to Nintendo, the "rightful owner of an authentic game" is entitled to have a copy to protect against damage or loss, but a Game Copying Device is inherently illegal because the copies it makes can be uploaded to the internet? Where is the legal backup copy supposed to come from? Will they give you a second cartridge if you ask nicely?

Re:Where did they get the Zelda on PC? (1)

tiananmen tank man (979067) | more than 5 years ago | (#24088509)

Most likely by buying the handheld console, the game and a flash cart to dump the game. Where in that process is anything illegal done?

Wow.. (1)

spiffmastercow (1001386) | more than 5 years ago | (#24087757)

I can't believe it.. An idea for a web programming environment that would make me hate web programming slightly less.

Re:Wow.. (0)

Anonymous Coward | more than 5 years ago | (#24087867)

You insensitive clod. Now they'll have to abandon development :(

am I the only one bored with the software world? (5, Insightful)

Anonymous Coward | more than 5 years ago | (#24087765)

Everything's being constantly reinvented but no actual progress is being made. Oh look, the 100th toolkit to do exactly the same thing! Oh look, a new way of layering something old on something old on something old to give something new! Oh look, another silver bullet framework!

Can anyone here remember the web of 10 years ago, for example? Content = text for reading + graphics for illustration. No bullcrap, just Google/Wikipedia style web sites to give me a simple navbar + content.

Re:am I the only one bored with the software world (0)

Anonymous Coward | more than 5 years ago | (#24088283)

Everything's being constantly reinvented but no actual progress is being made. Oh look, the 100th toolkit to do exactly the same thing! Oh look, a new way of layering something old on something old on something old to give something new! Oh look, another silver bullet framework!

Can anyone here remember the web of 10 years ago, for example? Content = text for reading + graphics for illustration. No bullcrap, just Google/Wikipedia style web sites to give me a simple navbar + content.

Hear! Hear! The best websites have nothing but text. Your comments are excellent, never mind the slashdot moderation/censorship system - I know how to get around it, found your comment, read it and appreciated it greatly. You are not the only one who thinks this way.

Re:am I the only one bored with the software world (1)

LilGuy (150110) | more than 5 years ago | (#24088493)

I also remember waiting 5 minutes for a picture to download...

I don't mind having nice looking sites because it takes just as long for one of them to load as it does for a plain text site anymore.

However, people have shifted more toward flashiness than content which I don't particularly like.

You insensitive 3lod! (-1, Offtopic)

Anonymous Coward | more than 5 years ago | (#24087775)

Wisnd0ws, SUN or

But is it secure? (4, Informative)

Animats (122034) | more than 5 years ago | (#24087777)

If the "byte array mapped to RAM" installed in Tamarin allows the code to store anywhere in the interpreter's space, that's a huge security hole. It can do anything the user process can do. If you're going to allow that, you may as well just load executable machine code directly, as with Active-X.

Anyway, the article is a blog post that rehashes an interview from last year. [digitalbackcountry.com] The info in that article is better.

Re:But is it secure? (5, Insightful)

ergo98 (9391) | more than 5 years ago | (#24087893)

If the "byte array mapped to RAM" installed in Tamarin allows the code to store anywhere in the interpreter's space, that's a huge security hole. It can do anything the user process can do. If you're going to allow that, you may as well just load executable machine code directly, as with Active-X.

You should email them and tell them about this! Surely they haven't though of such a thing!

Sarcasm aside (sorry, I couldn't help myself), I suspect the VM needs to actually hand you a block of memory, and on accesses it validates that it is within the VM allocated range. Anything less would be silly, however such a thing would provide a huge win (I've tried to do image editing in pure managed code, and then found a massive performance win switching it over to P/Invoke native code).

Re:But is it secure? (1)

Yold (473518) | more than 5 years ago | (#24088111)

Exactly what I was thinking. There isn't much space to compromise between the security of Java applet, and the speed of an Active-X plug-in. So this is basically a cross-platform version of Active-X; I am sure that will make many system administrators happy, especially the ones that grant their OS X users admin rights, thinking they are safe =) from web-installed rubbish.

Am I the only one feeling... (0)

Anonymous Coward | more than 5 years ago | (#24087815)

...that this is our doom?

Purpose? (3, Insightful)

roman_mir (125474) | more than 5 years ago | (#24087837)

This is an interesting hack but it does not do anything for improving either computational theory or improving web application development. Combine C arrays that can be coded within a page like Javascript with a web-browser's security model and you get yourself what exactly? Is this going to improve the speed of development, the security of a thin client, the stability of a browser, the ease of memory usage, the consistency of interfaces or reusability of code? Certainly there will be more features available to a browser client but will there be enough abstraction between the machine and the code to avoid having major security/consistency problems?

It is just not clear to me right now whethere there is a purpose to this beyond satisfaction of an interesting hack.

He's out of jail? (-1, Offtopic)

Anonymous Coward | more than 5 years ago | (#24087839)

So Scott Peterson is out of jail and working for Adobe?

Ah, the Memories... (5, Insightful)

Tickenest (544722) | more than 5 years ago | (#24087843)

Petersen demonstrated a version of Quake running in a Flash app, as well as a C-based Nintendo emulator running Zelda; both were eminently playable, and included sound effects and music.

So Flash can simulating computing as it was back in 1998? Super....

Very good (1)

gweihir (88907) | more than 5 years ago | (#24087853)

So the language for ''real men'' will not die out! All those kids playing with their scripting or byte-code should watch out!

Seriously, I like Perl and Python. But some things, expecially real-time stuff like audio and video are not for scripting.

Re:Very good (1)

X0563511 (793323) | more than 5 years ago | (#24087911)

Use scripting/interpreted stuff for some things, and for the time-critical use 'bindings'. We do that already. Python-OpenGL - python itself isn't rendering the tris... that would (indeed!) be quite silly.

Re:Very good (1)

tepples (727027) | more than 5 years ago | (#24088297)

Use scripting/interpreted stuff for some things, and for the time-critical use 'bindings'. We do that already. Python-OpenGL

What do you use to decompress textures, read controllers, play sounds, or do any other signal processing or I/O that the Python standard library and OpenGL don't handle by themselves? You have to find or write a C extension, and then you have to port it to each platform that you plan to support.

Adobe Systems != Open Source (5, Informative)

mpapet (761907) | more than 5 years ago | (#24087859)

The last time I checked, Adobe Systems is about as hostile to open source as possible. They are the seldom acknowledged masters of the "first hit on the crack pipe is free" scheme.

http://labs.adobe.com/technologies/eula/air.html [adobe.com]

Multiple helper libraries licensed under the MPL doesn't change the fact they are promoting another information silo.

I can already C the future (sorry 4 pun) (1)

caywen (942955) | more than 5 years ago | (#24087925)

I get it! So, now we have interpreted C, and it's (relatively) strongly typed! Wow, so because of that, we can deduce a lot of runtime information at compile time. Thus, potentially, the interpreter could optimize. And for the ultimate speed gain, they will find a way to turn that interpreted C into native machine language. And then it'll run really fast. Yeah.

Perl is Interpreted C (4, Interesting)

Doc Ruby (173196) | more than 5 years ago | (#24087989)

There's very little if any C code that can't be written basically the same for Perl to interpret it basically the same way. The exception is direct memory access, but there are ways. And besides, I'd rather access memory through an API that really manages it, like making it hard to unexpectedly overflow buffers or grant access to unauthorized other users.

I'd love a Perl interpreter embedded in my browser. I'd love to have a Perl API directly to the browser app and the browser documents' DOM. I'd love to have a "Perl commandline" that returns text like usual, or that works on remote data by URL, or that returns icons or other data displayable in the browser.

Javascript is a pain in the ass. I'd rather have a Perl engine, and all the Perl modules and scripts, to run against my browser the way I usually run against my terminal window.

Startup latency (5, Interesting)

IamTheRealMike (537420) | more than 5 years ago | (#24087999)

Being able to run Python or Quake inside a Flash VM sounds useful at first blush, but it seems you'd lose most of what makes webapps nice for both developers and users. In particular, C based apps are not designed to be streamed, whereas Flash or AJAX apps usually are (to some extent). Nobody wants to browse to a "web app" and then spend 5 minutes twiddling their thumbs whilst 20 megabyte of Python runtime or Quake is pulled down over the wire. Web apps just have a different DNA to desktop apps.

I can see this being used to accelerate computation-heavy subelements of a regular Flash app though. I wonder how much of this is being driven by a desire to run a Photoshop subset inside Flash?

Flash? (1)

andy19 (1250844) | more than 5 years ago | (#24088071)

I thought the "new" web was trying to get away from Flash?

Re:Flash? (0)

Anonymous Coward | more than 5 years ago | (#24088453)

This thing is from Adobe, who wants to assimilate the Web.

Great, just another layer (1)

jmerlin (1010641) | more than 5 years ago | (#24088095)

I predict 20 years from now that there will be 10+ layers of virtualization to "safely" run "web applications" and plenty of viruses running around causing trouble.

That's not browser scripting! (0)

Anonymous Coward | more than 5 years ago | (#24088159)

Uh... that's not browser scripting, that's plugin scripting.
You can do anything with the right plugin...

Can you say Active-X (0)

Anonymous Coward | more than 5 years ago | (#24088261)

What a boon to malware writers everywhere, totally portable RAM access to your machine.

A mighty hack, but of dubious use. (4, Informative)

Peganthyrus (713645) | more than 5 years ago | (#24088433)

Hooray! Now C programmers can join the fun of writing sluggish applications that eat up huge amounts of CPU even when they're doing nothing!

Deceptive headline, too, as this is just about compiling C to the bytecode that the Flash player interprets. Or even worse, now that I RTFA: "The LLVM instructions are converted into opcodes for a custom Virtual Machine that runs in ActionScript, a variant of ECMAScript and sibling of JavaScript." So your C is compiled to bytecode, that is interpreted by an interpreter that is, itself, a stream of the Flash player's bytecode.

Moore's Law notwithstanding, this is a pretty insane use of processor cycles, guaranteed to make your program run a couple orders of magnitude slower than it would if you actually compiled it, or rewrote it in Actionscript!

Load More Comments
Slashdot Account

Need an Account?

Forgot your password?

Don't worry, we never post anything without your permission.

Submission Text Formatting Tips

We support a small subset of HTML, namely these tags:

  • b
  • i
  • p
  • br
  • a
  • ol
  • ul
  • li
  • dl
  • dt
  • dd
  • em
  • strong
  • tt
  • blockquote
  • div
  • quote
  • ecode

"ecode" can be used for code snippets, for example:

<ecode>    while(1) { do_something(); } </ecode>
Sign up for Slashdot Newsletters
Create a Slashdot Account

Loading...