Actions
Task #5720
closedAliases for arrays of registers
Start date:
03/18/2015
Due date:
% Done:
100%
Estimated time:
Detected in build:
2.1.5-beta-150305
Published in build:
150522
Description
It would be very convenient and useful to have aliases for arrays of regs. The example follows.
reg GPR [32, DWORD] reg X [32, DWORD] alias = GPR // expected reg W [32, WORD] alias = GPR // expected
Updated by Alexander Kamkin over 9 years ago
- Target version changed from 2.1 to 2.2
Updated by Andrei Tatarnikov over 9 years ago
- Status changed from New to Open
Started - r3619 (grammar rules + sketch of runtime library code).
Updated by Andrei Tatarnikov over 9 years ago
Sketch implementation is done - r3630.
Updated by Andrei Tatarnikov over 9 years ago
Examples:
The structure reg Y [N, T] alias = X [MIN..MAX]
allows interpreting a part of the X array from MIN to MAX as an array of type T that includes N items.
Precondition: sizeof(Type of array X)
must be divisible to sizeof(T)
.
reg GPR [32, WORD] reg GPRS1 [2, SHORT] alias = GPR // Interpret GPR[0] as an array of 2 SHORTs reg GPRS2 [64, SHORT] alias = GPR[0..31] // Interpret GPR (entire) as an array of 64 SHORTs reg GPRS3 [32, SHORT] alias = GPR[16..31] // Interpret the second half of GPR as an array of 32 SHORTs
Updated by Andrei Tatarnikov over 9 years ago
- Status changed from Resolved to Closed
- % Done changed from 70 to 100
- Published in build set to 150522
Actions