summaryrefslogtreecommitdiffstats
path: root/src/broadcom/cle
Commit message (Collapse)AuthorAgeFilesLines
* v3d: Add support for draw indirect for GLES3.1.Eric Anholt2018-12-141-0/+39
| | | | | | In trying to enable compute shaders, I found that a bunch of deqp-gles31's compute stuff wanted to interact with indirect dispatch. This was easy to do on its own.
* v3d: Re-use the wrap mode uniform on V3D 3.3.Eric Anholt2018-12-071-24/+4
|
* move u_math to src/utilDylan Baker2018-09-071-1/+1
| | | | | | | | | | | | | | | Currently we have two sets of functions for bit counts, one in gallium and one in core mesa. The ones in core mesa are header only in many cases, since they reduce to "#define _mesa_bitcount popcount", but they provide a fallback implementation. This is important because 32bit msvc doesn't have popcountll, just popcount; so when nir (for example) includes the core mesa header it doesn't (and shouldn't) link with core mesa. To fix this we'll promote the version out of gallium util, then replace the core mesa uses with the util version, since nir (and other non-core mesa users) can and do link with mesautils. Acked-by: Eric Engestrom <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* meson: Build with Python 3Mathieu Bridon2018-08-101-2/+2
| | | | | | | | | | | | Now that all the build scripts are compatible with both Python 2 and 3, we can flip the switch and tell Meson to use the latter. Since Meson already depends on Python 3 anyway, this means we don't need two different Python stacks to build Mesa. Signed-off-by: Mathieu Bridon <[email protected]> Reviewed-by: Eric Engestrom <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* v3d: Emit the VCM_CACHE_SIZE packet.Eric Anholt2018-08-061-0/+10
| | | | | | | This is needed to ensure that we don't get blocked waiting for VPM space with bin/render overlapping. Cc: "18.2" <[email protected]>
* v3d: Actually put the "%s" in the snprintf.Eric Anholt2018-08-011-1/+1
| | | | | | | | I missed an important part when porting the change over, fixing my compiler warning but breaking -Werror=format-security. Fixes: e6ff5ac4468e ("v3d: use snprintf(..., "%s", ...) instead of strncpy") Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=107443
* v3d: use snprintf(..., "%s", ...) instead of strncpyEric Anholt2018-07-311-1/+1
| | | | | Fixes a compiler warning about terminator NUL, based on f836d799f906 ("intel/decoder: use snprintf(..., "%s", ...) instead of strncpy")
* v3d: Use a short, underscored name for packets in CLIF/CL dumping.Eric Anholt2018-07-302-44/+46
| | | | | | | These will match the names that the CLIF parser expects to see. I may in the future decide to change more of the other names so that I match the names the HW/closed SW team uses for their packets, rather than the names in the spec (which only they and I can read anyway).
* v3d: Rename "configuration" and "config" in the XML to "cfg"Eric Anholt2018-07-301-21/+21
| | | | | | This matches what CLIF parsing expects, and makes TILE_BINNING_MODE_CONFIGURATION_COMMON_CONFIGURATION into a much more legible TILE_BINNING_MODE_CFG_COMMON.
* v3d: s/colour/color in the XML.Eric Anholt2018-07-301-19/+19
| | | | | | The CLIF format expects american english spelling, and the rest of Mesa is too. I was previously adhering to the spec's spelling, which is counterproductive.
* v3d: Rename primitives to prims in the XML to match CLIF names.Eric Anholt2018-07-301-7/+7
| | | | This makes us match up with the V3D HW team's names a bit more.
* v3d: Print CLIF fixed-point values as just their decimal value.Eric Anholt2018-07-301-6/+16
| | | | The parser doesn't handle float input, so we have to dump the raw value.
* v3d: When not doing terminal pretty-printing, comment struct field names.Eric Anholt2018-07-301-1/+7
| | | | | The struct field names aren't part of the CLIF ABI, just the order of fields within the struct. The comments are there for human readability.
* v3d: Add pack header support for f187 values.Eric Anholt2018-07-305-7/+29
| | | | | | V3D only has one of these (the top 16 bits of a float32) left in its CLs, but VC4 had many more. This gets us proper pretty-printing of the values instead of a large uint.
* v3d: Skip printing sub-id or pad fields in CLIF dumping.Eric Anholt2018-07-271-0/+8
| | | | | The parser doesn't expect them, so our fields would end up mismatched. They're not really useful in console output, either.
* v3d: Dump fields in CLIF output in increasing offset order.Eric Anholt2018-07-271-0/+14
| | | | | | Previously, we emitted in XML order, which I happen to type in the decreasing offset order of the specifications. However, the CLIF parser wants increasing offsets.
* v3d: Print addresses in CLIFs as references to buffers.Eric Anholt2018-07-272-4/+24
| | | | | | | With CLIFs, the parser will choose an address for the buffer being created, so we need to use effectively relocations to buffers instead of the addresses that the driver uses. This is also a whole lot more intelligible for console output than raw addresses!
* v3d: Stop doing pretty-printed colorful booleans in CLIF output.Eric Anholt2018-07-272-16/+8
| | | | | The parser wants to see a 1 or 0. We can put "true" and "false" in a comment to clarify that it's a boolean and the parser will skip it.
* v3d: Pass the whole clif_dump structure to v3d_print_group().Eric Anholt2018-07-272-4/+6
| | | | | | To generate CLIF files that the v3dv3 simulator can parse, we're going to need to decode addresses, and for that we'll need the vaddr lookup function from the clif structure from within v3d_decoder.
* v3d: Drop the VG support from the XML.Eric Anholt2018-07-271-13/+2
| | | | | | This reflects a change on the HW/closed SW side to drop this unused HW. With it dropped on their side, the CLIF parser no longer expects to find VG fields.
* v3d: Use /* */ instead of () for enum names in CLIF output.Eric Anholt2018-07-271-1/+1
| | | | This lets the comments be ignored by the CLIF parser.
* v3d: CLIF-dump the "Vec size" field as 0 == maximum value.Eric Anholt2018-07-271-0/+2
| | | | | That's what a user should want to see, and what the CLIF parser wants. This should maybe be generalized.
* python: Use range() instead of xrange()Mathieu Bridon2018-07-241-1/+1
| | | | | | | | | | | | | | | | Python 2 has a range() function which returns a list, and an xrange() one which returns an iterator. Python 3 lost the function returning a list, and renamed the function returning an iterator as range(). As a result, using range() makes the scripts compatible with both Python versions 2 and 3. Signed-off-by: Mathieu Bridon <[email protected]> Reviewed-by: Eric Engestrom <[email protected]> Reviewed-by: Dylan Baker <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* v3d: Implement noperspective varyings on V3D 4.x.Eric Anholt2018-07-091-1/+1
| | | | | Fixes a bunch of piglit interpolation tests, and reduces my concern about some MSAA blit shaders with noperspective varyings.
* v3d: Fix typo in dither mode offset.Eric Anholt2018-07-091-1/+1
| | | | | | We weren't using the field yet, so it didn't affect anything. Fixes: c0476d964abb ("v3d: Express dithering mode in the same way that the CLIF parser does.")
* v3d: Emit a TF flush after each draw using TF.Eric Anholt2018-07-021-0/+2
| | | | | This fixes GPU hangs on 7278 in transform feedback tests such as GTF-GLES3.gtf.GL3Tests.transform_feedback2.transform_feedback2_basic
* v3d: Add missing Stream field to transform feedback specs on V3D 4.1.Eric Anholt2018-06-291-1/+8
| | | | | Noticed when trying to CLIF parse a transform feedback job that hangs on HW.
* v3d: Add missing "tri trip or fan" flag in Primitive List Format.Eric Anholt2018-06-291-0/+1
|
* v3d: Fix the shader code address field widths on V3D 4.1+Eric Anholt2018-06-291-3/+3
| | | | | | We were overlapping it with the threadable/nan flags, resulting in incorrect relocations (threadable/nan included in the offset) and wrong ordering in the CLIF files.
* v3d: Add missing "no prim pack" field to the V3D4.1+ GL shader state.Eric Anholt2018-06-291-0/+2
| | | | | It looks like we don't need this flag for anything (not that I'm clear on what it does), but it makes our struct dumping line up with CLIF parsing.
* v3d: Express dithering mode in the same way that the CLIF parser does.Eric Anholt2018-06-291-4/+8
|
* v3d: Add missing "number of bin tile lists" field.Eric Anholt2018-06-291-0/+1
| | | | | Noticed when trying to feed our dumps through the CLIF parser. Since this is a "minus one" field, we were already filling in the value we wanted (0).
* v3d: Rewrite the color write masks to match CLIF format.Eric Anholt2018-06-291-5/+1
| | | | | The render_target_* fields gave us pretty(ish) printing, but meant we were incompatible with CLIF, and had much more verbose code generating them.
* v3d: Merge the V3D 4.1 and 4.2 XML into V3D 3.3'x XML.Eric Anholt2018-06-294-2154/+589
| | | | | | The XML ends up noisier if you're only looking at one version, but from the diffstat there's obvious wins in terms of deduplication. This will get even more significant if we ever support 3.2 or 4.0.
* v3d: Switch v3d_decoder.c to the XML's top min_ver/max_ver fields.Eric Anholt2018-06-295-6/+14
| | | | | | | The XML zipper wants one XML per version for filling out its tables, but we want to do more than one GPU version per XML now. Assume that the "gen" field will be the same as min_ver and look up our XML text assuming that they're listed in increasing min_ver.
* v3d: Create XML fields for min_ver and max_ver of a packet/struct/enum.Eric Anholt2018-06-292-2/+82
| | | | | This will be used to merge together the V3D 3.3-4.1 XML with the variants disabled based on the version.
* v3d: Pass the version being generated to the pack generator script.Eric Anholt2018-06-292-18/+16
| | | | | | | It turns out that most V3D versions change very few packets, so keeping separate copies of the XML per version makes changing the XML a pain as you have to replicate your changes to each one. This is the start of changing it so that one XML can generate headers for multiple versions.
* v3d: Convert a bunch of our "minus one" fields over to the new XML attr.Eric Anholt2018-06-273-24/+24
| | | | | This fixes up their formatting for CLIF files and makes the code more legible.
* v3d: Add pack/unpack/decode support for fields with a "- 1" modifier.Eric Anholt2018-06-273-17/+46
| | | | | | | | | | Right now, we name these fields as "field name minus one" so that your C code obviously states what the value should be. However, it's easy enough to handle at the codegen level with another little XML attribute, meaning less C code and easier-to-read values in CLIF dumping and gdb as well. (The actual CLIF format for simulator and FPGA replay takes in pre-minus-one values, so we need it there too).
* v3d, vc4: Disable valgrind checking of CLE inputs when NDEBUG is set.Eric Anholt2018-06-211-0/+2
| | | | | | For a meson -Db_ndebug=true release build on x86_64, reduces text size of libv3d.a from 53.0k to 51.6k. Inspired by 0d5329d626e3 ("anv: Disable __gen_validate_value if NDEBUG is set.")
* v3d: Be more explicit about include directory from our generated code.Eric Anholt2018-06-051-1/+1
| | | | | | | You'd need src/broadcom/cle/ in the -I previously, for srcdir != builddir. nir was fine at that, but automake didn't have it. Bugzilla: https://github.com/anholt/mesa/issues/104
* v3d: Add support for glSampleMask / glSampleCoverage.Eric Anholt2018-05-172-0/+10
|
* v3d: Enable NaN propagation in the VS and CS as well.Eric Anholt2018-05-173-3/+9
| | | | Fixes piglit vs-isnan-*.shader_test at the expense of gl-1.0-spot-light.
* broadcom/vc5: Fix tile load/store of MSAA surfaces on 4.x.Eric Anholt2018-04-252-4/+4
| | | | | For single-sample we have to always program SAMPLE_0, but for multisample we want to store all the samples.
* broadcom/vc5: Fix "hardwrae" typo in a field name in XML.Eric Anholt2018-02-052-2/+2
|
* broadcom/vc5: Add XML for V3D 4.2.Eric Anholt2018-01-273-0/+1055
|
* broadcom/vc5: Rename V3D 3.x Flat Shade Action to match v4.x naming.Eric Anholt2018-01-121-3/+3
| | | | | Now that the actions are reused for centroid and nonperspective, give them a more generic name.
* broadcom/vc5: Use THRSW to enable multi-threaded shaders.Eric Anholt2018-01-121-2/+6
| | | | | This is a major performance boost on all of V3D, but is required on V3D 4.x where shaders are always either 2- or 4-threaded.
* broadcom/vc5: Introduce v3dx_macros.h and v3dx_pack.h headers.Eric Anholt2018-01-121-0/+42
| | | | | This will be used by vc5 for prefixing functions and including the pack header in v3d-version-dependent code, following the model of anv.
* broadcom/cle: Fix error path of missing a "type" in the XML.Eric Anholt2018-01-121-1/+2
| | | | | | We try to emit a #error and continue so that you can debug the missing type at C compile time, but were missing a couple of definitions in that path (sigh, python).