[Bizgres-general] Question: Is 64-bit cache support valuable?

Josh Berkus josh at agliodbs.com
Thu Jul 21 18:28:32 GMT 2005


Simon,

> The challenge is to come up with a scheme that has these features:
> - prevents overallocation of memory which results in swapping
> - maximises allocation of large memory servers
> - allows heavy memory users to "go large" when they need to
> - prevents low memory users from conflicting with heavy users/each other
> - allows the administrator to have control over the system
> - allows some level of control at user level e.g. "need lots, please"
> - must be easy enough to get right in real-world use, not benchmarks
> - also need to take into account temp_buffers settings
> - there may also be a requirement for predictability, so that important
> regular tasks can complete in known durations or by deadlines

Sounds good but too complicated for a first implementation.   I'd narrow down 
the critical features to:

1. Allow 64-bit work_mem (and maintenance_work_mem) allocation.
2. Add a total_work_mem limit which would be tracked for work_mem, 
maintenance_work_mem, and temp_buffers.
3. Add a system where processes requesting over the limit or total_work_mem 
would block and wait.

I think that would be enough code for a first, useful implementation and 
further improvements would be suggested by the users/results.   Adding the 
hooks for centralized tracking and management of allocated memory will be 
enough code as it is.

-- 
Josh Berkus
Aglio Database Solutions
San Francisco


More information about the Bizgres-general mailing list