Remco;18614 wrote:
That's some impressive multi-tasking.
It isn't really, it simply means I have to work evenings and weekends to get any proper work done! I just happen to have worked on several very successful (in their niche) products, and they all need looking after.
Remco;18614 wrote:
That's old. It's also a reminder to me about the important of continuing to support older platforms. Do you mind me asking which version of VS you are running?
VS26 Insiders. I am old and my projects (well, some of them), are old, but my tools are not. I mostly skipped net9 but other than that we always move forward with the framework.
Remco;18614 wrote:
That's a fair assessment. It's a bit unfortunate that needing to support platform abstractions means NCrunch has to 'churn' up quite a bit of waste, with a lot of files copied. Ideally, the sandbox would be lighter weight, but there's no practical way to implement that without breaking a lot of stuff for everyone.
There is no optimisation you can possibly perform that will be better than simple not doing anything with a project, I don't really really feel this should be a point of debate.
Remco;18614 wrote:
A few things you might be interested in knowing:
- A project that is never changed will only have one workspace created by NCrunch, so it's only ever copied once. It will also only be built once, unless the 'Copy referenced assemblies to workspace' setting is being used
- Modern SSDs are very fast. Copying files and building workspaces is generally not a serious performance consideration unless they have massive resource files or an absolute ton of code
- However, actually BUILDING such projects can be a massive drain on resources, especially as MS's compiler optimisation goals have moved more towards lots of parallel threads rather than one insanely optimised one
- After the first build run/initialisation, everything always works faster
Remco;18614 wrote:
A question that I do have: Is the performance issue bothering you more specific to the initial engine startup? Or to the time the engine takes to report results?
I am a busy guy running 5 instances of Visual Studio with Resharper and nCrunch and I buy the fastest, most expensive, computers I can but they run Windows 11. You can be 100% sure that I am in a almost permenant rage about the dreadful performance of all these tools.
But you have now triggered a performance rant, because you say several things which I think hint at why the performance landscape is so terrible on a modern windows box.
* To start gently, I
do think it's reasonable for people writing interactive UI to be somewhat cavalier about their users' computer's resources. If you want to take 55ms to respond to a button click rather than 50, then that's fine, and the person who is waiting for you won't notice and won't care.
* All other code effectively runs in the background, and the implied contract between the developer and the user is different, or it should be:
- SSDs are fast, and I bought one because I wanted my computer to be faster, not so that software vendors could spend less effort avoiding disk accesses and thinking (or worse, telling me) it didn't really matter.
- I have lots of memory, but I didn't buy it so that other people can simply waste it.
- I have lots (far too many) of cores of CPU but that doesn't mean people should try and grab them all or stop other people using some of them so that they get a clear run.
- Caching (at every level) is an incredibly important thing for modern processors, but only works if the thing you need is in the cache, and hasn't been washed-out because someone couldn't work out how to make their app sleep until the next weekly firmware update check so they wake up once a second and look at the clock. (This is not a dig at you!)
- My computer is a shared (between software vendors) resource, and I want vendors to behave properly, not each throw their cigarette butts out of the car window and think it doesn't matter because each one is a tiny little bit of cotton and paper.
- To a vendor, his product is the most important thing, but to me it's just a background task which needs to coexist sensibly. Operating system kernels put an enormous amount of effort into that coexistence, but application developers (frequently from the same organisations as the OS) seem hell-bent on subverting that with the biggest land-grab they can make.
But often, it's just laziness or incompetence: at the moment, my PC, which does not have a single IDE open and is basically idle, has an absurd 380 process running on it,and it's doing about 20000 context switches a second, in good part because so many developers have mistaken something being very quick for being something they should do pointlessly over and over again. It seems utterly inescapable - even Zed, which is supposed to be a brand-new on-the-metal high performance editor is doing 250 context switches a second. A backgrounded text editor FFS - would could it possibly be doing other than waiting for a UI event?
When the excellent Bruce Dawson wrote the excellent
https://randomascii.word...tage-on-an-idle-laptop/ he said this:
Quote:
1. Don’t poll. Polling wastes CPU time and stops the CPU from dropping deep into power-saving states. WaitForMultipleObjects is your friend.
2. Seriously, don’t poll. I know you think that your program is a special snowflake but polling is just wasteful.
He had to write point 2 because he knows what programmers say when you put point 1 to them.
And if 2016 is too modern, here's one from another 10 years earlier:
https://devblogs.microso...ng/20060124-17/?p=32553
But for "polling" you can substitute "anything which you don't need to do but is just simpler to keep doing anyway", because it all means the same thing in terms of pissing into the public swimming pool.
(I would say that your grid server is very good about not polling when it's idle, so I'll overlook the 2G of RAM it seems to be holding on to :-)
Anyway, I like NCrunch (if not the config dialog) and I admire your tenacity - but you did goad me into the performance stuff :-) As an aside, you may be pleased that I once explained to a group from MS that I wasn't using the VS preview because NCrunch didn't run on it yet, and it didn't run on it yet because you were still massively stinging from a year of being dicked-about by the .net core introduction and couldn't be bothered with playing-along with their time wasting preview process any more. I heard later this has caused quite a reaction internally...
Cheers!