1. 13 May, 2019 4 commits
  2. 12 May, 2019 1 commit
  3. 11 May, 2019 2 commits
  4. 10 May, 2019 11 commits
  5. 09 May, 2019 18 commits
  6. 08 May, 2019 4 commits
    • Reactor (LLVM): Add support for Coroutines. · 1c82c7b8
      Ben Clayton authored
      rr::Coroutines are similar to rr::Functions in that it builds a new
      executable function, but Coroutines have the following differences:
        (1) Coroutines do not support Return() statements.
        (2) Coroutines support Yield() statements to suspend execution of the
            coroutine and pass a value up to the caller. Yield can be called multiple
            times in a single execution of a coroutine.
        (3) The template argument T to Coroutine<T> is a C-style function
            signature.
        (4) Coroutine::operator() returns a rr::Stream<T> instead of an
            rr::Routine.
        (5) operator() starts execution of the coroutine immediately.
        (6) operator() uses the Coroutine's template function signature to
            ensure the argument types match the generated function signature.
      
      It is my personal opinion that (3), (5) and (6) provide a more convenient and
      safer interface and this could be adopted by rr::Function (post immediate
      milestone).
      
      Coroutines expose 3 externally callable functions:
      (1) 'coroutine_begin' - the main entry point of the coroutine.
          Allocates a coroutine stack frame, and executes up to the first call to
          Yield().
      (2) 'coroutine_await' - the function to collect a yielded value and resume
          execution of the suspended coroutine.
      (3) 'coroutine_destroy' - the function to destruct and release the coroutine
          stack frame.
      
      As there are now three exposed functions for coroutines, rr::Routine::getEntry()
      now takes a function index. Standard rr::Functions always pass 0.
      rr::Nucleus::CoroutineEntries is an enumerator of these coroutine functions that
      correspond to the function index passed to rr::Routine::getEntry().
      
      This change also adds third_party/llvm-7.0/stubs/Stubs.cpp. This file holds stub
      functions that are never called by LLVM, but are referenced by the linker.
      Actually linking in the file that declares these functions will drag in more
      referenced files, significantly slowing the build and potentially bloating the
      final executable size.
      
      Coroutines are not currently supported by Subzero.
      
      Bug: b/131672705
      Change-Id: I0b13fe38b84c8dc85f4678019bf8d8afa7d9c37a
      Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/30212Tested-by: 's avatarBen Clayton <bclayton@google.com>
      Presubmit-Ready: Ben Clayton <bclayton@google.com>
      Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
      Reviewed-by: 's avatarNicolas Capens <nicolascapens@google.com>
    • Flatten required bits of imageview into SampledImageDescriptor · 45f9a930
      Chris Forbes authored
      Bug: b/123244275
      Bug: b/129523279
      Change-Id: I46e59313ac152ba493fad78cfcdadbcd31566554
      Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/30929
      Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
      Tested-by: 's avatarChris Forbes <chrisforbes@google.com>
      Reviewed-by: 's avatarNicolas Capens <nicolascapens@google.com>
    • SpirvShader: Implement OpImageQuerySizeLod · 0264d8e1
      Ben Clayton authored
      Tests: dEQP-VK.ycbcr.query.size_lod.*
      Tests: dEQP-VK.glsl.texture_functions.query.texturesize.*
      Bug: b/129523279
      Change-Id: I0a0db0f462d51b6b650ce798eacc66977a3fe896
      Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/30853
      Presubmit-Ready: Ben Clayton <bclayton@google.com>
      Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
      Reviewed-by: 's avatarNicolas Capens <nicolascapens@google.com>
      Tested-by: 's avatarBen Clayton <bclayton@google.com>
    • SpirvShader: Implement workgroup storage. · ecd38484
      Ben Clayton authored
      I couldn't find any tests that did not rely on another feature being implemented.
      
      Bug: b/131667866
      Change-Id: Ic872c06865b9c7a2bafffbe733f79718ba1505e5
      Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/30209
      Presubmit-Ready: Ben Clayton <bclayton@google.com>
      Reviewed-by: 's avatarNicolas Capens <nicolascapens@google.com>
      Tested-by: 's avatarBen Clayton <bclayton@google.com>
      Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>