Commit Graph

90 Commits

Author SHA1 Message Date
Nathan Gauër
cdc4e528f3
build: move from c++11 to c++17 (#4983)
* build: move from c++11 to c++17

Moving from cpp 11 to cpp 17 will allow us to use modern features like
filesystem support, optional, any, execution policies and improved
templates.

Signed-off-by: Nathan Gauër <brioche@google.com>
2023-01-20 15:17:34 +01:00
Steven Perron
1e85dca570
Add VS2019 kokoro configs (#5059)
We added new builds that will test spirv-tools with VS2019, but we need to add
the configurations for them.
2023-01-18 20:11:25 +00:00
David Neto
631f9bcb5e
Update README.md: Development occurs on the "main" branch (#5053)
Fixes: #5051
2023-01-11 14:58:35 -05:00
David Neto
5bec0884cf
Remove testing support for VS2015 (#5027)
Fixes: #5026
2022-12-19 16:39:58 -05:00
Samuel Bronson
451ba8ec3d
README.md: The validator now handles larger limits (#5003)
* README.md: The validator now handles larger limits

* Oops ...

* Fix typo

Co-authored-by: David Neto <dneto@google.com>
2022-12-15 21:35:08 -05:00
Steven Perron
f56726a323
Use bazel 5 for bazel builds. (#4738)
* Use bazel 5 for Linux bazel builds.
* Download bazel 5.0.0 for macos and windows bazel builds.
* Modify the readme to mention bazel 5.0.0 as the version to use.
2022-03-03 15:35:25 +00:00
Shahbaz Youssefi
7fa9e746ef
Introduce spirv-diff (#4611)
spirv-diff is a new tool that produces diff-style output comparing two
SPIR-V modules.  The instructions between the src and dst modules are
matched as best as the tool can, and output is produced (in src
id-space) that shows which instructions are removed in src, added in dst
or modified between them.  The order of instructions are not retained.

Matching instructions between two SPIR-V modules is not trivial, and
thus a number of heuristics are applied in this tool.  In particular,
without debug information, it's hard to match functions as they can be
reordered.  As such, this tool is primarily useful to produce the diff
of two SPIR-V modules derived from the same source.

This tool can be useful in a number of scenarios:

- Compare the SPIR-V before and after modifying a shader
- Compare the SPIR-V produced from a shader before and after compiler
  codegen changes.
- Compare the SPIR-V produced from a shader before and after some
  transformation or optimization.
- Compare the SPIR-V produced from a shader with different compilers.
2022-02-02 10:33:18 -05:00
Jakub Kuderski
c72c454203
Clarify how to update DEPS (#4626)
-  Mention that `depot_tools` are required and link to that repo.
-  Make `roll_deps.sh` exit on error. The script passes `shellcheck`
   with this change.
-  Reword instruction in the README.
2021-11-09 10:28:01 -05:00
David Neto
d645ea2705
Update CHANGES, README for WebAssembly build (#4609) 2021-11-02 08:56:06 -04:00
David Neto
7a7a69037e
README: Remove appveyor build badge. (#4584)
Bot failures are unrelated.
2021-10-19 17:17:56 -04:00
David Neto
4578db3c41
README: Update tested versions of compilers (#4579)
I checked this against the Kokoro output.
2021-10-18 15:34:06 -04:00
David Neto
10343e53ed
Remove Appveyor CI, update README (#4578)
- Remove Appveyor CI
- Write new "Getting the source" subsection, consolidating material
  from a couple of places.  Emphasize using the utils/git-sync-deps
  script for getting a known-good combination of sources.
- Built artifacts:
   - top of tree artifacts are from Kokoro CI bots
   - mention Vulkan SDK and Android NDK as alternatives

Fixes: #4577
2021-10-14 17:46:27 -04:00
alan-baker
3510a14cfc
Add a section releases to the README (#4444)
* Releases are unrelated to SPIRV-Headers releases
* SPIRV-Headers should always be taken from the DEPS file
2021-08-06 09:07:53 -04:00
Jakub Kuderski
7320b9acd2
Explain how to run tests with CMake and Bazel (#4383)
Update README.
2021-07-16 11:48:22 -04:00
Alastair Donaldson
2299b710de
spirv-fuzz: support building using gn (#4365)
Adds support for building spirv-fuzz using gn. Updates the protobuf
dependency to the version used by Chromium.

Fixes #4372.
2021-07-13 19:45:01 +01:00
Ryan Harrison
9150cd441f
Remove WebGPU support (#4108)
Leaves SPV_ENV_WEBGPU_0 enum in place, but marked deprecated, so users
of the library are not broken by an API enum being removed.

Fixes #4101
2021-01-14 16:45:18 -05:00
Paul Thomson
a715b1b405
Improve spirv-fuzz CMake code (#3781)
This change improves spirv-fuzz CMake code to be more compatible with other projects that might want to include spirv-fuzz as a sub-project.

* Add a CMake option for building spirv-fuzz. 
* We now check if protobuf targets are already available. 
* We no longer specify `-DGOOGLE_PROTOBUF_NO_RTTI -DGOOGLE_PROTOBUF_USE_UNALIGNED=0`; a newer version of protobuf does not require this. Note that we probably should have specified this for protobuf targets as well, but this is no longer needed. 
* Updated protobuf version in Kokoro scripts and README.md.
2020-09-09 09:56:32 +01:00
Paul Thomson
55193b06e5
Improve build instructions for fuzzer (#3364) 2020-05-21 12:56:26 +01:00
CHAITANYA
30ffe62e25
typo fix: in README.md exectuable->executable (#3306) 2020-04-23 10:56:47 -04:00
David Neto
c3f22f7cba
Update README (#3047)
* This project supports SPIR-V 1.5
* Update description of the optimizer
2019-11-14 09:38:01 -05:00
Pierre Moreau
1f2af55f21 Update README (#3048)
* Fix one of the URIs to the Bazel project
* Fix a typo
2019-11-14 08:33:21 -05:00
Alastair Donaldson
87efe0a8b4 Add basic documentation about spirv-fuzz (#3016)
This change provides some information about spirv-fuzz in the
top-level SPIRV-Tools README.  A typo elsewhere in the README is also
fixed.
2019-11-06 11:12:01 -05:00
Ehsan
a03cd1f3eb
Add Bazel build configuration. (#2891)
* Add Bazel build configuration.

* fix for windows.

* Update doc file.

* Add tests that were accidentally skipped by Bazel

* Update doc file.
2019-09-24 15:56:59 -04:00
dan sinclair
47e354b0c2
Move docs into docs/ folder (#2872) 2019-09-19 09:46:27 -04:00
Ryan Harrison
69b9459925 Add infrastructure for maintaining and using DEPS (#2684)
This adds in a script for updating DEPS and another for pulling in the
specified versions in the DEPS file.

DEPS entries that are not part of the documented build processs are
removed. Using the documented cmake process with them made for a very
sad state of one's checkout. If this removal breaks workflows we can
revist this, since the state is saved in git.

DEPS are rolled forward, so that this is taking use to a known good
state. These look like scary big rolls, but in reality the bots and
most people are running near HEAD for external/, so this integration
should already have been tested.

Summary of DEPS roll:
+ Rolling 3 dependencies
+ Roll external/effcee/ 04b624799..b83b58d17 (14 commits)
+ Roll external/googletest/ 98a0d007d..2f42d769a (576 commits)
+ Roll external/re2/ 6cf8ccd82..848dfb7e1 (90 commits)
+ Created with:
+   roll-dep external/effcee external/googletest external/re2 external/spirv-headers

Fixes #2665
2019-06-20 14:57:28 -04:00
dan sinclair
42abaa099a Remove MarkV and Stats code. (#2576)
* Remove MarkV and Stats code.

This Cl removes the MarkV and Stats code from SPIRV-Tools. This code was
unused and currently un-maintained.
2019-05-24 15:43:59 -04:00
Ehsan
eef11cdb71
Update README with links to build artifacts. (#2548) 2019-05-06 10:21:57 -04:00
Steven Perron
fb08224f89
Fix spirv-headers link in the README. (#2516) 2019-04-26 09:34:11 -04:00
David Neto
07ac7dee5c SPIRV-Tools requires python3 (#2510)
Updates:
- CMake configuration
- Kokoro build scripts on Linux and macos (Windows already uses Python 3.6)
2019-04-12 08:23:19 -04:00
David Neto
82ebbbba15 README: fix formatting of requiring Python 'future' (#2500) 2019-04-09 14:42:20 -04:00
Steven Perron
07f80c4df1
Fix python scripts to work with python3 (#2426)
Updated script to work with python3 and python2.

Added required tools.

We added a section to the readme to mention the tools that are needed to
build and test spirv-tools. For the compiler, the compilers used by the
bots are mentioned.

The bots have been changed. The windows bots will not use python 3.6 for testing. The other bots will still use python 2.7. Both Python2 and Python3 will be tested.

Fixes #2407.
Fixes #1856.
2019-03-06 14:11:01 -05:00
Alastair Donaldson
adbbe20241 Mention the reducer tool and location in the README. (#2341)
* Mention the reducer tool and location in the README.

* Remark on how to get info on specifying interestingness.
2019-02-04 09:41:38 -08:00
Alastair Donaldson
3d71024248 Added some documentation about the reducer. (#2318) 2019-01-23 12:29:14 -05:00
Steven Perron
aa270e568a
Be more explicit about SPIRV_WERROR option. (#2141)
There was some confusion about the SPIRV_WERROR option when it is turned
off.  When the option is off nothing is done.  That is, we do not add
-Wno-error.  This means that if the parent project added -Werorr to the
C flags or CXX flags, then warnings will still be treated as errors.

I've updated the README.md to make this explicit.

Fixes #2121.
2018-12-06 11:31:47 -05:00
Hugues Evrard
66f8f645e9 Update build instructions: add effcee, re2 (#2085)
Both effcee and re2 are now required dependencies, add their checkout in build instructions.
2018-11-20 11:10:19 -05:00
Steven Perron
c4c68712c4
Make EFFCEE required (#1943)
Fixes #1912.

Remove the non-effcee build as EFFCEE is now required.
2018-10-04 10:00:11 -04:00
Jaebaek Seo
9e99d8b691 Specified clang-format version in README.md 2018-09-18 10:35:28 -04:00
Ehsan Nasiri
c02d216648 Update docs to reflect new bot status. 2018-07-11 10:36:45 -04:00
Jaebaek Seo
eb48263cc8 Description for Android build 2018-07-10 14:31:15 -04:00
David Neto
01f32ee001 Update README for SPIR-V 1.3 2018-03-06 15:17:31 -05:00
Nerijus Baliūnas
5d442fad2f fix typo 2018-02-15 12:00:02 -05:00
Lei Zhang
5f2589fd12 Update README about the automatic master-tot relase 2017-11-28 15:58:27 -05:00
David Neto
76555bd4ba Tests: Add optional dependency on Effcee stateful matcher
Add Effcee as an optional dependency for use in tests.  In future it will
be a required dependency.

Effcee is a stateful pattern matcher that has much of the functionality
of LLVM's FileCheck, except in library form.  Effcee makes it much easier
to write tests for optimization passes.

Demonstrate its use in a test for the strength-reduction pass.

Update README.md with example commands of how to get sources.

Update Appveyor and Travis-CI build rules.

Also: Include test libraries if not SPIRV_SKIP_TESTS
- SPIRV_SKIP_TESTS is implied by SPIRV_SKIP_EXECUTABLES
2017-11-13 11:34:21 -05:00
David Neto
1affe5a3ee Describe public_spirv_tools_dev@khronos.org mailing list 2017-11-06 11:07:46 -05:00
Pierre Moreau
86627f7b3f Implement Linker (module combiner)
Add extra iterators for ir::Module's sections
Add extra getters to ir::Function
Add a const version of BasicBlock::GetLabelInst()

Use the max of all inputs' version as version

Split debug in debug1 and debug2
- Debug1 instructions have to be placed before debug2 instructions.

Error out if different addressing or memory models are found

Exit early if no binaries were given

Error out if entry points are redeclared

Implement copy ctors for Function and BasicBlock
- Visual Studio ends up generating copy constructors that call deleted
  functions while compiling the linker code, while GCC and clang do not.
  So explicitly write those functions to avoid Visual Studio messing up.

Move removing duplicate capabilities to its own pass

Add functions running on all IDs present in an instruction

Remove duplicate SpvOpExtInstImport

Give default options value for link functions

Remove linkage capability if not making a library

Check types before allowing to link

Detect if two types/variables/functions have different decorations

Remove decorations of imported variables/functions and their types

Add a DecorationManager

Add a method for removing all decorations of id

Add methods for removing operands from instructions

Error out if one of the modules has a non-zero schema

Update README.md to talk about the linker

Do not freak out if an imported built-in variable has no export
2017-10-06 18:33:53 -04:00
Andrey Tuganov
c25b5bea35 Add SPIRV_SPIRV_COMPRESSION option to cmake
The option is off by default.
cmake -DSPIRV_BUILD_COMPRESSION=ON ..
enables the compression lib, executable, and test build.

Fixes https://github.com/KhronosGroup/SPIRV-Tools/issues/834
2017-09-25 14:37:08 -04:00
David Neto
d16403afb2 Create v2017.0
Update README to describe that we understand SPIR-V syntax based on the
grammar files included from the SPIRV-Headers repo.

(Also, it's high time we issue a v2017 release!
2017-09-01 16:26:09 -04:00
GregF
cdeb669541 README: Add reference to SPIR-V size reduction white paper 2017-08-25 15:11:24 -04:00
Lei Zhang
768d9b42d3 Support supplying extra definitions via CMAKE variable 2017-08-16 17:38:48 -04:00
GregF
0bd8300fc2 Update README.md with new code-reduction passes 2017-08-04 17:47:41 -04:00