[llvm-commits] [llvm] r49610 - in /llvm/trunk/test/Analysis/BasicAA: const-dce.ll pure-const-dce.ll

Chris Lattner clattner at apple.com
Mon Apr 14 22:23:36 PDT 2008


On Apr 14, 2008, at 6:39 PM, Owen Anderson wrote:

>
> On Apr 14, 2008, at 7:37 PM, Daniel Berlin wrote:
>
>> On Mon, Apr 14, 2008 at 4:24 PM, Dan Gohman <gohman at apple.com> wrote:
>>>
>>>
>>> It looks like the test was testing that two calls with identical
>>> arguments to a readonly function with no intervening stores can
>>> be changed to one call. What's horribly unsafe about that?
>>
>> I don't see anything  unsafe about that either, even though readonly
>> calls can throw exceptions (since they can only depend on arguments
>> and global variables, if the first doesn't throw an exception, and
>> there are no stores/etc, the second can't)
>
> The particular testcase wasn't broken, rather GVN's general  
> functionality for removing read-only calls.  It wasn't doing the  
> appropriate checking for intervening stores to globals.

gcse/loadvn used to do this, is it hard to add back?

-Chris



More information about the llvm-commits mailing list