[PATCH] D34069: [DAGCombiner] Fix PR33368 (vector extend/truncate optimization)

Wolfgang Pieb via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 28 15:03:06 PDT 2017


wolfgangp added a comment.

In https://reviews.llvm.org/D34069#794414, @zvi wrote:

> Hi @wolfgangp,
>
> I'm afraid that https://reviews.llvm.org/D34076 adds a combine which replaces the BUILD_VECTOR with a TRUNCATE, so if https://reviews.llvm.org/D34076 will be applied, the test-case in this commit will no longer be covering the bug this commit fixes.
>  Do you have a suggestion for an alternative test case?


Unfortunately not. It may not be possible to create a test case that is sufficiently insulated from future changes to DAGCombine. The only thing that sounds reasonable would be a unit test for the specific routine that had the bug. That would probably be immune against other optimizations, but I'm not even sure that the infrastructure for DAGCombine unit tests exists. In any case, I would be happy with updating the test case to reflect the code that is generated with the new optimization in place, since it will still demonstrate that the right code is generated.


Repository:
  rL LLVM

https://reviews.llvm.org/D34069





More information about the llvm-commits mailing list