Sign in to follow this  
Followers 0
Kiai

Page faults growing by 50 per minute

2 posts in this topic

I basically understand page faults. In reviewing a script I wrote, this simple loop causes a steady increase in page faults:

While 1

Select

Case WinActive("New Results Patient's Name:")

$RTE_window_open = 1

$title = WinGetTitle("New Results Patient's Name:")

GUI_RTE()

Case WinActive("", "Document Type: Letter")

GUI_Sign_Print()

Case WinActive("Inbox Message", $patient) And $clipboard = 1

GUI_Msg_paste()

EndSelect

Sleep(1000)

WEnd

While the page faults don't get as high as apps like interenet explorer (over 1,000,000), after a few hours, they are in the 10k's range. I'm not that worried about system stability but I wonder if anyone can point out, in this very simple loop, anything I can do to reduce the page fault rate?

Thanks.

Share this post


Link to post
Share on other sites



Firstly whenever you post code, always use tags so ppl can read it.

While 1
    Select
        Case WinActive("New Results Patient's Name:")
            $RTE_window_open = 1
            $title = WinGetTitle("New Results Patient's Name:")
            GUI_RTE()
        Case WinActive("", "Document Type: Letter")
            GUI_Sign_Print()
        Case WinActive("Inbox Message", $patient) And $clipboard = 1
            GUI_Msg_paste()
    EndSelect
    Sleep(1000)
WEnd

Secondly, page faults are normal, they happen all the time in windows. I suggest you Google traps and faults then page faults so you understand what they are why they are normal.

I can see nothing wrong with your script. :D


Post your code because code says more then your words can. SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y. Use Opt("MustDeclareVars", 1)[topic="84960"]Brett F's Learning To Script with AutoIt V3[/topic][topic="21048"]Valuater's AutoIt 1-2-3, Class... is now in Session[/topic]Contribution: [topic="87994"]Get SVN Rev Number[/topic], [topic="93527"]Control Handle under mouse[/topic], [topic="91966"]A Presentation using AutoIt[/topic], [topic="112756"]Log ConsoleWrite output in Scite[/topic]

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0