diff options
Diffstat (limited to 'libffi/testsuite/libffi.call/cls_2byte.c')
-rw-r--r-- | libffi/testsuite/libffi.call/cls_2byte.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/libffi/testsuite/libffi.call/cls_2byte.c b/libffi/testsuite/libffi.call/cls_2byte.c index 512952cc0c2..2198ee821cb 100644 --- a/libffi/testsuite/libffi.call/cls_2byte.c +++ b/libffi/testsuite/libffi.call/cls_2byte.c @@ -6,7 +6,7 @@ PR: none. Originator: <andreast@gcc.gnu.org> 20030828 */ -/* { dg-do run } */ +/* { dg-do run { xfail mips*-*-* arm*-*-* strongarm*-*-* xscale*-*-* } } */ #include "ffitest.h" typedef struct cls_struct_2byte { @@ -27,10 +27,10 @@ cls_struct_2byte cls_struct_2byte_fn(struct cls_struct_2byte a1, return result; } -static void +static void cls_struct_2byte_gn(ffi_cif* cif, void* resp, void** args, void* userdata) -{ - +{ + struct cls_struct_2byte a1, a2; a1 = *(struct cls_struct_2byte*)(args[0]); @@ -57,16 +57,16 @@ int main (void) struct cls_struct_2byte g_dbl = { 12, 127 }; struct cls_struct_2byte f_dbl = { 1, 13 }; struct cls_struct_2byte res_dbl; - + cls_struct_fields[0] = &ffi_type_uchar; cls_struct_fields[1] = &ffi_type_uchar; cls_struct_fields[2] = NULL; - + dbl_arg_types[0] = &cls_struct_type; dbl_arg_types[1] = &cls_struct_type; dbl_arg_types[2] = NULL; - - CHECK(ffi_prep_cif(&cif, FFI_DEFAULT_ABI, 2, &cls_struct_type, + + CHECK(ffi_prep_cif(&cif, FFI_DEFAULT_ABI, 2, &cls_struct_type, dbl_arg_types) == FFI_OK); args_dbl[0] = &g_dbl; @@ -79,7 +79,7 @@ int main (void) CHECK( res_dbl.b == (g_dbl.b + f_dbl.b)); CHECK(ffi_prep_closure(pcl, &cif, cls_struct_2byte_gn, NULL) == FFI_OK); - + res_dbl = ((cls_struct_2byte(*)(cls_struct_2byte, cls_struct_2byte))(pcl))(g_dbl, f_dbl); /* { dg-output "\n12 127 1 13: 13 140" } */ CHECK( res_dbl.a == (g_dbl.a + f_dbl.a)); |