Compilation time
Monkey Targets Forums/Desktop/Compilation time
| ||
It gets several minutes to compile a very simple application that uses lots of reflection. Anyway to improve this? It's getting to a point that it's too much to be sane |
| ||
Use msbuild, it's faster than GCC :B Or change optimization flags in command line... |
| ||
Yeah, I found switching from GCC to Visual Studio cut my builds from almost 3 minutes to under 30 seconds (sometimes as low as 10 seconds on a good day). Even if you want to switch back to GCC for release builds it reduced the frustration of development for me considerably :-) |
| ||
As nice as reflection is, it can add a huge heap of code to your app. I am not surprised that it takes way longer. Switching the compiler only helps there. Using reflection can extend the parsing and build process big time. |
| ||
As nice as reflection is, it can add a huge heap of code to your app. I am not surprised that it takes way longer. Switching the compiler only helps there. Using reflection can extend the parsing and build process big time. that's true, but as we lack Delegates, reflection is the only way to provide a decent event system. (I know it can be done using interfaces ala Java, but I was talking about a "decent" system) In the other hand the same code in JavaScript + HTML5 compiles with the blink of an eye, so it's not the Monkey side of things. I wonder why we can't have a switch or something like a switch to pre-compile modules on c++ targets. |
| ||
You could try using the XNA target, as the C# compiler is much faster than a C++ compiler. You'll need to return to C++ for debugging though. I might have to look and see how much work a "D" (http://dlang.org/) target would be, as that would give you native C++ speed, but with much faster compile times. |
| ||
Yes, I know D and love it. Not sure how complicated it would be but there are lots of things in Monkey that resembles D. I *think* a D target with support for SDL could maybe be a nice alternative to C++ with GLFW |