While working with armasm for Windows RT I noticed that I'm getting wrong results for data declared in executable section.
Below is a sample code. Since on Windows RT 32-bit ARM is broken and only Thumb2 works, I get unaligned fault when reading from test_data. The reason for that is because ldr r12 loads address of test_data as if it was a function (e.g. it adds 1 to the address).
In armasm from arm.com there are directives to control that behavior: functions need to marked as functions so that likner would know that it needs to patch the addresses to make them thumb. For data it doesn't add 1, but the armasm from microsoft seems to
ignore everything and tread it as thumb function anyways. Also, I wasn't able to force the address to be propelry aligned for reads with ldr r12, =test_data^1 (armasm gives a error for this).
ALIGN 4
test_data
DCD 0 //repeat it 7 more times 6 times
test
LDR r12,=test_data
VLD1.64 {d12,d13,d14,d15},[r12@128]
BX lr