Peter Waller
ade47bdc31
[LV] Improve register pressure estimate at high VFs
...
Previously, `getRegUsageForType` was implemented using
`getTypeLegalizationCost`. `getRegUsageForType` is used by the loop
vectorizer to estimate the register pressure caused by using a vector
type. However, `getTypeLegalizationCost` currently only appears to
understand splitting and not scalarization, so significantly
underestimates the register requirements.
Instead, use `getNumRegisters`, which understands when scalarization
can occur (via computeRegisterProperties).
This was discovered while investigating D118979 (Set maximum VF with
shouldMaximizeVectorBandwidth), where under fixed-length 512-bit SVE the
loop vectorizer previously ends up costing an v128i1 as 2 v64i*
registers where it actually occupies 128 i32 registers.
I'm sending this patch early for comment, I'm still doing some sanity checking
with LNT. I note that getRegisterClassForType appears to return VectorRC even
though the type in question (large vNi1 types) end up occupying scalar
registers. That might be worth fixing too.
Differential Revision: https://reviews.llvm.org/D125918
2022-05-23 07:57:45 +00:00
..
2022-05-23 07:57:45 +00:00
2022-04-08 17:46:49 -07:00
2022-05-16 15:27:22 +01:00
2022-05-20 09:58:40 +01:00
2022-05-16 09:14:24 +01:00
2022-04-04 01:15:30 +02:00
2022-05-23 07:57:45 +00:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2021-12-13 16:56:22 -08:00
2022-03-09 17:50:34 -05:00
2022-05-22 20:11:47 +01:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-05-10 12:17:09 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-01-05 10:46:06 +00:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-05-20 09:58:40 +01:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-05-21 16:01:38 +01:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-05-21 16:01:38 +01:00
2022-05-16 15:27:22 +01:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2021-11-24 16:20:35 +00:00
2022-05-16 15:27:22 +01:00
2022-04-28 16:46:00 +02:00
2022-01-08 20:46:31 +00:00
2021-10-18 16:48:10 -07:00
2022-04-04 01:15:30 +02:00
2022-04-19 13:06:39 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2021-12-20 15:10:41 +00:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2021-05-24 19:43:40 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-07 23:21:21 +02:00
2022-05-16 16:30:26 +02:00
2022-05-21 16:01:38 +01:00
2022-04-28 16:46:00 +02:00
2022-05-15 15:51:26 +01:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2021-12-13 16:56:22 -08:00
2022-04-04 01:15:30 +02:00
2021-06-17 09:38:28 +02:00
2021-12-13 16:56:22 -08:00
2021-12-13 16:56:22 -08:00
2022-05-21 16:01:38 +01:00
2022-04-04 01:15:30 +02:00
2021-08-05 14:39:08 +01:00
2022-05-22 18:27:41 +01:00
2022-03-07 19:32:37 +03:00
2021-12-13 16:56:22 -08:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-02-23 15:57:39 +00:00
2021-12-20 16:23:29 +00:00
2021-09-15 10:45:50 +01:00
2021-05-24 19:43:40 +02:00
2022-05-16 15:27:22 +01:00
2021-10-18 18:03:09 +01:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-05-16 15:27:22 +01:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-03-07 19:32:37 +03:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-03-07 19:32:37 +03:00
2022-05-21 16:01:38 +01:00
2022-04-04 01:15:30 +02:00
2022-05-20 09:58:40 +01:00
2022-02-09 20:02:54 +00:00
2021-06-07 10:47:52 +01:00
2021-06-07 10:47:52 +01:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-02 19:34:32 +01:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2021-09-18 20:51:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-05-15 21:52:07 +01:00
2022-05-21 16:01:38 +01:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-02-24 09:01:20 +01:00
2022-02-22 12:04:35 +00:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-02-24 09:01:20 +01:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-05-19 20:36:46 +01:00
2021-05-11 14:32:34 +01:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-05-16 15:27:22 +01:00
2022-05-16 15:27:22 +01:00
2022-05-16 15:27:22 +01:00
2022-05-16 15:27:22 +01:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2021-08-10 08:27:43 +01:00
2022-03-13 17:15:24 +00:00
2021-08-06 10:13:15 +01:00
2022-05-16 15:27:22 +01:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2021-10-27 22:21:37 +03:00
2022-04-04 01:15:30 +02:00
2021-11-18 14:08:57 +00:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-05-16 15:27:22 +01:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2021-06-07 10:47:52 +01:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-04-28 16:46:00 +02:00
2022-03-07 19:32:37 +03:00
2022-05-19 12:28:01 +08:00
2021-12-13 16:56:22 -08:00
2022-01-24 13:04:09 +00:00
2022-04-28 16:46:00 +02:00
2022-04-04 01:15:30 +02:00
2022-04-09 14:19:47 +02:00
2022-04-04 01:15:30 +02:00
2022-05-21 16:01:38 +01:00
2022-04-20 19:34:41 +01:00
2022-04-19 13:06:39 +02:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-04-04 01:15:30 +02:00
2022-04-28 16:46:00 +02:00