i am chinese, my english is poor,so hope you can understand what i write.
CSP++ is a C++Server Page, haven't heard?That is affirmative, this is that I prepare start of a C++open source item, this item concentrates on developping a C++ base Web application development system.C++ is a strong language, but no C++ base Web application development system, just JSP, ASP.NET, all of these is base on interpret language.C++ is a efficiently language, server demand efficiently application, but why C++ none therein exertive it should have ?I think they are two main reason ,one is manufacturer strategy(this we are beyond the power to care) , other is a safe reason.of course C++ is a strong language, with the result that none let a person to at will upload a code to server, then let the server compile execution.That is a question whether we can let this code compile execution safely in the server?I think answer is yes, first my object be the portability of OS and platform, so all codes are that independent of platforms and OS , be also say that I just use the most basic C++language element(nonsupport head document and the related function of platforms and OS, only have a basic library to provided ) and with some inside object like JSP, ASP.NET, in fine to provide strong function possibly base on safe foundation .Certainly just so still not enough , so my object still wants to put this application to execution in the virtual machine(not is explain run , but use CPU to directly execution ).This virtual machine execution an OS which smallest , provide a limited document access, perhaps can't carry on a document access, provide an intermediate database access capability, done't imitate any hardware, in the memory space of process they are only some public link libraries that can promise a safety, don't exist any other things.(in my safe knowledge, i think it should be able to promise a safety )Pass these mechanisms, we can provide the portability of platforms and OS, at same platform next only change an OS we even can need not re-compile.
in my plan , first develops a syntax checker which aims at this item, to the C++ source document carry on some coherence checks ,then the C++source document send to a already have of intelligence C++compiler. in farsighted object, we need develop a optimizatio compiler for this item. First develop a simple virtual machine to satisfy the minimum gather of Web application demand , in farsighted object,we need develop a extensible, custom-built efficiently virtual machine, in the Web server we should some already have.
Above is the basic thought of this item, because of finite capability and finite energy .i Announce my thought with look for participant, Welcome contacts me , t10599762@163.com. let us do some for C++!Above is only my thought, affirmation exists much shortage, hope that everyone's joint effort does an optimization thought of this item .I am personal to think that this project contains a lot of advantages, the requirement isn't small either, is worthy to pay for him.
Normally, the virtual machine, either JVM or CLR, provides an execution environment for the program. The source code is compiled into certain intermediate language, and the intermediate language is converted into code native to the OS that it runs on.
In Microsoft .NET for instance, .NET compiler compiles C++ source code into MSIL or CIL, and CLR converts MSIL into code for the target OS.
Not sure if this basic requirement can be bypassed with any of your idea.
may be i should say virtual OS ,like VMware Workstation,if i use inter mediate language ,i think it no different from jave,intermediate language convert into machine code need time,i want convert C++ code into machine code,then run in very small virtual OS ,if run it on server os ,it not safe.or may be i don't really know what you say.