views:

46

answers:

4

In order to measure application' cold-start time, I have to reboot my machine every time, which is really time-consuming. I understand it is mission impossible to simulate a real reboot, but what I want is something rough, ex, put out cache in standby list as many as possible so the warm start won't be so warm anymore.

Any ideas on this?

Thanks

A: 

I would run a modern game and quit it immediately. All the loading most modern games do should be enough to overwrite all cached data. And perhaps running a mp3 or video while starting your app will be enough to simulate OS startup, but thats maybe too much :)

PeterK
+3  A: 

A virtual machine would be your best bet. The virtual machine will provide a clean slate for the app, but it will be much quicker to reload the virtual machine image than your physical machine.

C. Ross
But I am afraid there would be a big impact on performance on virtual machine.
lz_prgmr
@Dbger On your machine, quite possibly. You'd have to compare it against itself, then once you'd made some real improvement retest it. OR you could have a virtual machine on a proper server, but that's *real money* as we say.
C. Ross
A: 

There are applications out there that 'clear' your RAM... However, they can take awhile... So you are better off rebooting. Also on Win7 disable superfetch for this kind of functionality; the service caches things you do in RAM.

A: 

I agree with the VM approach. You might also try "logging off" your current user, and logging back on.

reuscam