I am currently working on a project, where i inject bitflips (0 -> 1, or 1 -> 0) in memory or registers. Now i have to think about some special cases.
Here is my question:
Can there be cases, where there is a memory access on a certain memory location and shortly after, there is a memory access on the same location with smaller or wider access size?
Example:
1: ld.B D15, [A15]
2: ld.W D15, [A15]
In line 1 the memory is accessed via the pointer in the addressregister A15 and it's content is stored in dataregister D15. The access size is a byte (.B). In line 2 it's the same as in line 1, but with the access size word (.W)(32-Bit).
So the access sizes would be something like this:
[A15] ------XX -> line 1
[A15] XXXXXXXX -> line 2
Where X is a hexdecimal.
Is this possible, that the compiler would do something like this? And what would be an example case for this?
I have no idea if this question is stupid or not. I am sorry! :D