testsuite: Add trivial tests for Go closures

This commit is contained in:
Richard Henderson
2014-11-14 13:04:33 +01:00
parent c952a92e20
commit c9f5b6648b
5 changed files with 118 additions and 0 deletions

View File

@@ -0,0 +1,19 @@
#ifdef __aarch64__
# define STATIC_CHAIN_REG "x18"
#elif defined(__alpha__)
# define STATIC_CHAIN_REG "r1"
#elif defined(__arm__)
# define STATIC_CHAIN_REG "ip"
#elif defined(__sparc__)
# if defined(__arch64__) || defined(__sparcv9)
# define STATIC_CHAIN_REG "g5"
# else
# define STATIC_CHAIN_REG "g2"
# endif
#elif defined(__x86_64__)
# define STATIC_CHAIN_REG "r10"
#elif defined(__i386__)
# ifndef ABI_NUM
# define STATIC_CHAIN_REG "ecx" /* FFI_DEFAULT_ABI only */
# endif
#endif