Slower reload after upgrade

Ask for help, how to use AHK_H, etc.
think
Posts: 33
Joined: 09 Feb 2014, 05:20

Slower reload after upgrade

07 Apr 2018, 05:29

Hi, after upgrading from 1.22 to 1.28, reloading one of my larger scripts is now much slower. First run is instant, however reloading (or running again) the same script causes a two seconds delay (windows waiting cursor, slow cursor movement). After the script is reloaded it shows two Tray icons, when cursor is moved over Tray, the second icon disappears.

It looks like closing of processes takes much more time now... Any idea?
think
Posts: 33
Joined: 09 Feb 2014, 05:20

Re: Slower reload after upgrade

15 Jun 2018, 16:59

Installed 1.1.29.01 and the issue is the same.
swagfag
Posts: 938
Joined: 11 Jan 2017, 17:59

Re: Slower reload after upgrade

15 Jun 2018, 19:28

i doubt anyones gonna be able to tell you much without seeing the contents of the script
User avatar
jeeswg
Posts: 4783
Joined: 19 Dec 2016, 01:58
Location: UK

Re: Slower reload after upgrade

15 Jun 2018, 19:31

Try 1.1.23/24/25/26/27 to help narrow it down.
think
Posts: 33
Joined: 09 Feb 2014, 05:20

Re: Slower reload after upgrade

16 Jun 2018, 05:18

Thanks for the tip! The script is large and consists of several threads, using multiple ahkthread, ahkterminate etc.

I tried all the releases and I have found the following (both AutoHotkey_H Unicode 32-bit):
1.1.24.05 H008 - WORKS
1.1.25.00 H001 - HAVE ISSUES

The following issues started from 1.1.25.00 H001 onwards:
- slower script exit/reload, two seconds delay with slow cursor movement.
- two tray icons after reload, the older disappears when cursor is moved over it.
- one of the dll.ahkTerminate() functions crashes the script (AutoHotkey has stopped working).

What was changed in 1.1.25.00 H001 that could cause the above issues?
HotKeyIt
Posts: 1664
Joined: 29 Sep 2013, 18:35
Contact:

Re: Slower reload after upgrade

16 Jun 2018, 09:40

As far as I remember there was a bug reloading a thread and resources were not freed fully, after the fix it might take longer to reload.
With regards to crashes and slow mouse movements it would be good if you can post an example script.
think
Posts: 33
Joined: 09 Feb 2014, 05:20

Re: Slower reload after upgrade

18 Jun 2018, 03:13

Thanks for your response HotKeyIt. I believe I have found a reason - the following simple script crashes on exit or reload. The reason is in #IfWinExistcommand.
As mentioned this started with 1.1.25.00 H001.

Code: [Select all] [Download] GeSHi © Codebox Plus

string:="
(
#NoTrayIcon
#IfWinExist Untitled - Notepad ;<--- this causes the issue
::kr::kind regards
)"

dll:=ahkthread(string)
Return
HotKeyIt
Posts: 1664
Joined: 29 Sep 2013, 18:35
Contact:

Re: Slower reload after upgrade

18 Jun 2018, 16:48

This is because your main script exits right away, you have to use #Persistent!
think
Posts: 33
Joined: 09 Feb 2014, 05:20

Re: Slower reload after upgrade

19 Jun 2018, 02:32

No difference, please run the script and try to exit or reload it.

Code: [Select all] [Download] GeSHi © Codebox Plus

#Persistent
string:="
(
#NoTrayIcon
#IfWinExist Untitled - Notepad ;<--- this causes the issue
::kr::kind regards
)"

dll:=ahkthread(string)
Return
think
Posts: 33
Joined: 09 Feb 2014, 05:20

Re: Slower reload after upgrade

20 Jun 2018, 04:37

Thanks! ;)

Return to “Ask For Help”

Who is online

Users browsing this forum: No registered users and 1 guest