Florian Hahn
2bdc1a1337
[LV] Use frozen start value for FindLastIV if needed. (#132691)
FindLastIV introduces multiple uses of the start value, where in the
original source there was only a single use, when the epilogue is
vectorized.
Each use of undef may produce a different result, so introducing
multiple uses can produce incorrect results when the input is
undef/poison.
If the start value may be undef or poison, freeze it and use the frozen
value, which will be the same at all uses.
See the following scenarios in Alive2:
* Both main and epilogue vector loops execute, go to exit block: https://alive2.llvm.org/ce/z/_TSvRr
* Both main and epilogue vector loops execute, go to scalar loop: https://alive2.llvm.org/ce/z/CsPj5v
* Only epilogue vector loop executes, go to exit block: https://alive2.llvm.org/ce/z/5XqkNV
* Only epilogue vector loop executes, go to scalar loop: https://alive2.llvm.org/ce/z/JUpqRN
The latter 2 show requiring freezing the resume phi. That means we cannot freeze
in the preheader. We could move the freeze to the main iteration count check, but
that would be a bit fragile to find and other transforms can sink the freeze if needed.
Depends on https://github.com/llvm/llvm-project/pull/132689
and https://github.com/llvm/llvm-project/pull/132690.
Fixes https://github.com/llvm/llvm-project/issues/126836
PR: https://github.com/llvm/llvm-project/pull/132691
2025-04-04 11:48:01 +01:00
..
2025-03-14 15:50:49 +00:00
2025-01-22 14:47:15 +00:00
2025-03-05 18:56:00 +08:00
2025-02-03 08:18:23 +00:00
2025-03-14 15:50:49 +00:00
2025-02-13 15:17:12 +01:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-02-27 08:48:55 +01:00
2025-02-25 14:22:55 +01:00
2025-03-27 10:23:30 +01:00
2025-03-12 08:25:24 -04:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2024-12-25 01:29:01 -08:00
2025-01-14 11:59:41 +00:00
2025-03-14 21:10:22 -07:00
2025-01-03 09:25:08 -08:00
2025-03-14 13:11:45 +01:00
2025-01-29 16:56:47 +01:00
2025-02-13 11:39:02 -08:00
2025-02-28 11:33:44 +01:00
2025-01-29 16:56:47 +01:00
2025-01-04 10:56:45 -08:00
2025-03-18 15:06:39 +01:00
2025-04-01 14:27:11 +01:00
2025-03-21 12:00:22 +05:30
2025-01-29 16:56:47 +01:00
2025-01-22 01:29:12 +00:00
2025-03-28 16:18:49 -07:00
2025-04-02 18:45:33 +08:00
2025-04-03 16:47:36 -07:00
2025-03-13 12:59:57 +01:00
2025-04-01 06:24:59 +07:00
2025-04-03 18:03:16 +01:00
2025-04-03 18:03:16 +01:00
2025-03-11 21:51:28 +00:00
2025-01-29 16:56:47 +01:00
2025-04-01 23:27:20 +07:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-03-07 08:56:44 +01:00
2025-03-11 11:39:21 +08:00
2025-03-14 15:50:49 +00:00
2025-01-27 14:21:14 +00:00
2025-03-24 09:49:31 -04:00
2025-04-03 16:21:19 +09:00
2025-03-25 12:57:24 +00:00
2025-01-29 16:56:47 +01:00
2025-03-14 15:50:49 +00:00
2025-02-21 12:26:39 +01:00
2025-03-29 21:51:59 +08:00
2025-04-04 10:16:50 +01:00
2025-03-29 19:21:34 +00:00
2025-04-04 11:48:01 +01:00
2025-01-14 12:06:22 +00:00
2025-03-12 09:50:50 -07:00
2025-01-29 16:56:47 +01:00
2025-04-02 20:27:43 +01:00
2025-03-14 15:50:49 +00:00
2025-04-03 16:24:56 +01:00
2025-02-27 08:41:28 -08:00
2025-03-14 15:50:49 +00:00
2025-04-04 10:16:40 +01:00
2024-12-12 15:45:44 +13:00
2025-02-06 12:48:52 -06:00
2025-02-14 09:28:57 +01:00
2025-01-29 16:56:47 +01:00
2025-03-07 11:02:52 +00:00
2025-03-18 22:03:26 -07:00
2025-03-31 19:33:40 -04:00
2025-03-27 22:39:11 +00:00
2025-03-14 15:50:49 +00:00
2025-01-29 16:56:47 +01:00
2025-03-14 15:50:49 +00:00
2025-03-24 10:11:55 -07:00
2025-03-29 10:42:51 -07:00
2025-04-01 14:27:11 +01:00
2025-03-14 15:50:49 +00:00
2025-03-18 12:30:20 +01:00
2025-03-14 15:50:49 +00:00
2025-04-02 22:11:17 -07:00
2025-04-03 13:17:40 -07:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-03-18 12:30:20 +01:00
2025-03-10 22:29:15 +07:00
2025-03-14 15:50:49 +00:00
2025-03-14 15:50:49 +00:00
2025-04-03 16:24:56 +01:00
2025-03-13 14:50:41 -07:00
2025-01-27 20:08:53 -08:00