Opening Window takes a lot of time

I have the following Problem. On my startpage I have two buttons which opens a subwindow with addWindow(). This works fine. But sometimes it takes a very, very long time util the subwindow opens (10-15 seconds and the red wait animation runs and runs).

Can anyone give me a hint how to find the reason or how to debug? There is nothing special with that windows. One is the password reset window, which contains a TextField for the E-Mail address and a submit button.
12652.png