- "*(int *)0 = " is apparently ignored by LLVM for who-knows-why
reason. Cast the zero to a volatile int * instead.
- remove an unused function that gcc failed to mention was unused
(why? because it was marked __attribute__((noreturn)) ?)
As an aside, clang/llvm-2.8 seemed to be able to successfully
compile Valgrind.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11429
return &c->region_start_img[ c->region_next ];
}
-__attribute__((noreturn))
-static void failWith ( Cursor* c, HChar* str ) {
- vg_assert(c);
- vg_assert(c->barf);
- c->barf(str);
- /*NOTREACHED*/
- vg_assert(0);
-}
-
/* FIXME: document assumptions on endianness for
get_UShort/UInt/ULong. */
static inline UChar get_UChar ( Cursor* c ) {
{
VALGRIND_PRINTF_BACKTRACE("Program aborting because of call to %s\n", str);
_exit(99);
- *(int *)0 = 'x';
+ *(volatile int *)0 = 'x';
}
#define PANIC(soname, fnname) \
VG_USERREQ__LIBC_FREERES_DONE,
0, 0, 0, 0, 0);
/*NOTREACHED*/
- *(int *)0 = 'x';
+ *(volatile int *)0 = 'x';
}
/* ---------------------------------------------------------------------