target-mips: Misaligned memory accesses for MSA
commitadc370a48fd26b92188fa4848dfb088578b1936c
authorYongbok Kim <yongbok.kim@imgtec.com>
Mon, 1 Jun 2015 11:13:24 +0000 (1 12:13 +0100)
committerLeon Alrae <leon.alrae@imgtec.com>
Thu, 11 Jun 2015 09:13:28 +0000 (11 10:13 +0100)
tree1b2663f554501c9a55ed8bb0fa71e0688378c39e
parent3b4afc9e75ab1a95f33e41f462921093f8a109c4
target-mips: Misaligned memory accesses for MSA

MIPS SIMD Architecture vector loads and stores require misalignment support.
MSA Memory access should work as an atomic operation. Therefore, it has to
check validity of all addresses for a vector store access if it is spanning
into two pages.

Separating helper functions for each data format as format is known in
translation.
To use mmu_idx from cpu_mmu_index() instead of calculating it from hflag.
Removing save_cpu_state() call in translation because it is able to use
cpu_restore_state() on fault as GETRA() is passed.

Signed-off-by: Yongbok Kim <yongbok.kim@imgtec.com>
Reviewed-by: Leon Alrae <leon.alrae@imgtec.com>
[leon.alrae@imgtec.com: remove unused do_* functions]
Signed-off-by: Leon Alrae <leon.alrae@imgtec.com>
target-mips/helper.h
target-mips/op_helper.c
target-mips/translate.c