steadycookie Posted June 28, 2009 Posted June 28, 2009 (edited) I have many very short scripts which will be called in Autohotkey script once in a while. To increase the efficiency, I want to keep an instance of autoit.exe always in memory, and then when running an autoit script, I want to use this instance to run the autoit script, other than starting up another new instance of autoit.exe. In this way, the time of loading autoit.exe to run my script is saved--when the script is short, this part of time is significant compared to the total runtime of the script. Is there a way to implement what I want? Thank you very much! Edited June 28, 2009 by steadycookie
Inverted Posted June 28, 2009 Posted June 28, 2009 (edited) Best way would be to make one script with your stuff and your hotkeys and just keep that running. Edited June 28, 2009 by Inverted
steadycookie Posted June 28, 2009 Author Posted June 28, 2009 Thanks for help!Your method is feasible. However, is there a way I want (keep autoit.exe in memory to run different scripts)? Best way would be to make one script with your stuff and your hotkeys and just keep that running.
Bert Posted June 28, 2009 Posted June 28, 2009 I do not think so. The Vollatran project My blog: http://www.vollysinterestingshit.com/
steadycookie Posted June 28, 2009 Author Posted June 28, 2009 OK. Thanks! My requirements seem easy, but they turn out to be impossible. I do not think so.
MilesAhead Posted June 28, 2009 Posted June 28, 2009 (edited) OK. Thanks! My requirements seem easy, but they turn out to be impossible.I wonder what would happen if you wrapped it in one of those "run any exe as a service" utilities?Also if you had a script that just idled in the tray, wouldn't the OS just duplicate the exe image already in ram to feed to the new script? (I don't know the answers,.. I'm just asking... not rhetorically) Edited June 28, 2009 by MilesAhead My Freeware Page
Thornhunt Posted June 28, 2009 Posted June 28, 2009 run a script like this while 1 slepp(1000) wend only that in the background with no end... that way the it will sleightly be in memory and hardly take up processor i thnink thats what you mean ? Budweiser + room = warm beerwarm beer + fridge = too long!warm beer + CO2 fire extinguisher = Perfect![quote]Protect the easly offended ... BAN EVERYTHING[/quote]^^ hmm works for me :D
herewasplato Posted June 28, 2009 Posted June 28, 2009 (edited) ... wouldn't the OS just duplicate the exe image already in ram to feed to the new script? ...Each new instance comes from the drive - at least in XP.Edit: I've been hunting for the reference where I read this on a MS site, but cannot locate it - so for now, file this under "my guess". Edited June 28, 2009 by herewasplato [size="1"][font="Arial"].[u].[/u][/font][/size]
herewasplato Posted June 28, 2009 Posted June 28, 2009 run a script like this while 1 sleep(1000)wendonly that in the background with no end...that way the it will sleightly be in memory and hardly take up processor i thnink thats what you mean ?Each new script loads a new instance of AutoIt, so keeping this code running would just increase the odds that the OS has pushed another copy of AutoIt from RAM. [size="1"][font="Arial"].[u].[/u][/font][/size]
Thornhunt Posted June 28, 2009 Posted June 28, 2009 fair enuth Budweiser + room = warm beerwarm beer + fridge = too long!warm beer + CO2 fire extinguisher = Perfect![quote]Protect the easly offended ... BAN EVERYTHING[/quote]^^ hmm works for me :D
MDCT Posted June 29, 2009 Posted June 29, 2009 (edited) Steadycookie, I believe what you really want is speed, right? You want the script to be loaded in the memory and so when the script is called it would be faster than called on normal harddisk. Maybe you can use RAM Drive to create a drive space taken from your RAM. It is many times faster than normal harddisk, but it cannot store data on restart. I don't know how significant the usage of RAM Drive on the script as the script is relatively very small in size. Edited June 29, 2009 by MDCT
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now