ir3: fix oob access to regs array for getbuf,getinfo,rgetinfo

Since they have zero source registers, src->regs[1] is out of bounds.
It probably wasn't able to cause any harm, but it's always better
be safe.

Closes: #4209

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <!9609>
108 jobs for !9609 with ir3/fix/sam-oob-regs-array-access in 20 minutes and 58 seconds (queued for 6 minutes and 16 seconds)
latest detached
Status Job ID Name Coverage
  Sanity
passed #8054397
sanity

00:00:11

 
  Container
passed #8054403
aarch64
arm_build

00:00:17

passed #8054405
arm_test-base

00:00:16

passed #8054407
windows shell 1809 mesa
windows_build_vs2019

00:00:08

passed #8054399
x86_build-base

00:00:25

passed #8054401
x86_test-base

00:00:13

 
  Container 2
passed #8054423
android_build

00:00:13

passed #8054429
arm64_test

00:00:13

passed #8054431
armhf_test

00:00:12

passed #8054418
i386_build

00:00:13

passed #8054410
kernel+rootfs_amd64

00:01:11

passed #8054412
aarch64
kernel+rootfs_arm64

00:00:59

passed #8054414
aarch64
kernel+rootfs_armhf

00:00:10

passed #8054420
ppc64el_build

00:00:18

passed #8054422
s390x_build

00:00:15

passed #8054416
x86_build

00:00:17

passed #8054425
x86_test-gl

00:00:15

passed #8054427
x86_test-vk

00:00:15

 
  Meson X86 64
passed #8054442
meson-clang

00:01:38

passed #8054444
meson-clover

00:02:15

passed #8054436
meson-clover-testing

00:01:07

passed #8054438
gstreamer
meson-gallium

00:02:35

passed #8054440
meson-release

00:01:06

passed #8054433
meson-testing

00:01:47

passed #8054434
meson-testing-asan

00:02:04

passed #8054446
meson-vulkan

00:01:33

 
  Build Misc
passed #8054448
meson-android

00:01:02

passed #8054452
aarch64
meson-arm64

00:01:22

passed #8054455
aarch64
meson-arm64-asan

00:02:54

passed #8054457
aarch64
meson-arm64-build-test

00:01:28

passed #8054450
aarch64
meson-armhf

00:01:41

passed #8054464
meson-i386

00:01:28

passed #8054469
meson-mingw32-x86_64

00:02:22

passed #8054467
kvm
meson-ppc64el

00:02:46

passed #8054465
kvm
meson-s390x

00:03:22

passed #8054461
windows docker 1809 mesa
meson-windows-vs2019

00:04:04

 
  Amd
passed #8054470
radv-fossils

00:12:44

 
  Arm
passed #8054474
mesa-ci-aarch64-lava-collabora
panfrost-g52-gles2:arm64

00:03:57

passed #8054476
mesa-ci-aarch64-lava-collabora
panfrost-g52-gles3:arm64

00:06:44

passed #8054472
mesa-ci-aarch64-lava-collabora
panfrost-t720-gles2:arm64

00:07:37

 
  Broadcom
passed #8054496
igalia-rpi4
v3d-rpi4-gles2:armhf

00:07:20

passed #8054487
igalia-rpi4
v3d-rpi4-gles31:armhf 1/2

00:05:39

passed #8054489
igalia-rpi4
v3d-rpi4-gles31:armhf 2/2

00:06:02

passed #8054491
igalia-rpi4
v3d-rpi4-gles3:armhf 1/4

00:05:52

passed #8054492
igalia-rpi4
v3d-rpi4-gles3:armhf 2/4

00:04:46

passed #8054493
igalia-rpi4
v3d-rpi4-gles3:armhf 3/4

00:05:27

passed #8054495
igalia-rpi4
v3d-rpi4-gles3:armhf 4/4

00:04:35

passed #8054497
igalia-rpi4
v3dv-rpi4-vk:armhf 1/6

00:07:02

passed #8054499
igalia-rpi4
v3dv-rpi4-vk:armhf 2/6

00:07:12

passed #8054500
igalia-rpi4
v3dv-rpi4-vk:armhf 3/6

00:07:12

passed #8054501
igalia-rpi4
v3dv-rpi4-vk:armhf 4/6

00:07:28

passed #8054503
igalia-rpi4
v3dv-rpi4-vk:armhf 5/6

00:08:27

passed #8054505
igalia-rpi4
v3dv-rpi4-vk:armhf 6/6

00:07:11

passed #8054479
igalia-rpi3
vc4-rpi3-gles2:armhf 1/4

00:04:30

passed #8054481
igalia-rpi3
vc4-rpi3-gles2:armhf 2/4

00:04:31

passed #8054483
igalia-rpi3
vc4-rpi3-gles2:armhf 3/4

00:04:25

passed #8054485
igalia-rpi3
vc4-rpi3-gles2:armhf 4/4

00:04:11

 
  Freedreno
passed #8054507
google-freedreno-db410c
a306_gles2

00:04:45

passed #8054509
google-freedreno-db410c
a306_gles3 1/3

00:08:43

passed #8054510
google-freedreno-db410c
a306_gles3 2/3

00:08:49

passed #8054511
google-freedreno-db410c
a306_gles3 3/3

00:08:46

passed #8054513
google-freedreno-db410c
a306_gles3_options

00:03:52

passed #8054514
google-freedreno-db820c
a530_gles2

00:05:26

passed #8054517
google-freedreno-db820c
a530_gles31 1/2

00:08:12

passed #8054515
google-freedreno-db820c
a530_gles3 1/2

00:09:26

passed #8054518
google-freedreno-db820c
a530_gles31 2/2

00:07:14

passed #8054516
google-freedreno-db820c
a530_gles3 2/2

00:07:47

passed #8054519
google-freedreno-db820c
a530_piglit_gl

00:10:39

passed #8054520
google-freedreno-db820c
a530_piglit_shader

00:09:35

passed #8054524
google-freedreno-cheza
a630_gl

00:02:36

passed #8054521
google-freedreno-cheza
a630_gles2

00:02:49

passed #8054523
google-freedreno-cheza
a630_gles3

00:06:03

passed #8054522
google-freedreno-cheza
a630_gles31

00:05:19

passed #8054526
google-freedreno-cheza
a630_gles_asan

00:04:08

passed #8054525
google-freedreno-cheza
a630_gles_others

00:03:57

passed #8054530
google-freedreno-cheza
a630_piglit_gl

00:06:26

passed #8054531
google-freedreno-cheza
a630_piglit_shader

00:05:16

passed #8054532
google-freedreno-cheza
a630-traces

00:06:56

passed #8054527
google-freedreno-cheza
a630_vk 1/2

00:07:53

passed #8054528
google-freedreno-cheza
a630_vk 2/2

00:08:08

passed #8054529
google-freedreno-cheza
a630_vk_sysmem

00:02:15

 
  Software Renderer
passed #8054539
lavapipe-vk

00:02:24

passed #8054538
llvmpipe-gles2

00:00:58

passed #8054533
llvmpipe-piglit-cl

00:01:45

passed #8054535
llvmpipe-piglit-glslparser

00:04:06

passed #8054534
llvmpipe-piglit-quick_gl

00:07:27

passed #8054536
llvmpipe-piglit-quick_shader

00:05:39

passed #8054537
llvmpipe-traces

00:01:12

passed #8054544
softpipe-asan-gles31

00:03:01

passed #8054546
softpipe-gl

00:01:09

passed #8054540
softpipe-gles2

00:01:23

passed #8054541
softpipe-gles3

00:09:13

passed #8054542
softpipe-gles31 1/2

00:06:17

passed #8054543
softpipe-gles31 2/2

00:05:36

passed #8054545
softpipe-piglit-quick

00:09:36

 
  Layered Backends
passed #8054559
windows docker 1809 mesa
test-d3d12-windows

00:03:11

passed #8054551
virgl-gl30-on-gl

00:00:36

passed #8054552
virgl-gl31-on-gl

00:02:17

passed #8054553
virgl-gl32-on-gl

00:02:15

passed #8054547
virgl-gles2-on-gl

00:02:40

passed #8054549
virgl-gles31-on-gl 1/2

00:04:57

passed #8054550
virgl-gles31-on-gl 2/2

00:05:33

passed #8054548
virgl-gles3-on-gl

00:05:46

passed #8054554
virgl-traces

00:00:43

passed #8054558
zink-lvp-gl

00:01:09

passed #8054556
zink-lvp-gles2

00:03:05

passed #8054557
zink-lvp-gles3

00:02:23

passed #8054555
zink-piglit-quick_gl

00:09:17