diff options
author | David Schleef <ds@schleef.org> | 2009-03-30 00:45:22 +0400 |
---|---|---|
committer | David Schleef <ds@schleef.org> | 2009-05-27 03:55:42 +0400 |
commit | f51924f03fcfac22dad73192b398d413d56a24eb (patch) | |
tree | 716dc561b6cc3d8a1c27b757b22af0e32db12128 /orc-test/orctest.c | |
parent | d506d07f091b32135a8faf3aa4997460cf4e8a79 (diff) |
misalign memory for test
Diffstat (limited to 'orc-test/orctest.c')
-rw-r--r-- | orc-test/orctest.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/orc-test/orctest.c b/orc-test/orctest.c index 51024e9..216bec5 100644 --- a/orc-test/orctest.c +++ b/orc-test/orctest.c @@ -152,22 +152,22 @@ print_array_val_signed (void *array, int size, int i) switch (size) { case 1: { - int8_t *a = array; - printf(" %4d", a[i]); + uint8_t *a = array; + printf(" %4u", a[i]); return a[i]; } break; case 2: { - int16_t *a = array; - printf(" %5d", a[i]); + uint16_t *a = array; + printf(" %5u", a[i]); return a[i]; } break; case 4: { - int32_t *a = array; - printf(" %10d", a[i]); + uint32_t *a = array; + printf(" %10u", a[i]); return a[i]; } break; @@ -370,6 +370,8 @@ orc_test_compare_output (OrcProgram *program) dest_exec = alloc_array (n, program->vars[dest_index].size, &ptr_exec); dest_emul = alloc_array (n, program->vars[dest_index].size, &ptr_emul); + memset (dest_exec, 0xa5, n*program->vars[dest_index].size); + memset (dest_emul, 0xa5, n*program->vars[dest_index].size); orc_executor_set_array (ex, dest_index, dest_exec); orc_executor_run (ex); |