lkml.org 
[lkml]   [2009]   [Dec]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] ARM: Convert BUG() to use unreachable()
On 12/17/2009 06:17 PM, Richard Guenther wrote:
> It shouldn't as *(int *)0 = 0; might trap. But if you want to be sure
> use
> __builtin_trap ();
> instead for the whole sequence (the unreachable is implied then).
> GCC choses a size-optimal trap representation for your target then.

Agree that it shouldn't but just to be sure I'd use

*(volatile int *)0 = 0;
unreachable ();

Paolo


\
 
 \ /
  Last update: 2009-12-22 12:35    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site