summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJakob Bornecrantz <[email protected]>2010-08-15 00:59:57 +0100
committerJakob Bornecrantz <[email protected]>2010-08-15 01:06:53 +0100
commitd62b29f567f7dd41d7abf3c931065ea54e90f48b (patch)
treee341bfc9eb94f8a72fbb13fcfb431e85847c13d4 /src
parent7f5202be63c6dc639e57d11ef8253e79dd349f59 (diff)
gallium/docs: Add a debugging section
Diffstat (limited to 'src')
-rw-r--r--src/gallium/docs/source/debugging.rst96
-rw-r--r--src/gallium/docs/source/index.rst1
2 files changed, 97 insertions, 0 deletions
diff --git a/src/gallium/docs/source/debugging.rst b/src/gallium/docs/source/debugging.rst
new file mode 100644
index 00000000000..74f51bc0ea7
--- /dev/null
+++ b/src/gallium/docs/source/debugging.rst
@@ -0,0 +1,96 @@
+Debugging
+=========
+
+Debugging utilities in gallium.
+
+Debug Variables
+^^^^^^^^^^^^^^^
+
+All drivers respond to a couple of debug enviromental variables. Below is
+a collection of them. Set them as you would any normal enviromental variable
+for the platform/operating system you are running. For linux this can be
+done by typing "export var=value" into a console and then running the
+program from that console.
+
+Common
+""""""
+
+GALLIUM_PRINT_OPTIONS <bool> (false)
+
+This options controls if the debug variables should be printed to stderr.
+This is probably the most usefull variable since it allows you to find
+which variables a driver responds to.
+
+GALLIUM_RBUG <bool> (false)
+
+Controls if the :ref:`rbug` should be used.
+
+GALLIUM_TRACE <string> ("")
+
+If not set tracing is not used, if set it will write the output to the file
+specifed by the variable. So setting it to "trace.xml" will write the output
+to the file "trace.xml".
+
+GALLIUM_DUMP_CPU <bool> (false)
+
+Dump information about the current cpu that the driver is running on.
+
+TGSI_PRINT_SANITY <bool> (false)
+
+Gallium has a inbuilt shader sanity checker, this option controls if results
+from it should be printed. This include warnings such as unused variables.
+
+DRAW_USE_LLVM <bool> (false)
+
+Should the :ref:`draw` module use llvm for vertex and geometry shaders.
+
+ST_DEBUG <flags> (0x0)
+
+Debug :ref:`flags` for the GL state tracker.
+
+
+Driver specific
+"""""""""""""""
+
+I915_DEBUG <flags> (0x0)
+
+Debug :ref:`flags` for the i915 driver.
+
+I915_NO_HW <bool> (false)
+
+Stop the i915 driver from submitting commands to the hardware.
+
+I915_DUMP_CMD <bool> (false)
+
+Dump all commands going to the hardware.
+
+LP_DEBUG <flags> (0x0)
+
+Debug :ref:`flags` for the llvmpipe driver.
+
+LP_NUM_THREADS <int> (num cpus)
+
+Number of threads that the llvmpipe driver should use.
+
+
+.. _flags:
+
+Flags
+"""""
+
+The variables of type <flags> all take a string with comma seperated
+flags to enable different debugging for different parts of the drivers
+or state tracker. If set to "help" the driver will print a list of flags
+to which the variable can be set to. Order does not matter.
+
+
+.. _rbug:
+
+Remote Debugger
+^^^^^^^^^^^^^^^
+
+Or rbug for short allows for runtime inspections of :ref:`Context`,
+:ref:`Screen`, Resources and Shaders; pauseing and stepping of draw calls;
+and runtime disable and replacement of shaders. Is used with rbug-gui which
+is hosted outside of the main mesa repositor. Rbug is can be used over a
+network connection so the debbuger does not need to be on the same machine.
diff --git a/src/gallium/docs/source/index.rst b/src/gallium/docs/source/index.rst
index 54bc883fced..6c19842dac4 100644
--- a/src/gallium/docs/source/index.rst
+++ b/src/gallium/docs/source/index.rst
@@ -12,6 +12,7 @@ Contents:
:maxdepth: 2
intro
+ debugging
tgsi
screen
context