|
From: | Richard Henderson |
Subject: | Re: [PATCH 2/2] target/m68k: add M68K_FEATURE_NO_DALIGN feature |
Date: | Sun, 7 Mar 2021 17:03:15 -0800 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 |
On 3/7/21 12:26 PM, Mark Cave-Ayland wrote:
According to the M68040UM Appendix D the requirement for data accesses to be word aligned is only for the 68000, 68008 and 68010 CPUs. Later CPUs from the 68020 onwards will allow unaligned data accesses but at the cost of being less efficient. Add a new M68K_FEATURE_NO_DALIGN feature to specify that data accesses are not required to be word aligned, and don't perform the alignment on the stack pointer when taking an exception if this feature is not selected.
How about a positive, rather than negative name, like M68K_FEATURE_UNALIGNED_DATA?This points out that we should be raising Address Error without this feature. This requires a moderate amount of cleanup in translate, manipulating MO_ALIGN{,_2} as part of the MemOp parameter to tcg_gen_qemu_{ld,st}_i32.
r~
[Prev in Thread] | Current Thread | [Next in Thread] |