summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* glsl/ast: Add 64-bit integer support in some places.Dave Airlie2017-01-201-0/+5
| | | | | | | | Just add support in two more places in ast parsing. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* glsl: Add 64-bit integer support to some operations.Dave Airlie2017-01-202-8/+8
| | | | | | | | This adds 64-bit integer support to some AST and IR operations where it is needed. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* glsl/ir_builder: Add support for some 64-bit bitcasts.Dave Airlie2017-01-202-0/+30
| | | | | | | | We need builder support to implement some of the builtins. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* glsl/ast: Add 64-bit integer support to conversion functionsDave Airlie2017-01-202-0/+99
| | | | | | | | | | | | | | | | This adds support to call the new operations on conversions. v2 (idr): Delete an unnecessary break-statement. Noticed by Matt. Add a missing blank line. Noticed by Ian. v3 (idr): "cut them down later" => Remove ir_unop_b2u64 and ir_unop_u642b. Handle these with extra i2u or u2i casts just like uint(bool) and bool(uint) conversion is done. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> [v1] Reviewed-by: Matt Turner <[email protected]> [v2] Reviewed-by: Nicolai Hähnle <[email protected]>
* glsl: Add 64-bit integer support for constant expressionsDave Airlie2017-01-202-41/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | This just adds the new operations and add 64-bit integer support to all the existing cases where it is needed. v2: fix some issues found in testing. v2.1: add unreachable (Ian), add missing int/uint pack/unpack (Dave). v3 (idr): Rebase on top of idr's series to generate ir_expression_operation_constant.h. In addition, this version: Adds missing support for ir_unop_bit_not, ir_binop_all_equal, ir_binop_any_nequal, ir_binop_vector_extract, ir_triop_vector_insert, and ir_quadop_vector. Removes support for uint64_t from ir_unop_abs and ir_unop_sign. v4 (idr): "cut them down later" => Remove ir_unop_b2u64 and ir_unop_u642b. Handle these with extra i2u or u2i casts just like uint(bool) and bool(uint) conversion is done. Signed-off-by: Dave Airlie <[email protected]> Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Ian Romanick <[email protected]> [v2] Reviewed-by: Matt Turner <[email protected]> [v3] Reviewed-by: Nicolai Hähnle <[email protected]>
* glsl/ir: Add support for 64-bit integer conversions.Dave Airlie2017-01-203-0/+210
| | | | | | | | | | | | | | | | | | | | | | This adds all the conversions in the world, I'm not 100% sure of all of these are needed, but add all of them and we can cut them down later. v2: fix issue with packing output types. v3 (idr): Rebase on top of idr's series to generate ir_expression_operation_constant.h. Fix transposed ir_validate assertions for ir_unop_u642i64 and ir_unop_i642u64. Add missing automatic type setup for ir_unop_u642i64 and ir_unop_i642u64. v4 (idr): "cut them down later" => Remove ir_unop_b2u64 and ir_unop_u642b. Handle these with extra i2u or u2i casts just like uint(bool) and bool(uint) conversion is done. Signed-off-by: Dave Airlie <[email protected]> Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Ian Romanick <[email protected]> [v2] Reviewed-by: Matt Turner <[email protected]> [v3] Reviewed-by: Nicolai Hähnle <[email protected]>
* glsl: Add 64-bit integer support to uniform initialiser codeDave Airlie2017-01-201-2/+2
| | | | | | | | Just add support to the double case, same code should work. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* glsl/varyings: Add 64-bit integer support.Dave Airlie2017-01-201-0/+8
| | | | | | | | This adds 64-bit ints to the link_varyings 64-bit support. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* glsl/ast/ir: Add 64-bit integer constant supportDave Airlie2017-01-208-8/+193
| | | | | | | | | | | | | | | | | This adds support for 64-bit integer constants to the parser, ast and ir. v2: fix a few issues found in testing. v3: Add missing ir_constant copy contructor support. v4: Use PRIu64 and PRId64 in printfs in glsl_parser_extras.cpp. Suggested by Nicolai. Rebase on Marek's linalloc changes. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> [v2] Reviewed-by: Matt Turner <[email protected]> [v3] Reviewed-by: Nicolai Hähnle <[email protected]>
* mesa: Add support for 64-bit integer uniformsDave Airlie2017-01-202-5/+247
| | | | | | | | | | This hooks up the API to the internals for 64-bit integer uniforms. v2: update to use non-strict aliased alternatives Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* glsl: Add basic ARB_gpu_shader_int64 typesDave Airlie2017-01-2011-4/+131
| | | | | | | | | | | | | This adds the builtins and the lexer support. To avoid too many warnings, it adds basic support to the type in a few other places in mesa, mostly in the trivial places. It also adds a query to be used later for if a type is an integer 32 or 64. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* glsl: Add ARB_gpu_shader_int64 boilerplate.Dave Airlie2017-01-202-0/+8
| | | | | | | | This just adds the basic boilerplate support. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* mesa: Add ARB_gpu_shader_int64 extension bitsDave Airlie2017-01-202-0/+2
| | | | | | | | This just adds the usual boilerplate in mesa core. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* mapi: Add support for ARB_gpu_shader_int64.Dave Airlie2017-01-207-0/+606
| | | | | | | | | | | | | | Just add the boilerplate xml code. v2 (idr): Update dispatch_sanity. Only add extension functions in core profile. v3 (idr): Remove comment line from gl_API.xml. Suggested by Matt. Signed-off-by: Dave Airlie <[email protected]> Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Ian Romanick <[email protected]> [v1] Reviewed-by: Matt Turner <[email protected]>
* anv: don't require render target isl bit for depth/stencil surfacesLionel Landwerlin2017-01-201-2/+5
| | | | | | | | | | | | | | | | Blorp can deal with depth/stencil surfaces blits/copies without the render target requirement. Also having both render target and depth/stencil requirement is incompatible from isl's point of view. This fixes an image creation issue in the high level quality settings of the Unity3D player, which requires a depth texture with src/dst transfer & 4x multisampling. v2: Simply aspect checking condition (Jason) Signed-off-by: Lionel Landwerlin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]> Cc: 13.0 17.0 <[email protected]>
* spirv: don't assert with location decorations on non i/o variablesLionel Landwerlin2017-01-201-1/+2
| | | | | | | | | | Some applications might add location decoration to samplers. Rather than raising an error it seems it would make more sense to just discard these decorations. Signed-off-by: Lionel Landwerlin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]> Cc: 17.0 <[email protected]>
* i965: Validate "Special Cases for Byte Operations"Matt Turner2017-01-202-9/+150
| | | | | Do this in general_restrictions_based_on_operand_types() because the two rules that "Special Cases for Byte Operations" relax are checked there.
* i965: Validate "Region Alignment Rules"Matt Turner2017-01-202-1/+697
|
* i965: Validate "General Restrictions Based on Operand Types"Matt Turner2017-01-202-0/+273
|
* i965: Validate "General Restrictions on Regioning Parameters"Matt Turner2017-01-202-0/+377
|
* i965: Replace reg_type_size[] with a function.Matt Turner2017-01-203-25/+75
| | | | | | A function is necessary to handle immediate types. Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Validate math instruction sources.Matt Turner2017-01-202-9/+23
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Claim that SEND/math has two sources.Matt Turner2017-01-201-1/+8
| | | | | | | | src1 must be a descriptor (including the information to determine that the SEND is doing an extended math operation), but src0 can actually be null since it serves as the source of the implicit GRF -> MRF move. Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Simplify num_sources_from_inst().Matt Turner2017-01-201-3/+1
| | | | | | | | desc will always be non-NULL, because brw_validate_instructions() does not attempt to validate any instructions that fail the is_unsupported_inst() check. Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Factor out send_restrictions() function.Matt Turner2017-01-201-12/+22
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Factor out sources_not_null() validation function.Matt Turner2017-01-201-17/+23
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Structure code so unsupported inst will not generate more errors.Matt Turner2017-01-201-2/+5
| | | | | | | | We want to rely on brw_opcode_desc() always returning non-NULL in other validation functions. Other validation functions will be in the else case of the block added in this patch. Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Add a test for the EU assembly validator.Matt Turner2017-01-202-0/+176
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Add a CHECK macro to call more complicated validation funcs.Matt Turner2017-01-201-0/+9
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Make ERROR_IF usable from other functions.Matt Turner2017-01-201-1/+1
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Mark error annotation on correct SIMD16 inst.Matt Turner2017-01-201-2/+2
| | | | | | | | | | | | inst, whose assignment can be seen in the last line of context pointed to the correct instruction in the SIMD16 program, but src_offset was the offset from the beginning of the SIMD16 program. So if an instruction at offset 0x100 in the SIMD16 program was illegal, we would mark an error on the instruction at offset 0x100 (which is likely in the SIMD8 program). Reviewed-by: Kenneth Graunke <[email protected]>
* i965/vec4: Use UW-typed operands when dest is UW.Matt Turner2017-01-201-4/+6
| | | | | | | | | | Using a UD-typed operand makes the execution size D, and if the size of the execution type is greater than the size of the destination type, the destination must be appropriately strided. We actually just want UW-types all around. Reviewed-by: Kenneth Graunke <[email protected]>
* i965: Use W-typed immediate in brw_F32TO16().Matt Turner2017-01-201-1/+1
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* gtest: Update to 1.8.0.Matt Turner2017-01-2026-972/+2975
| | | | Acked-by: Kenneth Graunke <[email protected]>
* i965: Don't change F->VF if dest type is DF.Matt Turner2017-01-201-1/+2
| | | | | | | | | We change the immediate source type to VF to allow instruction compaction, but there are no entires in the compaction table for DF, so there's no point in doing this. Additionally, I mixing floating-point types is now allowed except for F and VF.
* anv: fix comment typoLionel Landwerlin2017-01-201-1/+1
| | | | | Signed-off-by: Lionel Landwerlin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* spirv: fix warn string typoLionel Landwerlin2017-01-201-1/+1
| | | | | Signed-off-by: Lionel Landwerlin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* blorp: remove unnecessary struct declarationLionel Landwerlin2017-01-201-1/+0
| | | | | Signed-off-by: Lionel Landwerlin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* Revert "radeonsi: reject invalid vertex element formats"Marek Olšák2017-01-201-5/+0
| | | | | | | This reverts commit 9e4d1d8a7c0d60a6975d186944cd870e06f94773. It broke arb_vertex_type_10f_11f_11f_rev-draw-vertices, which has first_non_void == -1.
* gallium: add pipe_screen::resource_changed callback wrappersPhilipp Zabel2017-01-203-0/+47
| | | | | | | | | | Add resource_changed to the ddebug, rbug, and trace wrappers. Since it is optional, there is no need to add it to noop. Signed-off-by: Philipp Zabel <[email protected]> Suggested-by: Nicolai Hähnle <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Lucas Stach <[email protected]>
* st/mesa: ask pipe driver to recreate derived internal resources when ↵Philipp Zabel2017-01-201-0/+4
| | | | | | | | | | | | | | | (re-)binding external textures Use the resource_changed callback to invalidate internal resources derived from external textures when they are (re-)bound. This is needed to comply with the requirement from the GL_OES_EGL_image_external extension that a call to glBindTexture guarantees that all further sampling will return values that correspond to the values in the external texture at or after the time that glBindTexture was called. Signed-off-by: Philipp Zabel <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Lucas Stach <[email protected]>
* mesa: update external textures when (re-)bindingPhilipp Zabel2017-01-201-2/+3
| | | | | | | | | | | | | | | To comply with the requirement from the GL_OES_EGL_image_external extension that a call to glBindTexture guarantees that all further sampling will return values that correspond to the values in the external texture at or after the time that glBindTexture was called, do not bail out early from mesa_BindTextures if the target is external. This will later allow the state tracker to instruct the pipe driver to invalidate internal resources derived from the external texture. Signed-off-by: Philipp Zabel <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Lucas Stach <[email protected]>
* etnaviv: implement resource_changed to invalidate internal resources derived ↵Philipp Zabel2017-01-201-0/+13
| | | | | | | | | | | | from imported buffers Implement the resource_changed pipe callback to invalidate internal resources derived from imported buffers. This is needed to update the texture for re-imported renderables. Signed-off-by: Philipp Zabel <[email protected]> Reviewed-by: Reviewed-by: Christian Gmeiner <[email protected]> Signed-off-by: Lucas Stach <[email protected]>
* etnaviv: initialize seqno of imported resourcesPhilipp Zabel2017-01-201-0/+2
| | | | | | | | | | Imported resources already have contents that we want to be copied to texture resources derived from them. Set initial seqno of imported resources to 1, just as if it had already been rendered to. Signed-off-by: Philipp Zabel <[email protected]> Reviewed-by: Christian Gmeiner <[email protected]> Signed-off-by: Lucas Stach <[email protected]>
* st/dri: ask the driver to update its internal copies on reimportPhilipp Zabel2017-01-201-0/+4
| | | | | | | | | | | | For imported buffers that can't be used directly as a source to the texture samplers, the pipe driver might need to create an internal copy, for example in a different tiling layout. When buffers are reimported they may contain new image data, so the driver internal copies need to be recreated. Signed-off-by: Philipp Zabel <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Lucas Stach <[email protected]>
* gallium: add pipe_screen::resource_changedPhilipp Zabel2017-01-202-0/+22
| | | | | | | | | | Add a hook to tell drivers that an imported resource may have changed and they need to update their internal derived resources. Signed-off-by: Philipp Zabel <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Lucas Stach <[email protected]>
* configure.ac: move require_dri_shared_libs_and_glapi() before its usersEmil Velikov2017-01-201-16/+16
| | | | | | | | | | | | | Otherwise we'll get a lovely message as below: "require_dri_shared_libs_and_glapi: command not found" Cc: Steven Newbury <[email protected]> Reported-by: Steven Newbury <[email protected]> Fixes: da410e6afad "configure: explicitly require shared glapi for enable-dri" Signed-off-by: Emil Velikov <[email protected]> Tested-by: Steven Newbury <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
* gallium/hud: add missing break in hud_cpufreq_graph_install()Samuel Pitoiset2017-01-201-0/+1
| | | | | | | Fixes: e99b9395bef "gallium/hud: Add support for CPU frequency monitoring" Cc: [email protected] Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* android: correct typo in buildTapani Pälli2017-01-201-1/+1
| | | | | | Fixes: 63c58dfc653c499aab5b8d0ea07f1dc1af88c856 Signed-off-by: Tapani Pälli <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* nir: add min/max optimisationElie TOURNIER2017-01-191-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | Add the following optimisations: min(x, -x) = -abs(x) min(x, -abs(x)) = -abs(x) min(x, abs(x)) = x max(x, -abs(x)) = x max(x, abs(x)) = abs(x) max(x, -x) = abs(x) shader-db: total instructions in shared programs: 13067779 -> 13067775 (-0.00%) instructions in affected programs: 249 -> 245 (-1.61%) helped: 4 HURT: 0 total cycles in shared programs: 252054838 -> 252054806 (-0.00%) cycles in affected programs: 504 -> 472 (-6.35%) helped: 2 HURT: 0 Signed-off-by: Elie Tournier <[email protected]> Reviewed-by: Plamena Manolova <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>