Title | Requirements for fixing tagged references are unclear |
Status | closed |
Priority | optional |
Assigned user | Gareth Rees |
Organization | Ravenbrook |
Description | The reference manual needs to explain what the requirements are for a reference passed to any of the fix functions (MPS_FIX1, MPS_FIX2, or MPS_FIX12). In particular, if you have a tagged (or otherwise "encrypted") reference, do you need to remove the tag before calling them (and restore it afterwards)? It seemed simplest to explain that you do need to remove and restore the tag. But maybe there is is some "leeway" here. But what exactly should be documented? |
Analysis | job002175 seems to be related. In discussion, RB and GDR agreed that the documentation will say that if references are stored in "encrypted" form (e.g. with a tag) then they must be decrypted before calling any of the MPS_FIX functions and encrypted again afterwards. It's safe to document the most stringent requirement because we can relax it later. [GDR 2012-10-18: updated documentation on branch/2012-10-09/user-guide to say this.] However, if it is intended that the MPS should support some leeway (e.g. it might support a reference that's "near enough" being passed to MPS_FIX1) then this should be thought about and then documented. GDR 2012-10-25: RB and I discussed this and we agreed that we would document that if you pass an interior pointer to MPS_FIX1 you get an accurate result for the whole object. (The actual behaviour gives more leeway than this: in fact any pointer to the page works, but we don't want to document that.) This gives clients the flexibility to use small tags in the low bits of the reference without having to strip them before passing to MPS_FIX1. (The documentation continues to state that you have to remove the tag before calling MPS_FIX2.) |
How found | inspection |
Evidence | None. |
Observed in | 1.110.0 |
Created by | Gareth Rees |
Created on | 2012-10-17 17:30:38 |
Last modified by | Gareth Rees |
Last modified on | 2012-10-25 23:01:41 |
History | 2012-10-17 GDR Created. 2012-10-18 GDR Note that documentation was updated. 2012-10-25 GDR Added analysis from meeting with RB. |
Change | Effect | Date | User | Description |
---|---|---|---|---|
180061 | closed | 2012-10-24 22:00:22 | Gareth Rees | Write scanning chapter. |
179931 | open | 2012-10-18 09:26:59 | Gareth Rees | Complete more tasks from discussion with RB yesterday. |