MPS issue job003943

TitleNo consistent way to discover arena configuration
Assigned userNick Barnes
DescriptionOn branch/2015-08-06/config we have mps_arena_configure(), a single way for client code to set diverse modifiable arena parameters. But there is no single way for client code to find out the current values of those parameters. We have mps_arena_commit_limit() and mps_arena_spare_commit_limit() but no way to get the other existing arena parameters (such as the base and size of a client arena, the size of a VM arena, the grain size, and the VMW3_TOP_DOWN parameter) or other future parameters. A single consistent interface would be better than adding more and more ad-hoc getter functions.
AnalysisIt seems like a good idea to use keyword argument arrays: expose a few more utility functions and macros - like ArgPick - to client code. Then write mps_arena_configuration() which fills in a client keyword argument array with all the arena config keyword arguments.
It may be a step to far to use this same interface to return other potentially useful information about an arena (such as its arena class, unless arena class should become something passed as a keyword??) But then maybe we need a different API for "what class is this arena?" Further analysis required.
How foundinspection
Created byNick Barnes
Created on2015-09-09 14:41:55
Last modified byNick Barnes
Last modified on2015-09-09 14:41:55
History2015-09-09 NB Created.