summaryrefslogtreecommitdiff
path: root/src/intel
AgeCommit message (Collapse)AuthorFilesLines
2016-04-25isl: remove ffs function that conflicts with system headersJonathan Gray1-5/+1
Remove a wrapper around __builtin_ffs that conflicts with system headers on OpenBSD and perhaps elsewhere: isl_priv.h:44: error: conflicting types for 'ffs' v2: include strings.h to ensure prototype is found Signed-off-by: Jonathan Gray <jsg@jsg.id.au> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2016-04-25anv: fix warnings in release buildGrazvydas Ignotas4-4/+4
Mark variables MAYBE_UNUSED to avoid unused-but-set-variable warnings in release build. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Reviewed-by: Chad Versace <chad.versace@intel.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2016-04-25isl: fix warnings in release buildGrazvydas Ignotas2-2/+2
Mark variables MAYBE_UNUSED to avoid unused-but-set-variable warnings in release build. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Reviewed-by: Chad Versace <chad.versace@intel.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2016-04-23genxml: use PYTHON3Jonathan Gray2-1/+3
Allows the build to work when the python3 binary is not "python3". v2: remove x bit from the script at Emil's suggestion Signed-off-by: Jonathan Gray <jsg@jsg.id.au> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-21isl/format: Add a get_num_channels helperJason Ekstrand2-0/+17
Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-21isl/format: Add more isl_format_has_type_channel functionsJason Ekstrand2-4/+43
Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-21isl/format: Break the guts of has_[us]int_channel into a helperJason Ekstrand1-18/+16
Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-21anv/image: Use the has_matching_typed_storage_image_format helper from islJason Ekstrand1-12/+3
Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-21isl: Add a helper for determining when a typed load/store can be usedJason Ekstrand2-0/+20
Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-21isl: Take a devinfo in lower_storage_image_format instead of an isl_deviceJason Ekstrand4-18/+19
We want to call this function from the shader compiler and having a full isl_device available at that point isn't practical. Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-21isl: Don't use designated initializers in the headerJason Ekstrand1-13/+24
C++ doesn't support designated initializers and g++ in particular doesn't handle them when the struct gets complicated, i.e. has a union. Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-21isl: Include c99_compat.hJason Ekstrand1-0/+1
We need the restrict keyword in isl.h Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-21i965: Add a dependency on libislJason Ekstrand1-4/+0
To avoid build issues, ensure that you're running `make' at the top level and/or you've executed `make clean' beforehand. Reviewed-by: Chad Versace <chad.versace@intel.com>
2016-04-20i965: Generalize wm_key->compute_sample_id to wm_key->multisample_fbo.Kenneth Graunke1-1/+1
I'm going to need a key entry meaning "we have a multisample FBO, and multisampling is enabled" in an upcoming patch. This is basically wm_key->compute_sample_id, except that it also checks that the SAMPLE_ID system value is read. The only use of wm_key->compute_sample_id is in emit_sampleid_setup(), which is only called when handling the SAMPLE_ID system value. So we can just eliminate the check and generalize the field. v2: Also update the Vulkan driver. Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Matt Turner <mattst88@gmail.com>
2016-04-20i965: Delete now dead persample_2x FS program key flag.Kenneth Graunke1-3/+0
This was only used by the old gl_SampleID calculations. The new code doesn't need to handle 2x specially. v2: Delete it from the Vulkan driver, too. Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Matt Turner <mattst88@gmail.com>
2016-04-20anv: s/anv_batch_emit_blk/anv_batch_emit/Jason Ekstrand11-138/+133
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv: Remove the old emit macroJason Ekstrand1-10/+0
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/gen7_pipeline: Use the new emit macroJason Ekstrand1-113/+124
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/gen7_cmd_buffer: Use the new emit macroJason Ekstrand1-52/+70
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/device: Use the new emit macroJason Ekstrand2-12/+13
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/state: Use the new emit macroJason Ekstrand1-77/+78
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/gen8_pipeline: Use the new emit macroJason Ekstrand1-177/+191
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/genX_pipeline: Use the new emit macroJason Ekstrand2-38/+45
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/gen8_cmd_buffer: Use the new emit macroJason Ekstrand1-74/+87
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/cmd_buffer: Use the new emit macro for quariesJason Ekstrand1-24/+32
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/cmd_buffer: Use the new emit macro for DRAWING_RECTANGLEJason Ekstrand1-9/+10
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/cmd_buffer: Use the new emit macro for compute shader dispatchJason Ekstrand1-52/+64
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/cmd_buffer: Use the new emit macro for 3DSTATE_CONSTANTJason Ekstrand1-10/+11
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/cmd_buffer: Use the new emit macro for DEPTH/STENCIL_BUFFERJason Ekstrand1-34/+42
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/cmd_buffer: Use the new emit macro for PIPE_CONTROL and STATE_BASE_ADDRESSJason Ekstrand1-62/+76
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv/cmd_buffer: Use the new emit macro for 3DPRIMITIVE commandsJason Ekstrand1-24/+28
Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv: Add a new block-based batch emit macroJason Ekstrand1-0/+9
This new macro uses a for loop to create an actual code block in which to place the macro setup code. One advantage of this is that you syntatically use braces instead of parentheses. Another is that the code in the block doesn't even get executed if anv_batch_emit_dwords fails. Acked-by: Kristian Høgsberg <krh@bitplanet.net>
2016-04-20anv: fix build without Wayland platformMarcin Ślusarz2-7/+5
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-04-20anv: fix building on i686 with -mcpu=genericLaurent Carlier1-1/+1
mcpu=generic doesn't enable sse2, and anvil definitly needs it Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-04-20nir: rename nir_foreach_block*() to nir_foreach_block*_call()Connor Abbott3-4/+7
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-04-20anv/apply_dynamic_offsets: Provide a range on the load_uniformJason Ekstrand1-1/+3
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94998 Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=95001
2016-04-20anv/lower_push_constants: Stop treating scalar speciallyJason Ekstrand3-28/+4
All of the code that did something special based on vec4 vs. scalar is bogus. In the backend, everything is now in units of bytes and the vec4 backend can handle full std140 packing so we don't need to do anything special anymore. Signed-off-by: Jason Ekstrand <jason@jlekstrand.net> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94998
2016-04-15anv/device: Images are only enabled in scalar stagesJason Ekstrand1-2/+2
Reported-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-04-15anv: Advertise vertexPipelineStoresAndAtomics based on scalar stagesJason Ekstrand1-1/+5
Previously, we just looked at the hardware generation but this meant that if you did INTEL_DEBUG=vec4 on BDW or SKL, you would have advertised but non-working features.
2016-04-14anv: Install the installable ICDJason Ekstrand1-0/+3
2016-04-14anv/intel_icd: Don't provide an absolute pathJason Ekstrand2-3/+2
The driver will be installed to $(libdir)/libvulkan_intel.so and just providing a driver name is enough for the loader. This also ensures that multi-arch systems work ok.
2016-04-14configure: Add initial support for enabling Vulkan driversJason Ekstrand1-1/+5
2016-04-14anv/pipeline: Use the right mask for lower_indirect_derefsJason Ekstrand1-3/+3
2016-04-14spirv: Move to compiler/Jason Ekstrand1-1/+1
While it does rely on NIR, it's not really part of the NIR core. At the moment, it still builds as part of libnir but that can be changed later if desired.
2016-04-13Merge remote-tracking branch 'public/master' into vulkanJason Ekstrand1-1/+1
2016-04-13anv: Remove default scissor and viewport conceptsNanley Chery4-49/+9
Users should never provide a scissor or viewport count of 0 because they are required to set such state in a graphics pipeline. This behavior was previously only used in Meta, which actually just disables those hardware operations at pipeline creation time. Kristian noticed that the current assignment of viewport count reduces the number of viewport uploads, so it is not removed. Signed-off-by: Nanley Chery <nanley.g.chery@intel.com> Reviewed-by: Kristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
2016-04-13anv: Replace ::disable_scissor with ::use_rectlistsNanley Chery7-7/+2
Meta currently uses screenspace RECTLIST primitives that lie within the framebuffer rectangle. Since this behavior shouldn't change in the future, disable the scissor operation whenever rectlists are used. Signed-off-by: Nanley Chery <nanley.g.chery@intel.com> Reviewed-by: Kristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
2016-04-13anv: Delete anv_graphics_pipeline_create_info::disable_viewportNanley Chery5-5/+0
There are no users of this field. Signed-off-by: Nanley Chery <nanley.g.chery@intel.com> Reviewed-by: Kristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
2016-04-13gen{7,8}_pipeline: Always set ViewportXYClipTestEnableNanley Chery2-2/+2
For the following reasons, there is no behavioural change with this commit: the ViewportXYClipTest function of the CLIP stage will continue to be enabled outside of Meta (where disable_viewport is always false), and the CLIP stage is turned off within Meta, so this function will continue to be disabled in that case. Signed-off-by: Nanley Chery <nanley.g.chery@intel.com> Reviewed-by: Kristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
2016-04-13gen{7,8}_pipeline: Apply 3DPRIM_RECTLIST restrictionsNanley Chery2-4/+4
According to 3D Primitives Overview in the Bspec, when the RECTLIST primitive is in use, the CLIP stage should be disabled or set to have a different Clip Mode, and Viewport Mapping must be disabled: Clipping: Must not require clipping or rely on the CLIP unit’s ClipTest logic to determine if clipping is required. Either the CLIP unit should be DISABLED, or the CLIP unit’s Clip Mode should be set to a value other than CLIPMODE_NORMAL. Viewport Mapping must be DISABLED (as is typical with the use of screen-space coordinates). We swap out ::disable_viewport for ::use_rectlist, because we currently always use the RECTLIST primitive when we disable viewport mapping, and we'll likely continue to use this primitive. Signed-off-by: Nanley Chery <nanley.g.chery@intel.com> Reviewed-by: Kristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>