gcc-patches@gcc.gnu.org
[Top] [All Lists]

Re: [PATCH] Add new built-in: __builtin_unreachable()

Subject: Re: [PATCH] Add new built-in: __builtin_unreachable()
From: Paolo Bonzini
Date: Mon, 15 Jun 2009 10:15:45 +0200

Could you explain why it is allowed to remove the trapping instruction?

If this were java (which admittedly it is not), that would not be allowed.

Because of -fdelete-null-pointer-checks. Without non-call exceptions, *f does not throw an exception but still the compiler is allowed to assume its address is not null in anything that postdominates it. Admittedly this case is a bit borderline.

Paolo

<Prev in Thread] Current Thread [Next in Thread>