Commit f10dc08e004bf9d96918c5284bbaebb94a2a5c1c

Authored by aurel32
1 parent 1c73fe5b

PPC: add support for TCG helpers

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5094 c046a42c-6fe2-441c-8c8c-71466251a162
target-ppc/helper.h 0 → 100644
  1 +#ifndef DEF_HELPER
  2 +#define DEF_HELPER(ret, name, params) ret name params;
  3 +#endif
  4 +
... ...
target-ppc/translate.c
... ... @@ -26,6 +26,7 @@
26 26 #include "cpu.h"
27 27 #include "exec-all.h"
28 28 #include "disas.h"
  29 +#include "helper.h"
29 30 #include "tcg-op.h"
30 31 #include "qemu-common.h"
31 32  
... ... @@ -65,6 +66,12 @@ void ppc_translate_init(void)
65 66 cpu_T[1] = tcg_global_reg_new(TCG_TYPE_TL, TCG_AREG2, "T1");
66 67 cpu_T[2] = tcg_global_reg_new(TCG_TYPE_TL, TCG_AREG3, "T2");
67 68 #endif
  69 +
  70 + /* register helpers */
  71 +#undef DEF_HELPER
  72 +#define DEF_HELPER(ret, name, params) tcg_register_helper(name, #name);
  73 +#include "helper.h"
  74 +
68 75 done_init = 1;
69 76 }
70 77  
... ...