aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* util: move #include out of #if linuxEric Engestrom2019-05-011-1/+1
| | | | | | | | | This #include is needed for `NULL`, which is used on all OSes, not just Linux. Reported-by: Juan A. Suarez Romero <[email protected]> Fixes: 316964709e21286c2af5 "util: add os_read_file() helper" Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Juan A. Suarez <[email protected]>
* swr/rast: Add general SWTag statisticsAlok Hota2019-05-013-161/+191
| | | | | | Update Archrast parser to use stats, used with an internal tool Reviewed-by: Bruce Cherniak <[email protected]>
* swr/rast: Add string handling to AR event frameworkAlok Hota2019-05-015-31/+54
| | | | | | For use by an internal tool Reviewed-by: Bruce Cherniak <[email protected]>
* swr/rast: Add initial SWTag proto definitionsAlok Hota2019-05-012-39/+71
| | | | | | Update gen_archrast.py to properly generate event IDs Reviewed-by: Bruce Cherniak <[email protected]>
* swr/rast: Cleanup and generalize gen_archrastAlok Hota2019-05-013-123/+57
| | | | | | | | | | | | | | | | - Update meson.build - Includes current_build_dir() fix meson/swr: replace hard-coded path with current_build_dir() Fixes: 93cd9905c8fbb98985ae "swr/rast: Cleanup and generalize gen_archrast" Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Alok Hota <[email protected]> Reviewed-by: Dylan Baker <[email protected]> - Clean up meson.build (remove foreach loop, replace with single call) - Update SConscript - use `$SOURCES` to call `CodeGenerate` with multiple source files Reviewed-by: Bruce Cherniak <[email protected]>
* gitlab-ci: build vulkan drivers in clang buildEric Engestrom2019-05-011-0/+1
| | | | | Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* softpipe: setup pixel_offset for all primitive typesErik Faye-Lund2019-05-011-11/+10
| | | | | | | | | | | | If we don't update this for all primitive-types, we end up rendering slightly offset points and lines up until the point where the first triangle gets drawn. This is obviously not correct, and violates OpenGL's repeatability rule. Signed-off-by: Erik Faye-Lund <[email protected]> Fixes: ca9c413647b ("softpipe: Respect gl_rasterization_rules in primitive setup.") Reviewed-By: Gert Wollny <[email protected]>
* nir: improve convert_yuv_to_rgbJonathan Marek2019-05-011-15/+14
| | | | | | | | | | | | Use a different arrangement of constants to allow more ffma. A vec4 backend will now use 3 fma for yuv_to_rgb. On freedreno/ir3, it is down from 10 to 7 alu (4 fma, 3 mul, 3 add to 7 fma). Other backends shouldn't be hurt. Signed-off-by: Jonathan Marek <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Tested-by: Ian Romanick <[email protected]>
* doc: Update feature matrixGert Wollny2019-05-011-11/+11
| | | | | | | | | Since softpipe doesn't truely support multisample, I've not added softpipe to the "Enhanced per-sample shading" even though with the advertised GLSL level ARB_gpu_shader5 is advertised. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Increase the GLSL feature levelGert Wollny2019-05-011-1/+1
| | | | | | | | This will enable calls to the interpolateAt* functions, but also a bunch of other features. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Add support for TGSI_OPCODE_INTERP_CENTROIDGert Wollny2019-05-011-0/+42
| | | | | | | | | | | | Like with interpolatAtSample this is also not really implementing the according sampling and will only work correctly for pixels that are fully covered, but since softpipe only supports one sample this is good enough for now. v2: Correct spelling (Roland Scheidegger) Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Add support for TGSI_OPCODE_INTERP_OFFSETGert Wollny2019-05-011-0/+32
| | | | | | | | | | Since for this opcode the offsets are given manually the function should actually also work for non-zero offsets, but the related piglits only ever test with offset 0. Accordingly the patch satisfies "fs-interpolateatoffset-*". Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Add (fake) support for TGSI_OPCODE_INTERP_SAMPLEGert Wollny2019-05-011-1/+40
| | | | | | | | | | | | Softpipe doesn't support more than one sample, so this function implements the interpolation at sample 0 and adds a stub to make it possible to interpolate at other samples. As it is this makes the piglits "fs-interpolateatsample-*" pass, but they only ever test sample 0 anyway. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Add an per-input array for interpolator correctors to machineGert Wollny2019-05-012-4/+79
| | | | | | | | This adds entry points for correcting the interpolation values if the interpolation is done by using one of the interpolateAt* functions. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Factor out evaluation of the source indicesGert Wollny2019-05-011-28/+41
| | | | | | | We will need these for per sample interpolation as well Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: evaluate cube the faces on a per sample basesGert Wollny2019-05-011-24/+16
| | | | | | | | | | Now that the LOD is evaluated up front the cube faces can also be evauate on a per sample basis instead of using the quad. This fixes a large number of deqp gles 3 and 31 cube texture tests. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: keep input lod for explicite derivativesGert Wollny2019-05-011-2/+4
| | | | | | | This only affects anisotropic interpolation. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: tie in new code path for lod evaluationGert Wollny2019-05-012-46/+21
| | | | | | | | | This enables the use of explicit gradients. Also remove an unused parameter when changing the interfaces. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Move selection of shadow values up and clean parameter listGert Wollny2019-05-011-29/+43
| | | | | | | | | The shadow evaluation compare parameter is stored in different locations, depending on the texture type. Move the values to a common location free the lod storage and to be able to reduce the number of parameters. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Pipe gather_comp through from st_tgsi_get_samplesGert Wollny2019-05-012-5/+18
| | | | | | | | The value is stored in the lod components and this will be overwritten when swithcing to the new code path. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Prepare handling explicit gradientsGert Wollny2019-05-013-1/+42
| | | | | | | This only adds corde that is not yet enabled. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: Factor gradient evaluation out of the lambda evaluationGert Wollny2019-05-011-19/+119
| | | | | | | this is useful when we want to use explicit gradients. Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* egl: return correct error code for a case req ver < 3 with forward-compatibleAndrii Simiklit2019-05-011-1/+4
| | | | | | | | | | | | | | | | | | | | The EGL_KHR_create_context spec says: "If an OpenGL context is requested and the values for attributes EGL_CONTEXT_MAJOR_VERSION_KHR and EGL_CONTEXT_MINOR_VERSION_KHR, when considered together with the value for attribute EGL_CONTEXT_OPENGL_FORWARD_COMPATIBLE_BIT_KHR, specify an OpenGL version and feature set that are not defined, than an EGL_BAD_MATCH error is generated." This case is already correctly handled a bit below in the same source file. The correct handling was added by commit: 63beb3df Reported-by: Ian Romanick <[email protected]> Here: https://bugzilla.freedesktop.org/show_bug.cgi?id=92552#c9 Fixes: 11cabc45b712 "egl: rework handling EGL_CONTEXT_FLAGS" Reviewed-by: Ian Romanick <[email protected]> Signed-off-by: Andrii Simiklit <[email protected]>
* radeonsi/nir: call radeonsi nir opts before the scan passTimothy Arceri2019-05-012-0/+2
| | | | | | | | | | | | | | Some of the opts are not called in the general optimastion loop in the state trackers glsl -> nir conversion. We need to call the radeonsi specific optimisation once before scanning over the nir otherwise we can end up gathering info on code that is later removed. Fixes an assert in the piglit test: ./bin/varying-struct-centroid_gles3 Reviewed-by: Marek Olšák <[email protected]>
* radeonsi/nir: create si_nir_opts() helperTimothy Arceri2019-05-012-36/+43
| | | | | | We will make use of this in the following commit. Reviewed-by: Marek Olšák <[email protected]>
* swr/rast: early exit on empty triangle maskAlok Hota2019-04-301-0/+6
| | | | Reviewed-by: Bruce Cherniak <[email protected]>
* swr/rast: add guards for cpuid on LinuxAlok Hota2019-04-301-0/+2
| | | | Reviewed-by: Bruce Cherniak <[email protected]>
* swr/rast: add flat shadingAlok Hota2019-04-301-0/+13
| | | | Reviewed-by: Bruce Cherniak <[email protected]>
* swr/rast: add SWR_STATIC_ASSERT() macroAlok Hota2019-04-301-1/+8
| | | | Reviewed-by: Bruce Cherniak <[email protected]>
* swr/rast: update guardband rects at draw setupAlok Hota2019-04-301-2/+3
| | | | | | It's dependent on other state fields Reviewed-by: Bruce Cherniak <[email protected]>
* swr/rast: add more llvm intrinsicsAlok Hota2019-04-301-0/+3
| | | | Reviewed-by: Bruce Cherniak <[email protected]>
* st/va: properly set stride and offset in vlVaDeriveImageJulien Isorce2019-04-301-10/+25
| | | | | | | | Using the new resource_get_info function. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110443 Signed-off-by: Julien Isorce <[email protected]> Reviewed-by: Leo Liu <[email protected]>
* radeonsi: implement resource_get_infoJulien Isorce2019-04-301-8/+35
| | | | | | | | Re-use existing si_texture_get_offset. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110443 Signed-off-by: Julien Isorce <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium: add resource_get_info to pipe_screenJulien Isorce2019-04-304-0/+51
| | | | | | | | Generic plumbing. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110443 Signed-off-by: Julien Isorce <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* freedreno/ir3: fixes for half reg in/outRob Clark2019-04-304-13/+39
| | | | | | | Needs to update max_half_reg, or be remapped to full reg and update max_reg accordingly, depending on generation.. Signed-off-by: Rob Clark <[email protected]>
* st/nine: Check discard_delayed_release is set before allocating moreAxel Davy2019-04-301-0/+2
| | | | | | | | | | When discard_delayed_release is set (default), we allocate more buffers and use a different buffer wait path. Check if it is set, and use the old paths if not (the alternative buffer wait path could still be used, but there is no advantage to using it in this case). Signed-off-by: Axel Davy <[email protected]>
* st/nine: Throttle rendering similarly for thread_submitAxel Davy2019-04-302-22/+22
| | | | | | | | | thread_submit's throttling depending on the number of internal back buffers, and wasn't affected by the driver requested throttling value. Now it is. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Optimize a bit writeonly buffersAxel Davy2019-04-301-1/+6
| | | | | | | | | | | Optimize writeonly by passing PIPE_TRANSFER_WRITE for these buffers instead of the safer PIPE_TRANSFER_READ_WRITE. This seems to improve the performance of d3d8 games using d3d8to9. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Use TGSI_SEMANTIC_GENERIC for fogAxel Davy2019-04-302-28/+29
| | | | | | | | | | | | | | We used TGSI_SEMANTIC_FOG for fog, however on vs/ps 3, fog is allowed to have 4 components (even on the ff pipeline according to a wine test). Since gallium's TGSI_SEMANTIC_FOG has only one component, use TGSI_SEMANTIC_GENERIC instead. Fixes: https://github.com/iXit/Mesa-3D/issues/346 Signed-off-by: Axel Davy <[email protected]>
* st/nine: Enable computing const_rangesAxel Davy2019-04-301-1/+1
| | | | | | | All the pieces for constant compact are ready, thus enable the path. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Handle const_ranges in nine_stateAxel Davy2019-04-301-2/+26
| | | | | | Handle slot mapping if there is one. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Cache constant buffer sizeAxel Davy2019-04-307-23/+52
| | | | | | | | | | | | The shader constant buffer size with the constant compaction code can vary depending on the shader variant compiled (for example if fog constants are required, etc). Thus instead of using fixed size for the shader, add in the variant cache the size required, pass it to the context, and use this value. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Propagate const_range to contextAxel Davy2019-04-307-15/+37
| | | | | | | | | As with the constant compaction we map the constant slots to new slots, we need to pass that information to the context which is in charge of uploading the constants. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Prepare constant compaction in nine_shaderAxel Davy2019-04-302-28/+118
| | | | | | | | | | | | | | When indirect addressing is not used, we know exactly which constants are accessed, and thus can have them located in consecutive slots. We thus parse again the shader with a slot map for compaction. The path contains the work inside nine_shader.c for this path, but it needs some other commits to work, and thus is not enabled yet by this commit. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Refactor counting of constantsAxel Davy2019-04-301-25/+21
| | | | | | Track the number of slots used Signed-off-by: Axel Davy <[email protected]>
* st/nine: Track constant slots usedAxel Davy2019-04-301-2/+11
| | | | | | This tracking will be useful for constant compaction Signed-off-by: Axel Davy <[email protected]>
* st/nine: Refactor ct_ctorAxel Davy2019-04-301-89/+95
| | | | | | | The refactoring will make it easier to parse the shader twice for the constant compaction path. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Make swvp_on imply IS_VSAxel Davy2019-04-302-6/+10
| | | | | | | swvp cannot happen with ps, thus it makes sense to force it to false with ps. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Refactor shader constants ureg_src computationAxel Davy2019-04-302-95/+99
| | | | | | | Put the shader constant code in one place to better change that code in future commits. Signed-off-by: Axel Davy <[email protected]>
* st/nine: Manually upload vs and ps constantsAxel Davy2019-04-301-0/+46
| | | | | | | In future commits we will introduce more fine-grained uploads Signed-off-by: Axel Davy <[email protected]>