Rolling 5 dependencies

Roll third_party/SPIRV-Tools/ 0c4feb643..29af42df1 (44 commits)

https://chromium.googlesource.com/external/github.com/KhronosGroup/SPIRV-Tools/+log/0c4feb643b89..29af42df12a3

$ git log 0c4feb643..29af42df1 --date=short --no-merges --format='%ad %ae %s'
2019-08-08 greg Add SPV_EXT_physical_storage_buffer to opt whitelists (#2779)
2019-08-07 stevenperron Handle RelaxedPrecision in SROA (#2788)
2019-08-07 zoddicus Add -fextra-semi to Clang builds (#2787)
2019-08-05 afdx Add 'copy object' transformation (#2766)
2019-08-02 paulthomson fuzz: change output extension and fix usage string (#2778)
2019-08-01 geoff Remove extra ';' after member function definition. (#2780)
2019-07-31 zoddicus Update WebGPU validation rules of OpAtomic*s (#2777)
2019-07-31 alanbaker Treat access chain indexes as signed in SROA (#2776)
2019-07-30 dneto Add pass to inject code for robust-buffer-access semantics (#2771)
2019-07-30 zoddicus Update OpMemoryBarriers rules for WebGPU (#2775)
2019-07-30 dneto Add opt test fixture method SinglePassRunAndFail (#2770)
2019-07-29 dneto Element type is const for analysis::Vector,Matrix,RuntimeArray (#2765)
2019-07-29 dnovillo Protect against out-of-bounds references when folding OpCompositeExtract (#2774)
2019-07-29 alanbaker Don't move debug or decorations when folding (#2772)
2019-07-29 zoddicus Update OpControlBarriers rules for WebGPU (#2769)
2019-07-26 dnovillo Fix #2609 - Handle out-of-bounds scalar replacements. (#2767)
2019-07-25 afdx Limit fuzzer tests so that they take less time to run (#2763)
2019-07-25 stevenperron Fix check for unreachable blocks in merge-return (#2762)
2019-07-25 afdx Transformation and fuzzer pass to add dead continues (#2758)
2019-07-24 zoddicus Remove unneeded future imports (#2739)
2019-07-24 stevenperron Process OpDecorateId in ADCE (#2761)
2019-07-24 stevenperron Record correct dominators in merge return (#2760)
2019-07-23 stevenperron SSA rewriter: Don't use trivial phis (#2757)
2019-07-23 alanbaker Fix block depth rule priority (#2755)
2019-07-23 alanbaker Case validation with repeated labels (#2689)
2019-07-22 greg Bindless Instrument: Make init check depend solely on input_init_enabled (#2753)
2019-07-22 kevin.petit Validate storage class OpenCL environment rules for atomics (#2750)
2019-07-22 51214578+jmacnak-nv Allow LOD ops in compute shaders with derivative group execution modes (#2752)
2019-07-18 dneto Document opt::Instruction::InsertBefore methods (#2751)
2019-07-17 stevenperron Revert "Do not inline OpKill Instructions (#2713)" (#2749)
2019-07-16 jbolz For Vulkan, disallow structures containing opaque types (#2546)
2019-07-16 stevenperron Fix bug in merge return (#2734)
2019-07-15 51214578+jmacnak-nv Allow ray tracing shaders in inst bindle check pass. (#2733)
2019-07-12 zoddicus Correctly implement WebGPU related flag exclusions (#2737)
2019-07-12 greg Remove Common Uniform Elimination Pass (#2731)
2019-07-12 cwallez BUILD.gn: Add deps and move files for `gn check` (#2735)
2019-07-11 zoddicus Update execution scope rules for WebGPU (#2730)
2019-07-11 33432579+alan-baker Extra small storage validation (#2732)
2019-07-11 jbolz Add validation for SPV_EXT_demote_to_helper_invocation (#2707)
2019-07-10 52076061+digit-google BUILD.gn: Add targets to build all command-line tools (#2727)
2019-07-10 stevenperron Change the order branches are simplified in dead branch elim (#2728)
2019-07-11 troughton Add —preserve-bindings and —preserve-spec-constants (#2693)
2019-07-10 stevenperron Handle decorations better in some optimizations (#2716)
2019-07-10 zoddicus Update memory scope rules for WebGPU (#2725)

Roll third_party/glslang/ 8aa9a7bb8..3cea2e588 (28 commits)

https://chromium.googlesource.com/external/github.com/KhronosGroup/glslang/+log/8aa9a7bb8f74..3cea2e5882e3

$ git log 8aa9a7bb8..3cea2e588 --date=short --no-merges --format='%ad %ae %s'
2019-08-02 cepheus Bump revision and give the bots another chance to work.
2019-08-01 rharrison Add in header for uint32_t definition
2019-07-30 rharrison Convert no RTTI rule to be compiler specific
2019-07-28 lryer Fix Clang compiler warning.
2019-07-28 lryer Fix location distribution not in order
2019-07-25 stevenperron Remove execute permission from LICENSE.txt
2019-07-25 lryer Fix memory init issue, to make sure the class members are init in order.
2019-07-23 cepheus Revert "Merge pull request #1792 from Roy-AMD/automapping-opengl-location"
2019-07-22 alele Fix bugs in missing Builtin decoration for some NV builtins for tessellation control shaders. Fix bug in member remapping.
2019-07-22 cepheus SPV: Update to latest SPIR-V header.
2019-07-18 greg Update spirv-tools and spirv-headers known good.
2019-07-17 cepheus Build: shut up warning to add unnecessary parens.
2019-07-17 alele Fix bug in printing trailing comma when dumping AST for a structure.
2019-07-16 jmacnak Update known good SPIRV-Tools commit
2019-07-15 sparmar Allow unsized view array dimension for non-block perviewNV attributes
2019-07-15 cepheus ESSL: Fix #1823: Conditions for when derivatives are in compute shader.
2019-07-15 rex.xu OpIsHelperInvocationEXT should declare relevant SPV extension and capability
2019-07-13 cepheus GLSL: Fix #1833: Don't constant fold integer mix to a float.
2019-07-12 jmacnak spirv: Generate missing SampleMaskOverrideCoverageNV capability op
2019-07-12 rharrison Explicitly remove RTTI in the top-level build config
2019-07-10 aaron.hagan Add support for SPV_KHR_shader_clock
2019-07-10 jbolz Avoid generating 8/16-bit constants when 8/16-bit arithmetic extensions aren't enabled
2019-07-08 alanbaker Test updates
2019-07-08 alanbaker Update SPIRV-Tools revision
2019-07-03 cepheus SPV: Fix #1783: Don't do bounds checking for spec-const-expression size
2019-06-25 jbolz Handle SPIR-V type mismatch when constructing a composite
2019-06-07 lryer code format refine
2019-06-06 lryer Add interface symbol and uniform symbol location auto mapping for OpenGL shader.

Roll third_party/shaderc/ e9bb8f287..b3b228c60 (10 commits)

https://chromium.googlesource.com/external/github.com/google/shaderc/+log/e9bb8f287417..b3b228c60d63

$ git log e9bb8f287..b3b228c60 --date=short --no-merges --format='%ad %ae %s'
2019-08-07 zoddicus Rolling 7 dependencies (#776)
2019-08-01 zoddicus Only use -fPIC on compilers that support it (#772)
2019-08-01 zoddicus Turn on warnings on about missing semi-colons (#770)
2019-07-31 yizhou.jiang Remove extra semicolons in shaderc (#768)
2019-07-19 dneto Be more pythonic about "not in" (#763)
2019-07-18 dneto Fix typo (#762)
2019-07-16 dneto Avoid C-style cast for constants definitions (#760)
2019-07-16 jbolz SetBeforeHlslLegalization to use more relaxed validation rules (#676)
2019-07-16 krzysio.kurek Explicitly use python3 for git-sync-deps (#759)
2019-07-09 dneto Remove app_dummy call in Android test (#756)

Roll third_party/spirv-cross/ 53ab2144b..4ce04480e (79 commits)

https://chromium.googlesource.com/external/github.com/KhronosGroup/SPIRV-Cross/+log/53ab2144b90a..4ce04480ec54

$ git log 53ab2144b..4ce04480e --date=short --no-merges --format='%ad %ae %s'
2019-08-01 post Fix severe performance issue with invariant expression invalidation.
2019-07-26 cdavis MSL: Unify the get_*_address_space() methods.
2019-07-26 post MSL: Cleanup temporary use with emit_uninitialized_temporary.
2019-07-26 post MSL: Deal with Modf/Frexp where output is access chain to scalar.
2019-07-26 post Do not force temporary unless continue-only for loop dominates.
2019-07-25 post Missed case where DoWhile continue block deals with Phi.
2019-07-25 post Vulkan GLSL: Support disabling samplerless texture function EXT.
2019-07-25 post Workaround MSVC 2013 compiler issues.
2019-07-22 cdavis MSL: Adjust BuiltInWorkgroupId for vkCmdDispatchBase().
2019-07-24 post Fix some typos in comments.
2019-07-24 post Do not attempt to pack types which are already scalar.
2019-07-24 post HLSL query lod cleanups.
2019-07-24 post Do not eagerly invalidate all active variables on a branch.
2019-07-23 post Do not disable temporary forwarding when we suppress usage tracking.
2019-07-23 post Add another test for unpacking without load forwarding.
2019-07-23 post Look at pointee type when unpacking expressions.
2019-07-23 post Fix some warnings when building in MoltenVK.
2019-07-23 post Deal correctly with non-forwarded packed loads.
2019-07-23 post Test CompositeInsert/Extract/VectorShuffle on packed vectors.
2019-07-23 post Add test for array of scalar struct.
2019-07-23 post Recursively pack struct types when we find scalar packed structs.
2019-07-23 post Run format_all.sh.
2019-07-23 post Unpack vector expression in Matrix-Vector multiplies.
2019-07-23 post Test matrix multiplies in more complex scenarios.
2019-07-23 post Test implicit packing of struct members.
2019-07-23 post GLSL/HLSL: Verify member alignment for explicit offset as well.
2019-07-23 post Add tests for struct padding and self-alignment.
2019-07-23 post Use to_unpacked_row_major_expression to unify row-major in MSL/GLSL.
2019-07-23 post Simplify row-major matrix/vector multiplies.
2019-07-23 post Test array of std140 vectors.
2019-07-23 post Add struct size padding tests.
2019-07-22 post Add test for CompositeExtract from row-major loaded vector.
2019-07-22 post Add test for split access chain into row-major matrix.
2019-07-22 post Remove obsolete matrix workaround code.
2019-07-22 post Only transpose unpacked expressions.
2019-07-22 post Deal correctly with complete stores to row_major matrices.
2019-07-22 post Declare correct matrix type when unpacking.
2019-07-22 post Don't forget to register a write to LHS expression in certain case.
2019-07-22 post Deal with swizzled stores to std140 matrices.
2019-07-22 post Fix some row-major column store cases.
2019-07-22 post Fix more stray parens.
2019-07-22 post Fixup stray parent in output.
2019-07-22 post Correctly unpack row-major matrices when storing to LHS.
2019-07-22 post MSL: Add std140 and scalar matrix layouts.
2019-07-22 post MSL: Add std430 matrix access test.
2019-07-22 post MSL: Support storing to row-major column.
2019-07-22 post Tests run clean.
2019-07-19 post Fix unpacking of packed but not remapped types on load.
2019-07-19 post Traverse correct types when checking scalar layout.
2019-07-19 post Deal with scalar layout of entire structs.
2019-07-19 post Pass down row-major state to unpacking functions.
2019-07-19 post Deal with all forms of matrix writes ...
2019-07-19 post Can deal with std140 matrices now.
2019-07-18 post Start considering how to emit physical type ID.
2019-07-18 post Deal more cleanly with matrices and row-major.
2019-07-18 post Reintroduce struct_member_* MSL queries.
2019-07-18 post MSL: Begin rewrite of buffer packing logic.
2019-07-18 cdavis Don't forward uses of an OpIsHelperInvocationEXT op.
2019-07-13 cdavis Support the SPV_EXT_demote_to_helper_invocation extension.
2019-07-17 post Test glsl.std450 more exhaustively.
2019-07-11 cdavis MSL: Support the SPV_INTEL_shader_integer_functions2 extension.
2019-07-11 cdavis Update external repos.
2019-07-12 cdavis Support the SPV_KHR_device_group extension.
2019-07-11 cdavis MSL: Support the SPV_AMD_shader_trinary_minmax extension.
2019-07-12 post Run format_all.sh.
2019-07-12 post Deal correctly with return sign of bitscan operations.
2019-07-10 post MSVC 2015: Workaround bogus warning with move_backwards.
2019-07-10 post MSVC: Fix some warnings in C wrapper.
2019-07-10 cdavis MSL: Use the select() function for OpSelect.
2019-07-10 cdavis Support the SPV_KHR_post_depth_coverage extension.
2019-07-10 cdavis MSL: Handle coherent, volatile, and restrict.
2019-07-11 post GLSL: Need extension to use bitcast on GLSL < 330.
2019-07-11 lifeng.pan Remove unreasonable assertion for OpTypeImage Sampled parameter.
2019-07-10 cdavis MSL: Handle packed matrices.
2019-07-10 cdavis MSL: Fix alignment of packed types.
2019-07-10 post Forget loop variable enables after emitting block chain.
2019-07-10 post MSL: Re-roll array expressions in initializers.
2019-07-09 cdavis MSL: Support scalar block layout.
2019-07-09 post MSVC 2013: Work around another compiler bug with array init.

Roll third_party/spirv-headers/ 29c11140b..e4322e3be (2 commits)

https://chromium.googlesource.com/external/github.com/KhronosGroup/SPIRV-Headers/+log/29c11140baaf..e4322e3be589

$ git log 29c11140b..e4322e3be --date=short --no-merges --format='%ad %ae %s'
2019-07-14 aaron.hagan Add SPV_KHR_shader_clock to spirv-headers
2019-07-12 michael.kinsner Reserve additional loop control bit for upcoming update to SPV_INTEL_fpga_loop_controls extension

Created with:
  roll-dep third_party/SPIRV-Tools third_party/glslang third_party/shaderc third_party/spirv-cross third_party/spirv-headers

Change-Id: I95453760ca570a96082672178b0ebd6908e112d5
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/9840
Commit-Queue: Kai Ninomiya <kainino@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
1 file changed
tree: dc11b69c84f04899a6dd44d8ef1e3d37e5acc78d
  1. build_overrides/
  2. docs/
  3. examples/
  4. generator/
  5. infra/
  6. scripts/
  7. src/
  8. third_party/
  9. .clang-format
  10. .gitattributes
  11. .gitignore
  12. .gn
  13. AUTHORS
  14. BUILD.gn
  15. codereview.settings
  16. CONTRIBUTING.md
  17. dawn.json
  18. dawn_wire.json
  19. DEPS
  20. LICENSE
  21. OWNERS
  22. PRESUBMIT.py
  23. README.chromium
  24. README.md
README.md

Dawn, a WebGPU implementation

Dawn (formerly NXT) is an open-source and cross-platform implementation of the work-in-progress WebGPU standard. It exposes a C/C++ API that maps almost one-to-one to the WebGPU IDL and can be managed as part of a larger system such as a Web browser.

Dawn provides several WebGPU building blocks:

  • WebGPU C/C++ headers that applications and other building blocks use.
  • A “native” implementation of WebGPU using platforms' GPU APIs:
    • D3D12 on Windows 10
    • Metal on OSX (and eventually iOS)
    • Vulkan on Windows, Linux (eventually ChromeOS and Android too)
    • OpenGL as best effort where available
  • A client-server implementation of WebGPU for applications that are in a sandbox without access to native drivers

Directory structure

  • dawn.json: description of the API used to drive code generators.
  • examples: examples showing how Dawn is used.
  • generator: code generator for files produces from dawn.json
    • templates: Jinja2 templates for the generator
  • scripts: scripts to support things like continuous testing, build files, etc.
  • src:
    • common: helper code shared between core Dawn libraries and tests/samples
    • dawn_native: native implementation of WebGPU, one subfolder per backend
    • dawn_wire: client-server implementation of WebGPU
    • include: public headers for Dawn
    • tests: internal Dawn tests
      • end2end: WebGPU tests performing GPU operations
      • unittests: unittests and by extension tests not using the GPU
        • validation: WebGPU validation tests not using the GPU (frontend tests)
    • utils: helper code to use Dawn used by tests and samples
  • third_party: directory where dependencies live as well as their buildfiles.

Building Dawn

Dawn uses the Chromium build system and dependency management so you need to install depot_tools and add it to the PATH.

On Linux you need to have the pkg-config command:

# Install pkg-config on Ubuntu
sudo apt-get install pkg-config

Then get the source as follows:

# Clone the repo as "dawn"
git clone https://dawn.googlesource.com/dawn dawn && cd dawn

# Bootstrap the gclient configuration
cp scripts/standalone.gclient .gclient

# Fetch external dependencies and toolchains with gclient
gclient sync

Then generate build files using gn args out/Debug or gn args out/Release. A text editor will appear asking build options, the most common option is is_debug=true/false; otherwise gn args out/Release --list shows all the possible options.

Then use ninja -C out/Release to build dawn and for example ./out/Release/dawn_end2end_tests to run the tests.

Contributing

Please read and follow CONTRIBUTING.md. Dawn doesn‘t have a formal coding style yet, except what’s defined by our clang format style. Overall try to use the same style and convention as code around your change.

If you find issues with Dawn, please feel free to report them on the bug tracker. For other discussions, please post to Dawn's mailing list.

License

Please see LICENSE.

Disclaimer

This is not an officially supported Google product.