summaryrefslogtreecommitdiff
path: root/target/m68k/helper.h
diff options
context:
space:
mode:
authorLaurent Vivier <laurent@vivier.eu>2016-01-11 01:33:26 +0100
committerLaurent Vivier <laurent@vivier.eu>2016-12-27 18:21:09 +0100
commit14f944063affbcc7bd6df42b060793dbfee8a822 (patch)
tree38b0f3ba0c2537980c27456db475917cf04a12b2 /target/m68k/helper.h
parentfb5543d820018a46b713911e7653594be727ca98 (diff)
downloadqemu-14f944063affbcc7bd6df42b060793dbfee8a822.zip
target-m68k: add cas/cas2 ops
Implement CAS using cmpxchg. Implement CAS2 using helper and either cmpxchg when the 32bit addresses are consecutive, or with parallel_cpus+cpu_loop_exit_atomic() otherwise. Suggested-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Laurent Vivier <laurent@vivier.eu> Reviewed-by: Richard Henderson <rth@twiddle.net>
Diffstat (limited to 'target/m68k/helper.h')
-rw-r--r--target/m68k/helper.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/target/m68k/helper.h b/target/m68k/helper.h
index 6180dc5643..a6f88fca76 100644
--- a/target/m68k/helper.h
+++ b/target/m68k/helper.h
@@ -12,6 +12,8 @@ DEF_HELPER_3(shr_cc, i32, env, i32, i32)
DEF_HELPER_3(sar_cc, i32, env, i32, i32)
DEF_HELPER_2(set_sr, void, env, i32)
DEF_HELPER_3(movec, void, env, i32, i32)
+DEF_HELPER_4(cas2w, void, env, i32, i32, i32)
+DEF_HELPER_4(cas2l, void, env, i32, i32, i32)
DEF_HELPER_2(f64_to_i32, f32, env, f64)
DEF_HELPER_2(f64_to_f32, f32, env, f64)