st/nir: use NIR for asm programs

This uses prog_to_nir to translate ARB assembly programs to NIR.

Co-authored by Tim Arceri, Dave Airlie, and Ken Graunke:

 - [Tim Arceri]: original patch
 - [Dave Airlie]: fix crashes with parameter names
 - [Ken Graunke]:
   - Rebase on SCALAR_ISA cap, lower wpos_ytransform too.
   - Rebase on streamout fixes.
   - Lower system values for fragcoord support.
   - Don't try to use prog_to_nir for ATI_fragment_shader programs.
   - Create TGSI for fixed-function or ARB vertex shaders even if the
     driver prefers NIR, so we can create draw module shaders for
     feedback/select emulation, which rely on TGSI.

Tested on:
- iris (Intel Skylake/Kabylake): Piglit & GL CTS - Ken Graunke
- radeonsi (AMD Vega 64): Piglit - Ken Graunke
- vc4/v3d - Piglit - Eric Anholt
- freedreno - dEQP - Kristian Høgsberg

Fixes lit_degenerate_case on vc4 and v3d, and vp-address-01,
vp-arl-constant-array-huge-offset-neg, and vp-arl-neg-array on v3d.
No Piglit regressions on radeonsi; no dEQP regressions on freedreno.

Acked-by: Eric Anholt <eric@anholt.net>
Tested-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
24 jobs for !262 with st-nir in 23 seconds (queued for 13 seconds)
detached
Status Job ID Name Coverage
  Build+Test
failed #127518
build:make-gallium-drivers-other

00:00:00

failed #127517
build:make-gallium-drivers-radeonsi

00:00:00

failed #127516
build:make-gallium-drivers-swr

00:00:00

failed #127519
build:make-gallium-st-clover-llvm-39

00:00:00

failed #127520
build:make-gallium-st-clover-llvm-4

00:00:00

failed #127521
build:make-gallium-st-clover-llvm-5

00:00:00

failed #127522
build:make-gallium-st-clover-llvm-6

00:00:00

failed #127523
build:make-gallium-st-clover-llvm-7

00:00:00

failed #127524
build:make-gallium-st-other

00:00:00

failed #127515
build:make-loader-classic-dri

00:00:00

failed #127514
build:make-vulkan

00:00:00

failed #127510
build:meson-gallium-clover-llvm5

00:00:01

failed #127511
build:meson-gallium-clover-llvm6

00:00:01

failed #127512
build:meson-gallium-clover-llvm7

00:00:01

failed #127509
build:meson-gallium-drivers-other

00:00:01

failed #127508
build:meson-gallium-radeonsi

00:00:01

failed #127513
build:meson-gallium-st-other

00:00:01

failed #127507
build:meson-gallium-swr

00:00:01

failed #127506
build:meson-glvnd

00:00:01

failed #127505
build:meson-loader-classic-dri

00:00:01

failed #127504
build:meson-vulkan

00:00:01

failed #127526
build:scons-llvm

00:00:00

failed #127525
build:scons-nollvm

00:00:00

failed #127527
build:scons-swr

00:00:00

 
Name Stage Failure
failed
build:scons-nollvm Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:scons-llvm Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-vulkan Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:meson-gallium-clover-llvm6 Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:scons-swr Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:meson-loader-classic-dri Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:meson-glvnd Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:meson-gallium-swr Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:meson-gallium-drivers-other Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:meson-gallium-clover-llvm5 Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:meson-gallium-st-other Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:make-loader-classic-dri Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-drivers-radeonsi Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-drivers-other Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-st-clover-llvm-39 Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-st-clover-llvm-5 Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-st-clover-llvm-6 Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-st-clover-llvm-7 Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-drivers-swr Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-st-clover-llvm-4 Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:make-gallium-st-other Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on fdo-gitlab-gce-runner3 81280d8f
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:0s)
failed
build:meson-vulkan Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:meson-gallium-radeonsi Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)
failed
build:meson-gallium-clover-llvm7 Build+Test
Running with gitlab-runner 11.7.0 (8bb608ff)
on gst-gitlab-htz-runner1 78559e26
Using Docker executor with image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
Pulling docker image registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 ...
ERROR: Job failed: Error response from daemon: manifest for registry.freedesktop.org/kwg/mesa/ubuntu:2019-02-12-01 not found (executor_docker.go:168:1s)