qemu/target-sparc/helper.h
<<
>>
Prefs
   1#include "exec/def-helper.h"
   2
   3#ifndef TARGET_SPARC64
   4DEF_HELPER_1(rett, void, env)
   5DEF_HELPER_2(wrpsr, void, env, tl)
   6DEF_HELPER_1(rdpsr, tl, env)
   7DEF_HELPER_1(power_down, void, env)
   8#else
   9DEF_HELPER_2(wrpil, void, env, tl)
  10DEF_HELPER_2(wrpstate, void, env, tl)
  11DEF_HELPER_1(done, void, env)
  12DEF_HELPER_1(retry, void, env)
  13DEF_HELPER_1(flushw, void, env)
  14DEF_HELPER_1(saved, void, env)
  15DEF_HELPER_1(restored, void, env)
  16DEF_HELPER_1(rdccr, tl, env)
  17DEF_HELPER_2(wrccr, void, env, tl)
  18DEF_HELPER_1(rdcwp, tl, env)
  19DEF_HELPER_2(wrcwp, void, env, tl)
  20DEF_HELPER_FLAGS_2(array8, TCG_CALL_NO_RWG_SE, tl, tl, tl)
  21DEF_HELPER_1(popc, tl, tl)
  22DEF_HELPER_4(ldda_asi, void, env, tl, int, int)
  23DEF_HELPER_5(ldf_asi, void, env, tl, int, int, int)
  24DEF_HELPER_5(stf_asi, void, env, tl, int, int, int)
  25DEF_HELPER_5(casx_asi, tl, env, tl, tl, tl, i32)
  26DEF_HELPER_2(set_softint, void, env, i64)
  27DEF_HELPER_2(clear_softint, void, env, i64)
  28DEF_HELPER_2(write_softint, void, env, i64)
  29DEF_HELPER_2(tick_set_count, void, ptr, i64)
  30DEF_HELPER_1(tick_get_count, i64, ptr)
  31DEF_HELPER_2(tick_set_limit, void, ptr, i64)
  32#endif
  33#if !defined(CONFIG_USER_ONLY) || defined(TARGET_SPARC64)
  34DEF_HELPER_5(cas_asi, tl, env, tl, tl, tl, i32)
  35#endif
  36DEF_HELPER_3(check_align, void, env, tl, i32)
  37DEF_HELPER_1(debug, void, env)
  38DEF_HELPER_1(save, void, env)
  39DEF_HELPER_1(restore, void, env)
  40DEF_HELPER_3(udiv, tl, env, tl, tl)
  41DEF_HELPER_3(udiv_cc, tl, env, tl, tl)
  42DEF_HELPER_3(sdiv, tl, env, tl, tl)
  43DEF_HELPER_3(sdiv_cc, tl, env, tl, tl)
  44DEF_HELPER_3(taddcctv, tl, env, tl, tl)
  45DEF_HELPER_3(tsubcctv, tl, env, tl, tl)
  46#ifdef TARGET_SPARC64
  47DEF_HELPER_3(sdivx, s64, env, s64, s64)
  48DEF_HELPER_3(udivx, i64, env, i64, i64)
  49#endif
  50DEF_HELPER_3(ldqf, void, env, tl, int)
  51DEF_HELPER_3(stqf, void, env, tl, int)
  52#if !defined(CONFIG_USER_ONLY) || defined(TARGET_SPARC64)
  53DEF_HELPER_5(ld_asi, i64, env, tl, int, int, int)
  54DEF_HELPER_5(st_asi, void, env, tl, i64, int, int)
  55#endif
  56DEF_HELPER_2(ldfsr, void, env, i32)
  57DEF_HELPER_FLAGS_1(fabss, TCG_CALL_NO_RWG_SE, f32, f32)
  58DEF_HELPER_2(fsqrts, f32, env, f32)
  59DEF_HELPER_2(fsqrtd, f64, env, f64)
  60DEF_HELPER_3(fcmps, void, env, f32, f32)
  61DEF_HELPER_3(fcmpd, void, env, f64, f64)
  62DEF_HELPER_3(fcmpes, void, env, f32, f32)
  63DEF_HELPER_3(fcmped, void, env, f64, f64)
  64DEF_HELPER_1(fsqrtq, void, env)
  65DEF_HELPER_1(fcmpq, void, env)
  66DEF_HELPER_1(fcmpeq, void, env)
  67#ifdef TARGET_SPARC64
  68DEF_HELPER_2(ldxfsr, void, env, i64)
  69DEF_HELPER_FLAGS_1(fabsd, TCG_CALL_NO_RWG_SE, f64, f64)
  70DEF_HELPER_3(fcmps_fcc1, void, env, f32, f32)
  71DEF_HELPER_3(fcmps_fcc2, void, env, f32, f32)
  72DEF_HELPER_3(fcmps_fcc3, void, env, f32, f32)
  73DEF_HELPER_3(fcmpd_fcc1, void, env, f64, f64)
  74DEF_HELPER_3(fcmpd_fcc2, void, env, f64, f64)
  75DEF_HELPER_3(fcmpd_fcc3, void, env, f64, f64)
  76DEF_HELPER_3(fcmpes_fcc1, void, env, f32, f32)
  77DEF_HELPER_3(fcmpes_fcc2, void, env, f32, f32)
  78DEF_HELPER_3(fcmpes_fcc3, void, env, f32, f32)
  79DEF_HELPER_3(fcmped_fcc1, void, env, f64, f64)
  80DEF_HELPER_3(fcmped_fcc2, void, env, f64, f64)
  81DEF_HELPER_3(fcmped_fcc3, void, env, f64, f64)
  82DEF_HELPER_1(fabsq, void, env)
  83DEF_HELPER_1(fcmpq_fcc1, void, env)
  84DEF_HELPER_1(fcmpq_fcc2, void, env)
  85DEF_HELPER_1(fcmpq_fcc3, void, env)
  86DEF_HELPER_1(fcmpeq_fcc1, void, env)
  87DEF_HELPER_1(fcmpeq_fcc2, void, env)
  88DEF_HELPER_1(fcmpeq_fcc3, void, env)
  89#endif
  90DEF_HELPER_2(raise_exception, noreturn, env, int)
  91#define F_HELPER_0_1(name) DEF_HELPER_1(f ## name, void, env)
  92
  93DEF_HELPER_3(faddd, f64, env, f64, f64)
  94DEF_HELPER_3(fsubd, f64, env, f64, f64)
  95DEF_HELPER_3(fmuld, f64, env, f64, f64)
  96DEF_HELPER_3(fdivd, f64, env, f64, f64)
  97F_HELPER_0_1(addq)
  98F_HELPER_0_1(subq)
  99F_HELPER_0_1(mulq)
 100F_HELPER_0_1(divq)
 101
 102DEF_HELPER_3(fadds, f32, env, f32, f32)
 103DEF_HELPER_3(fsubs, f32, env, f32, f32)
 104DEF_HELPER_3(fmuls, f32, env, f32, f32)
 105DEF_HELPER_3(fdivs, f32, env, f32, f32)
 106
 107DEF_HELPER_3(fsmuld, f64, env, f32, f32)
 108DEF_HELPER_3(fdmulq, void, env, f64, f64)
 109
 110DEF_HELPER_FLAGS_1(fnegs, TCG_CALL_NO_RWG_SE, f32, f32)
 111DEF_HELPER_2(fitod, f64, env, s32)
 112DEF_HELPER_2(fitoq, void, env, s32)
 113
 114DEF_HELPER_2(fitos, f32, env, s32)
 115
 116#ifdef TARGET_SPARC64
 117DEF_HELPER_FLAGS_1(fnegd, TCG_CALL_NO_RWG_SE, f64, f64)
 118DEF_HELPER_1(fnegq, void, env)
 119DEF_HELPER_2(fxtos, f32, env, s64)
 120DEF_HELPER_2(fxtod, f64, env, s64)
 121DEF_HELPER_2(fxtoq, void, env, s64)
 122#endif
 123DEF_HELPER_2(fdtos, f32, env, f64)
 124DEF_HELPER_2(fstod, f64, env, f32)
 125DEF_HELPER_1(fqtos, f32, env)
 126DEF_HELPER_2(fstoq, void, env, f32)
 127DEF_HELPER_1(fqtod, f64, env)
 128DEF_HELPER_2(fdtoq, void, env, f64)
 129DEF_HELPER_2(fstoi, s32, env, f32)
 130DEF_HELPER_2(fdtoi, s32, env, f64)
 131DEF_HELPER_1(fqtoi, s32, env)
 132#ifdef TARGET_SPARC64
 133DEF_HELPER_2(fstox, s64, env, f32)
 134DEF_HELPER_2(fdtox, s64, env, f64)
 135DEF_HELPER_1(fqtox, s64, env)
 136
 137DEF_HELPER_FLAGS_2(fpmerge, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 138DEF_HELPER_FLAGS_2(fmul8x16, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 139DEF_HELPER_FLAGS_2(fmul8x16al, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 140DEF_HELPER_FLAGS_2(fmul8x16au, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 141DEF_HELPER_FLAGS_2(fmul8sux16, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 142DEF_HELPER_FLAGS_2(fmul8ulx16, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 143DEF_HELPER_FLAGS_2(fmuld8sux16, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 144DEF_HELPER_FLAGS_2(fmuld8ulx16, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 145DEF_HELPER_FLAGS_2(fexpand, TCG_CALL_NO_RWG_SE, i64, i64, i64)
 146DEF_HELPER_FLAGS_3(pdist, TCG_CALL_NO_RWG_SE, i64, i64, i64, i64)
 147DEF_HELPER_FLAGS_2(fpack16, TCG_CALL_NO_RWG_SE, i32, i64, i64)
 148DEF_HELPER_FLAGS_3(fpack32, TCG_CALL_NO_RWG_SE, i64, i64, i64, i64)
 149DEF_HELPER_FLAGS_2(fpackfix, TCG_CALL_NO_RWG_SE, i32, i64, i64)
 150DEF_HELPER_FLAGS_3(bshuffle, TCG_CALL_NO_RWG_SE, i64, i64, i64, i64)
 151#define VIS_HELPER(name)                                                 \
 152    DEF_HELPER_FLAGS_2(f ## name ## 16, TCG_CALL_NO_RWG_SE,  \
 153                       i64, i64, i64)                                    \
 154    DEF_HELPER_FLAGS_2(f ## name ## 16s, TCG_CALL_NO_RWG_SE, \
 155                       i32, i32, i32)                                    \
 156    DEF_HELPER_FLAGS_2(f ## name ## 32, TCG_CALL_NO_RWG_SE,  \
 157                       i64, i64, i64)                                    \
 158    DEF_HELPER_FLAGS_2(f ## name ## 32s, TCG_CALL_NO_RWG_SE, \
 159                       i32, i32, i32)
 160
 161VIS_HELPER(padd)
 162VIS_HELPER(psub)
 163#define VIS_CMPHELPER(name)                                              \
 164    DEF_HELPER_FLAGS_2(f##name##16, TCG_CALL_NO_RWG_SE,      \
 165                       i64, i64, i64)                                    \
 166    DEF_HELPER_FLAGS_2(f##name##32, TCG_CALL_NO_RWG_SE,      \
 167                       i64, i64, i64)
 168VIS_CMPHELPER(cmpgt)
 169VIS_CMPHELPER(cmpeq)
 170VIS_CMPHELPER(cmple)
 171VIS_CMPHELPER(cmpne)
 172#endif
 173#undef F_HELPER_0_1
 174#undef VIS_HELPER
 175#undef VIS_CMPHELPER
 176DEF_HELPER_1(compute_psr, void, env)
 177DEF_HELPER_1(compute_C_icc, i32, env)
 178
 179#include "exec/def-helper.h"
 180