Ticket #488 (Fixed)Thu May 14 07:48:01 UTC 2020
VFPSupport_CreateContext documentation in Wiki is unclear about user mode flag
Reported by: | Dennis Ranke (8444) | Severity: | Minor |
Part: | RISC OS: Documentation | Release: | |
Milestone: | Status | Fixed |
Details by Dennis Ranke (8444):
The VFPSupport_CreateContext Page states:
Bit 0: User mode flag (0=user mode access not required, 1=user mode access required)
and in the full description:
The flag in bit 0 of R0 controls a security measure that is supported on some systems; if you only require use of VFP/NEON instructions from privileged modes then it is recommended that you set this bit. This will prevent user-mode code from being able to execute VFP/NEON instructions and corrupt your context while it is active.
I’m reading the first line as: set bit 0 for use mode code, and the second line as: set bit 0 for privileged mode code.
I’m assuming that the first (set for user mode) is correct, but reading the actual source code of the VFPSupport module doesn’t answer this conundrum, as it looks like this feature is not yet implemented and the bit 0 ignored.
Changelog:
Modified by Jeffrey Lee (213) Thu, May 14 2020 - 16:53:21 GMT
- Status changed from Open to Fixed
Whoops!
“Set for user mode, clear for privileged” is correct.
You’re also right about the feature not being implemented yet. I should probably hurry up and implement it, because over time there’s a higher and higher chance of software being released which has it configured incorrectly (especially with typos like this)