vaibhav
7e59b20034
[SCEV] Support addrec in right hand side in howManyLessThans ( #92560 )
...
Fixes #92554 (std::reverse will auto-vectorize now)
When calculating number of times a exit condition containing a
comparison is executed, we mostly assume that RHS of comparison should
be loop invariant, but it may be another add-recurrence.
~In that case, we can try the computation with `LHS = LHS - RHS` and
`RHS = 0`.~ (It is not valid unless proven that it doesn't wrap)
**Edit:**
We can calculate back edge count for loop structure like:
```cpp
left = left_start
right = right_start
while(left < right){
// ...do something...
left += s1; // the stride of left is s1 (> 0)
right -= s2; // the stride of right is -s2 (s2 > 0)
}
// left and right converge somewhere in the middle of their start values
```
We can calculate the backedge-count as ceil((End - left_start) /u (s1-
(-s2)) where, End = max(left_start, right_start).
**Alive2**: https://alive2.llvm.org/ce/z/ggxx58
2024-06-25 14:33:57 -07:00
..
2024-03-06 13:08:05 -08:00
2022-12-09 01:04:45 +03:00
2024-03-06 13:08:05 -08:00
2022-12-01 21:25:59 +01:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2022-12-01 21:25:59 +01:00
2022-12-15 10:00:45 +01:00
2023-07-05 09:54:28 +02:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2023-05-23 14:41:22 +02:00
2022-12-09 01:04:45 +03:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2024-06-03 13:25:55 +01:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2023-11-14 09:03:54 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-05-20 07:40:54 +02:00
2024-05-23 07:54:08 +02:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2022-12-01 21:25:59 +01:00
2024-03-06 13:08:05 -08:00
2023-02-20 16:12:58 +07:00
2022-12-01 21:25:59 +01:00
2023-06-01 09:46:16 +02:00
2023-11-24 15:49:28 +01:00
2023-06-01 09:46:16 +02:00
2024-03-06 10:24:32 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2024-06-20 15:59:42 +02:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2023-11-03 11:19:14 -07:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2022-12-01 21:25:59 +01:00
2023-05-31 21:05:17 -07:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2023-11-24 15:49:28 +01:00
2022-12-15 10:00:45 +01:00
2023-11-24 15:49:28 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2022-12-16 14:32:36 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2023-02-23 19:59:25 +00:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 08:48:25 -08:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2022-12-01 21:25:59 +01:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2022-12-01 21:25:59 +01:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2023-05-22 20:10:51 +07:00
2023-06-22 15:49:15 +07:00
2024-03-06 10:24:32 -08:00
2024-04-10 09:02:23 -04:00
2024-06-25 14:33:57 -07:00
2024-05-28 16:25:54 -07:00
2023-11-24 15:49:28 +01:00
2024-03-06 10:24:32 -08:00
2023-06-29 09:09:17 +02:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-04-12 18:21:48 +09:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2022-12-15 10:00:45 +01:00
2024-06-05 08:05:07 -07:00
2024-05-30 10:50:32 +08:00
2022-12-01 21:25:59 +01:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2022-12-01 21:25:59 +01:00
2023-03-17 14:27:03 +01:00
2023-06-09 11:51:53 +02:00
2023-06-09 11:51:53 +02:00
2022-12-09 01:04:45 +03:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2023-08-25 05:42:08 +00:00
2023-11-08 11:29:12 +01:00
2022-12-15 10:00:45 +01:00
2023-03-07 17:10:34 +01:00
2022-12-15 10:00:45 +01:00
2023-04-14 19:36:56 +07:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2023-11-24 15:49:28 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2024-06-18 16:31:08 -07:00
2024-03-06 13:08:05 -08:00
2024-06-19 08:59:26 -07:00
2024-03-06 15:57:34 -08:00
2024-03-06 10:24:32 -08:00
2024-03-06 10:24:32 -08:00
2022-12-15 10:00:45 +01:00
2023-04-27 15:07:19 +02:00
2022-12-15 10:00:45 +01:00
2022-12-15 10:00:45 +01:00
2024-03-06 10:24:32 -08:00
2024-03-06 13:08:05 -08:00
2022-12-15 10:00:45 +01:00
2024-03-06 13:08:05 -08:00
2024-03-06 10:24:32 -08:00
2022-12-15 10:00:45 +01:00