[PATCH] Avoid FP conversions when calling bitcasted / alias functions
Eli Friedman
eli.friedman at gmail.com
Fri Jul 26 17:32:30 PDT 2013
On Fri, Jul 26, 2013 at 5:15 PM, Matt Arsenault <arsenm2 at gmail.com> wrote:
>
> On Jul 26, 2013, at 17:04 , Eli Friedman <eli.friedman at gmail.com> wrote:
>
>> Something weird happened to the diff.
>>
>> Does it really make sense to zext and/or trunc the input here?
>>
> Sort of? I didn't really get why this code is here in the first place. I wast trying to preserve what it did except for the floating point part. It tries its best to call the underlying function with something valid when the types don't match. opt -lint says this is undefined (which should probably be fixed, since there are already other tests that check for specific behaviors here)
IIRC, the care we really care about is the case where we have two
pointers with a mismatched pointee type; that can happen legitimately
with LTO, and we really want to eliminate the bitcast if possible.
What we do in other cases doesn't matter as much... arguably, we
should be conservative.
-Eli
More information about the llvm-commits
mailing list