3 ms·
It's doable and been done, but it's just kind of pointless.
by jey 19y ago
It's doable and been done, but it's just kind of pointless.
- jcl 19y agoI assume you mean it's pointless because C++ sacrifices ease-of-coding for performance, but when C++ is compiled to bytecode it won't be appreciably faster than other languages. While it would be odd for someone to write new C++ code solely to target bytecode, I think that a C++ bytecode compiler would still be useful in situations where, for example, you have an existing C++ codebase that you would like to reuse in a web client.
- jey 19y agoNo, I mean it's pointless because I think there are very few use cases for it. You're pretty much limited to libraries which do not rely on any OS-specific calls or which only do very generic OS-calls like file I/O. FWIW, I'm the author of GCC-CIL, which provides a backend to GCC to emit .NET bytecode, and I still don't see the point. I mean, what are you going to recompile for flash or .NET? BLAS and LINPACK? :P At least with .NET you have access to libc and other native code libraries via P/Invoke, but you don't even get that from flash...
- jcl 19y agoAh, I wasn't sure what you meant. I agree that there aren't too many use cases. Personally, I think some of the existing computational geometry libraries could be useful, but I am thinking of a niche set of applications. More useful, perhaps, might be existing libraries to read/write file formats. But I'd be surprised if there was anyone looking to port their huge C++ application wholesale to Flash.