All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC 0/9] Add precise/invariant semantics to TGSI
@ 2017-06-11 18:42 Karol Herbst
  2017-06-11 18:42 ` [RFC 3/9] st/glsl_to_tgsi: handle precise modifier Karol Herbst
                   ` (2 more replies)
  0 siblings, 3 replies; 19+ messages in thread
From: Karol Herbst @ 2017-06-11 18:42 UTC (permalink / raw)
  To: mesa-dev; +Cc: nouveau

Running Tomb Raider on Nouveau I found some flicker caused by ignoring precise
modifiers on variables inside Nouveau.

This series add precise/invariant handling to TGSI, which can be then used by
drivers to disable certain unsafe optimisations which may otherwise alter
calculations, which depend on having the same result across shaders.

This series fixes this bug in Tomb Raider and one CTS test for 4.4 and 4.5

Note on Patch 3: I really dislike how I tell glsl_to_tgsi_visitor to apply the
precise flag on instruction emited in ir_assignment->rhs->accept(); but I found
no other easy way to handle this. Maybe somebody of you has a better idea?

Karol Herbst (9):
  tgsi: add precise flag to tgsi_instruction
  tgsi/dump: print _PRECISE modifier on Instrutions
  st/glsl_to_tgsi: handle precise modifier
  tgsi: populate precise
  tgsi/text: parse _PRECISE modifier
  nv50/ir: add precise field to Instruction
  nv50/ir/tgsi: handle precise for most ALU instructions
  nv50/ir: disable mul+add to mad for precise instructions
  nv50/ir/tgsi: split mad to mul+add

 src/gallium/auxiliary/tgsi/tgsi_build.c            |  4 +
 src/gallium/auxiliary/tgsi/tgsi_dump.c             |  4 +
 src/gallium/auxiliary/tgsi/tgsi_text.c             | 15 +++-
 src/gallium/auxiliary/tgsi/tgsi_ureg.c             | 14 +++-
 src/gallium/auxiliary/tgsi/tgsi_ureg.h             | 20 ++++-
 src/gallium/auxiliary/util/u_simple_shaders.c      |  2 +-
 src/gallium/drivers/nouveau/codegen/nv50_ir.h      |  1 +
 .../drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp  | 16 ++++
 .../drivers/nouveau/codegen/nv50_ir_peephole.cpp   |  6 +-
 src/gallium/include/pipe/p_shader_tokens.h         |  3 +-
 src/gallium/state_trackers/nine/nine_shader.c      |  6 +-
 src/mesa/state_tracker/st_atifs_to_tgsi.c          | 38 ++++-----
 src/mesa/state_tracker/st_glsl_to_tgsi.cpp         | 92 +++++++++++++++++-----
 src/mesa/state_tracker/st_mesa_to_tgsi.c           |  8 +-
 src/mesa/state_tracker/st_pbo.c                    |  2 +-
 15 files changed, 172 insertions(+), 59 deletions(-)

-- 
2.13.1

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2017-06-13 15:06 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-11 18:42 [RFC 0/9] Add precise/invariant semantics to TGSI Karol Herbst
2017-06-11 18:42 ` [RFC 3/9] st/glsl_to_tgsi: handle precise modifier Karol Herbst
     [not found]   ` <20170611184239.7204-4-karolherbst-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-06-12 10:41     ` [Mesa-dev] " Nicolai Hähnle
     [not found] ` <20170611184239.7204-1-karolherbst-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-06-11 18:42   ` [RFC 1/9] tgsi: add precise flag to tgsi_instruction Karol Herbst
2017-06-11 18:42   ` [RFC 2/9] tgsi/dump: print _PRECISE modifier on Instrutions Karol Herbst
2017-06-11 18:42   ` [RFC 4/9] tgsi: populate precise Karol Herbst
     [not found]     ` <20170611184239.7204-5-karolherbst-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-06-12 10:33       ` [Mesa-dev] " Nicolai Hähnle
2017-06-11 18:42   ` [RFC 5/9] tgsi/text: parse _PRECISE modifier Karol Herbst
2017-06-12 10:31     ` Nicolai Hähnle
2017-06-11 18:42   ` [RFC 6/9] nv50/ir: add precise field to Instruction Karol Herbst
2017-06-11 18:42   ` [RFC 7/9] nv50/ir/tgsi: handle precise for most ALU instructions Karol Herbst
2017-06-11 18:42   ` [RFC 8/9] nv50/ir: disable mul+add to mad for precise instructions Karol Herbst
2017-06-12 10:42   ` [Mesa-dev] [RFC 0/9] Add precise/invariant semantics to TGSI Nicolai Hähnle
2017-06-12 23:57     ` Roland Scheidegger
2017-06-13  0:01       ` Roland Scheidegger
     [not found]       ` <8a99cdc6-c415-1423-dd1b-13a09f902288-pghWNbHTmq7QT0dZR+AlfA@public.gmane.org>
2017-06-13  0:05         ` [Mesa-dev] " Ilia Mirkin
     [not found]           ` <CAKb7UviKiLbRG+z4paq8=-6epuWtKSxty2DHw6SQ1LZ+ULQgmw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-06-13  0:33             ` Roland Scheidegger
     [not found]               ` <6ffa13fd-c90b-bda6-b243-13c4857346f7-pghWNbHTmq7QT0dZR+AlfA@public.gmane.org>
2017-06-13 15:06                 ` Marek Olšák
2017-06-11 18:42 ` [RFC 9/9] nv50/ir/tgsi: split mad to mul+add Karol Herbst

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.