[PATCH] [Instcombine] Recognize test for overflow in integer multiplication.

Serge Pavlov sepavloff at gmail.com
Tue Apr 1 07:54:43 PDT 2014


Yes, good catch. Must be:

Mask = Mask.trunc(MulWidth);

Thanks!


2014-04-01 21:40 GMT+07:00 Erik Verbruggen <erik.verbruggen at me.com>:

>
>   I also did a patch for PR4917, but yours looks more complete. I have
> some different tests, and I'll see how they compare against this. Will
> probably do that tomorrow (CEST).
>
>   Nitpick: I applied this patch on top of r205314, and I get the following
> warning:
>
>
> /Users/erik/dev/clang-llvm/llvm-git/lib/Transforms/InstCombine/InstCombineCompares.cpp:2204:9:
> warning: ignoring return value of function declared with
>         warn_unused_result attribute [-Wunused-result]
>           Mask.trunc(MulWidth);
>           ^~~~~~~~~~ ~~~~~~~~
>
> http://llvm-reviews.chandlerc.com/D2814
>



-- 
Thanks,
--Serge
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140401/faf3dd16/attachment.html>


More information about the llvm-commits mailing list