nir/algebraic: add some half packing optimizations

pipeline-db (ACO):
Totals from affected shaders:
SGPRS: 29200 -> 29200 (0.00 %)
VGPRS: 17372 -> 17372 (0.00 %)
Spilled SGPRs: 105 -> 105 (0.00 %)
Spilled VGPRs: 0 -> 0 (0.00 %)
Private memory VGPRs: 0 -> 0 (0.00 %)
Scratch size: 0 -> 0 (0.00 %) dwords per thread
Code Size: 1406576 -> 1389256 (-1.23 %) bytes
LDS: 83 -> 83 (0.00 %) blocks
Max Waves: 3976 -> 3976 (0.00 %)

pipeline-db (LLVM):
Totals from affected shaders:
SGPRS: 21320 -> 21320 (0.00 %)
VGPRS: 17056 -> 17036 (-0.12 %)
Spilled SGPRs: 22 -> 22 (0.00 %)
Spilled VGPRs: 503 -> 487 (-3.18 %)
Private memory VGPRs: 0 -> 0 (0.00 %)
Scratch size: 396 -> 396 (0.00 %) dwords per thread
Code Size: 1441244 -> 1423292 (-1.25 %) bytes
LDS: 463 -> 463 (0.00 %) blocks
Max Waves: 3609 -> 3611 (0.06 %)

v2: add pattern for ishr

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
46 jobs for !2271 with nir_bf2_opts in 45 minutes and 8 seconds (queued for 5 seconds)
latest detached
Status Job ID Name Coverage
  Containers
passed #719794
debian-10

00:00:21

passed #719795
debian-9

00:00:23

passed #719793
lava-container:arm64

00:00:23

passed #719792
lava-container:armhf

00:00:18

passed #719796
aarch64
test-container:arm64

00:00:19

 
  Build
passed #719798
lava-build:arm64

00:04:54

passed #719797
lava-build:armhf

00:05:05

passed #719801
meson-arm64

00:04:50

passed #719800
meson-armhf

00:03:47

passed #719803
meson-clang

00:08:35

passed #719806
meson-clover

00:06:11

passed #719807
meson-clover-old-llvm

00:05:12

passed #719809
meson-i386

00:04:20

passed #719799
meson-main

00:03:32

passed #719802
meson-swr-glvnd

00:05:56

passed #719808
meson-vulkan

00:01:11

passed #719810
scons

00:10:46

passed #719811
scons-old-llvm

00:08:28

passed #719804
scons-swr

00:05:46

passed #719805
scons-win64

00:08:59

 
  Test
passed #719834
db410c
arm64_a306_gles2 1/4

00:08:05

passed #719835
db410c
arm64_a306_gles2 2/4

00:09:12

passed #719836
db410c
arm64_a306_gles2 3/4

00:08:06

passed #719837
db410c
arm64_a306_gles2 4/4

00:03:47

passed #719823
mesa-cheza
arm64_a630_gles2

00:04:07

passed #719824
mesa-cheza
arm64_a630_gles31 1/4

00:03:45

passed #719825
mesa-cheza
arm64_a630_gles31 2/4

00:04:40

passed #719826
mesa-cheza
arm64_a630_gles31 3/4

00:04:37

passed #719827
mesa-cheza
arm64_a630_gles31 4/4

00:04:34

passed #719828
mesa-cheza
arm64_a630_gles3 1/6

00:03:47

passed #719829
mesa-cheza
arm64_a630_gles3 2/6

00:03:49

passed #719830
mesa-cheza
arm64_a630_gles3 3/6

00:03:33

passed #719831
mesa-cheza
arm64_a630_gles3 4/6

00:03:47

passed #719832
mesa-cheza
arm64_a630_gles3 5/6

00:03:25

passed #719833
mesa-cheza
arm64_a630_gles3 6/6

00:03:50

passed #719812
lava-rk3288-veyron-jaq
panfrost-t760-test:armhf

00:06:18

passed #719813
lava-rk3399-gru-kevin
panfrost-t860-test:arm64

00:08:55

passed #719814
test-llvmpipe-gles2 1/4

00:03:57

passed #719815
test-llvmpipe-gles2 2/4

00:04:07

passed #719816
test-llvmpipe-gles2 3/4

00:03:39

passed #719817
test-llvmpipe-gles2 4/4

00:03:57

passed #719818
test-softpipe-gles2 1/4

00:01:28

passed #719819
test-softpipe-gles2 2/4

00:01:41

passed #719820
test-softpipe-gles2 3/4

00:01:34

passed #719821
test-softpipe-gles2 4/4

00:01:35

passed #719822
test-softpipe-gles3-limited

00:04:30