Lines Matching +full:llvmpipe +full:- +full:traces
1 LLVMpipe title
5 ------------
7 The Gallium LLVMpipe driver is a software rasterizer that uses LLVM to
10 to x86, x86-64, or ppc64le machine code. Also, the driver is
15 ------------
17 - For x86 or amd64 processors, 64-bit mode is recommended. Support for
25 Vector-Scalar Facility) is recommended if supported AND Mesa is built
30 - Unless otherwise stated, LLVM version 3.9 or later is required.
34 .. code-block:: sh
36 aptitude install llvm-dev
43 For a RPM-based distribution do:
45 .. code-block:: sh
47 yum install llvm-devel
50 … the Copr repository at `fedora-llvm-team/llvm-snapshots <https://copr.fedorainfracloud.org/coprs/…
58 ``-DLLVM_USE_CRT_xxx=yyy`` as described below.
61 +-----------------+----------------------------------------------------------------+
62 | LLVM build-type | Mesa build-type |
63 | +--------------------------------+-------------------------------+
66 | Debug | ``-DLLVM_USE_CRT_DEBUG=MTd`` | ``-DLLVM_USE_CRT_DEBUG=MT`` |
67 +-----------------+--------------------------------+-------------------------------+
68 | Release | ``-DLLVM_USE_CRT_RELEASE=MTd`` | ``-DLLVM_USE_CRT_RELEASE=MT`` |
69 +-----------------+--------------------------------+-------------------------------+
72 ``-DLLVM_TARGETS_TO_BUILD=X86`` to CMake.
75 --------
79 .. code-block:: sh
83 meson -D glx=xlib -D gallium-drivers=swrast
90 llvmpipe, and then create a wrap file so the meson knows where to
97 .. code-block:: sh
99 cmake ../llvm-project-18.1.1.src/llvm \
100 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_NDK_ROOT}/build/cmake/android.toolchain.cmake \
101 -DANDROID_ABI=x86_64 \
102 -DANDROID_PLATFORM=android-23 \
103 -DANDROID_NDK=${ANDROID_NDK_ROOT} \
104 -DCMAKE_ANDROID_ARCH_ABI=x86_64 \
105 -DCMAKE_ANDROID_NDK=${ANDROID_NDK_ROOT} \
106 -DCMAKE_BUILD_TYPE=MinSizeRel \
107 -DCMAKE_SYSTEM_NAME=Android \
108 -DCMAKE_SYSTEM_VERSION=23 \
109 -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} \
110 -DCMAKE_CXX_FLAGS='-march=x86-64 --target=x86_64-linux-android23 -fno-rtti' \
111 -DLLVM_HOST_TRIPLE=x86_64-linux-android23 \
112 -DLLVM_TARGETS_TO_BUILD=X86 \
113 -DLLVM_BUILD_LLVM_DYLIB=OFF \
114 -DLLVM_BUILD_TESTS=OFF \
115 -DLLVM_BUILD_EXAMPLES=OFF \
116 -DLLVM_BUILD_DOCS=OFF \
117 -DLLVM_BUILD_TOOLS=OFF \
118 -DLLVM_ENABLE_RTTI=OFF \
119 -DLLVM_BUILD_INSTRUMENTED_COVERAGE=OFF \
120 -DLLVM_NATIVE_TOOL_DIR=${ANDROID_NDK_ROOT}toolchains/llvm/prebuilt/linux-x86_64/bin \
121 -DLLVM_ENABLE_PIC=False
123 make -j$(nproc) install
132 .. code-block::
157 ``-Ddri-search-path`` when building the driver, so that the loader
162 -----
170 out LLVMpipe can be fastest by using 128 bit vectors,
186 On Linux, building will create a drop-in alternative for ``libGL.so``
191 build/foo/gallium/targets/libgl-xlib/libGL.so
205 ``build/windows-x86-debug/gallium/targets/libgl-gdi/opengl32.dll`` which
206 is a drop-in alternative for system's ``opengl32.dll``, which will use
207 the Mesa ICD, ``build/windows-x86-debug/gallium/targets/wgl/libgallium_wgl.dll``.
213 that comes with Microsoft Windows 7 (or later) with LLVMpipe (that is,
216 - copy
217 ``build/windows-x86-debug/gallium/targets/wgl/libgallium_wgl.dll`` to
220 - load this registry settings:
226 ; https://technet.microsoft.com/en-us/library/cc749368.aspx
227 …; https://www.msfn.org/board/topic/143241-portable-windows-7-build-from-winpe-30/page-5#entry942596
234 - Ditto for 64 bits drivers if you need them.
237 ---------
247 perf record -g /my/application
250 When run inside Linux perf, LLVMpipe will create a
251 ``/tmp/perf-XXXXX.map`` file with symbol address table. It also dumps
252 assembly code to ``/tmp/perf-XXXXX.map.asm``, which can be used by the
253 ``bin/perf-annotate-jit.py`` script to produce disassembly of the
257 `Gprof2Dot <https://github.com/jrfonseca/gprof2dot#linux-perf>`__.
267 and run your LLVMpipe program. Follow the FlameGraph instructions:
268 capture traces using a supported tool (for example DTrace),
272 LLVMpipe will create a ``jit-symbols-XXXXX.map`` file containing the symbol
274 disassemblies to ``jit-symbols-XXXXX.map.asm``. Run your folded traces and
279 ------------
282 ``build/linux-???-debug/gallium/drivers/llvmpipe``:
284 - ``lp_test_blend``: blending
285 - ``lp_test_conv``: SIMD vector conversion
286 - ``lp_test_format``: pixel unpacking/packing
288 Some of these tests can output results and benchmarks to a tab-separated
293 build/linux-x86_64-debug/gallium/drivers/llvmpipe/lp_test_blend -o blend.tsv
296 -----------------
298 - When looking at this code for the first time, start in lp_state_fs.c,
301 - The driver-independent parts of the LLVM / Gallium code are found in
305 - We use LLVM-C bindings for now. They are not documented, but follow
307 code generation. See `this stand-alone
308 example <https://npcontemplation.blogspot.com/2008/06/secret-of-llvm-c-bindings.html>`__.
309 See the ``llvm-c/Core.h`` file for reference.
314 -------------------
316 - Rasterization
318 - `Triangle Scan Conversion using 2D Homogeneous
319 Coordinates <https://userpages.cs.umbc.edu/olano/papers/2dh-tri/>`__
320 - `Rasterization on
321 Larrabee <https://www.drdobbs.com/parallel/rasterization-on-larrabee/217200602>`__
322 - `Rasterization using half-space
324 - `Advanced
325 …ttp://web.archive.org/web/20140514220546/http://devmaster.net/posts/6145/advanced-rasterization>`__
326 - `Optimizing Software Occlusion
327 Culling <https://fgiesen.wordpress.com/2013/02/17/optimizing-sw-occlusion-culling-index/>`__
329 - Texture sampling
331 - `Perspective Texture
333 - `Texturing As In
335 - `Run-Time MIP-Map
337 - `Will "brilinear" filtering
338 persist? <https://alt.3dcenter.org/artikel/2003/10-26_a_english.php>`__
339 - `Trilinear
340 filtering <http://ixbtlabs.com/articles2/gffx/nv40-rx800-3.html>`__
341 - `Texture tiling and
342 swizzling <https://fgiesen.wordpress.com/2011/01/17/texture-tiling-and-swizzling/>`__
344 - SIMD
346 - `Whole-Function
347 Vectorization <https://compilers.cs.uni-saarland.de/projects/wfv/#pubs>`__
349 - Optimization
351 - `Optimizing Pixomatic For Modern x86
352 Processors <https://www.drdobbs.com/optimizing-pixomatic-for-modern-x86-proc/184405807>`__
353 - `Intel 64 and IA-32 Architectures Optimization Reference
354 …/www.intel.com/content/www/us/en/content-details/779559/intel-64-and-ia-32-architectures-optimizat…
355 - `Software optimization
357 - `Intel Intrinsics
358 Guide <https://www.intel.com/content/www/us/en/docs/intrinsics-guide/index.html>`__
360 - LLVM
362 - `LLVM Language Reference
364 - `The secret of LLVM C
365 bindings <https://npcontemplation.blogspot.com/2008/06/secret-of-llvm-c-bindings.html>`__
367 - General
369 - `A trip through the Graphics
370 …Pipeline <https://fgiesen.wordpress.com/2011/07/09/a-trip-through-the-graphics-pipeline-2011-index…
371 - `WARP Architecture and
372 …rformance <https://learn.microsoft.com/en-us/windows/win32/direct3darticles/directx-warp#warp-arch…