From 62ca7b85ae1f7d914156a9b376d0520db85ba495 Mon Sep 17 00:00:00 2001 From: Corbin Simpson Date: Tue, 2 Feb 2010 16:36:34 -0800 Subject: gallium/docs: Start turning notes into docs. Yeah, what's that? You can read it? It's got, hmm, *readability*? Nice, ain't it. :3 --- src/gallium/docs/source/tgsi.rst | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) (limited to 'src') diff --git a/src/gallium/docs/source/tgsi.rst b/src/gallium/docs/source/tgsi.rst index 34d80da1d34..7e6dce99538 100644 --- a/src/gallium/docs/source/tgsi.rst +++ b/src/gallium/docs/source/tgsi.rst @@ -6,6 +6,19 @@ for describing shaders. Since Gallium is inherently shaderful, shaders are an important part of the API. TGSI is the only intermediate representation used by all drivers. +Basics +------ + +All TGSI instructions, known as *opcodes*, operate on arbitrary-precision +floating-point four-component vectors. An opcode may have up to one +destination register, known as *dst*, and between zero and three source +registers, called *src0* through *src2*, or simply *src* if there is only +one. + +Some instructions, like :opcode:`I2F`, permit re-interpretation of vector +components as integers. Other instructions permit using registers as +two-component vectors with double precision; see :ref:`Double Opcodes`. + Instruction Set --------------- @@ -1111,6 +1124,8 @@ ps_2_x TBD +.. _doubleopcodes: + Double Opcodes ^^^^^^^^^^^^^^^ @@ -1269,20 +1284,8 @@ Keywords discard Discard fragment. - dst First destination register. - - dst0 First destination register. - pc Program counter. - src First source register. - - src0 First source register. - - src1 Second source register. - - src2 Third source register. - target Label of target instruction. -- cgit v1.2.3