[PATCH] D18528: Don't fold double constant to an integer if dest type not integral

Ahmed Bougacha via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 30 14:52:23 PDT 2016


ab added a comment.

In http://reviews.llvm.org/D18528#385777, @tejohnson wrote:

> Thanks for the review!
>
> > LGTM, but the test shouldn't be in CodeGen. It's not great either, but what about Transforms/EarlyCSE?
>
>
> The bug isn't specific to EarlyCSE either (I originally found this when folding was invoked from the inliner). I wasn't sure where to put this but there are already a bunch of X86 constant folding tests in CodeGen/X86. It seemed consistent with past tests to put it there. Ok if I leave it there?


Yeah, I know :/
Looking at the history of ConstantFold.cpp, most changes seem to add a test to the relevant transform directory.  The closest to dedicated tests seem to be Assembler/ConstantExpr*Fold*.ll.


http://reviews.llvm.org/D18528





More information about the llvm-commits mailing list