ppc64: Arguments to iselInt128Expr_to_32x4 should be initialized.
[valgrind.git] / memcheck / tests / clientperm.c
blobac7574788d2480ea784d03963b21c9cccb7d7d92
2 #include <stdio.h>
3 #include <stdlib.h>
5 #include "../memcheck.h"
7 int main1 ( void )
9 int xxx, i;
10 for (i = 0; i < 10; i++) (void) VALGRIND_CHECK_VALUE_IS_DEFINED(xxx);
11 return 0;
14 int main ( void )
16 int i, sum, m;
17 char* aa = calloc(100,1);
18 sum = 0;
20 (void) VALGRIND_CHECK_MEM_IS_DEFINED(aa,100);
22 m = VALGRIND_MAKE_MEM_UNDEFINED( &aa[49], 1 );
23 (void) VALGRIND_CHECK_MEM_IS_ADDRESSABLE(aa,100);
25 printf("m_na: returned value is %d\n", m );
27 for (i = 0; i < 100; i++)
28 sum += aa[i];
29 printf("sum is %s\n", sum > 0 ? "positive" : "non-positive");
31 m = VALGRIND_DISCARD(m);
32 printf("m_rm: returned value is %d\n", m );
34 for (i = 0; i < 100; i++)
35 sum += aa[i];
36 printf("sum is %s\n", sum > 0 ? "positive" : "non-positive");
38 return 0;