View Issue Details

IDProjectCategoryView StatusLast Update
0002802Ham Radio DeluxeMaintenancepublic2018-09-11 13:18
ReporterK7ZCZAssigned ToK7ZCZ 
Status closedResolutionfixed 
Product Version6.4.0.858 
Target VersionFixed in Version6.4.0.886 
Summary0002802: All: don't call EmptyWorkingSet() API
DescriptionThe Logbook, Rig Control, and Digital Master have code to call the Windows EmptyWorkingSet() API.

This API is pretty bogus for desktop applications like ours. It does what it says: kicks as many pages out of memory as possible. The appeal in calling this function is to reduce the aparent memory usage of the application.

The use of the API is a false economy, however. At the moment it is called, all possible pages are evicted from memory. When the function returns -- literally, the next thing to execute in the application -- has to touch memory and it's likely that memory, whether it is code or data, shared or private -- hsa to be swapped back into memory. Of course, swapping data back into memory is expensive.

Instead of calling this API, the appications should let Windows manage memory naturally. Most customers won't be running with memory pressure. If they are, then the system should decide what needs to be removed from memory and when, based on pressure and demand and scheduling, rather than having the application try to naievely and artificially influence swapping.

In the suite, these applications have code which could call EmptyWorkingSet():

 + Logbook
 + Rig Control
 + Digital Master
Some of the applications have these calls disabled, some call more aggressively than the others. The calls, and any supporting code, should simply be removed.

The effect of the removal will be faster startup and less disruptive discarding of useful memory. The negative affect will be the appearance of a larger working set in Task Manager. The only performance impact is positive.
TagsNo tags attached.
Testing Not Tested



2018-08-15 19:59

administrator   ~0005979

fixed with this checkin

This will be visible to customers in that the Task Manager will report sensible stats for memory usage and page fault counts compared to previous versions of the product.


2018-09-07 16:55

administrator   ~0006118

Unable to test. Accepting this as validated; developer managed topic.

Issue History

Date Modified Username Field Change
2018-07-04 18:12 K7ZCZ New Issue
2018-08-15 19:59 K7ZCZ Assigned To => K7ZCZ
2018-08-15 19:59 K7ZCZ Status new => resolved
2018-08-15 19:59 K7ZCZ Resolution open => fixed
2018-08-15 19:59 K7ZCZ Note Added: 0005979
2018-08-29 18:40 K7ZCZ Fixed in Version =>
2018-09-07 16:55 WA9PIE Status resolved => closed
2018-09-07 16:55 WA9PIE Testing Not Started => Not Tested
2018-09-07 16:55 WA9PIE Note Added: 0006118
2018-09-11 13:15 WA9PIE Project 3 - Current Dev List => Ham Radio Deluxe
2018-09-11 13:18 WA9PIE Fixed in Version =>