1. 04 Mar, 2019 2 commits
  2. 02 Mar, 2019 1 commit
  3. 01 Mar, 2019 4 commits
  4. 28 Feb, 2019 13 commits
  5. 27 Feb, 2019 16 commits
  6. 26 Feb, 2019 4 commits
    • Add Print helpers to reactor · 1bc7ee95
      Ben Clayton authored
      New tools for debugging JITed code.
      
      rr::Print() is a new function that emits a call to printf() using the provided message and optional values. There is also an overload that accepts additional file, line, and function parameters to help identify the call site.
      
      Format values passed to rr::Print() are implicity cast to a new rr::PrintValues type which does the work of dispatching the value type to the correct printf() format specifier(s) and argument value(s). A single rr::Print() format value can automatically be expanded into multiple printf values - for example an rr::Float4 will expand to "%f %f %f %f" and four scalar float values.
      
      rr::Print() format values can be any of the following types:
        * Reactor LValues, RValues, Pointers.
        * Standard Plain-Old-Value types (int, float, bool, etc)
        * Custom types that specialize the PrintValue::Ty template struct.
        * Static arrays in the form T[N] where T can be any of the above.
      
      The sw::Vector4f and sw::Vector4s types have already had custom formatters written.
      
      These new functions and types described above are typically not called directly. Instead there are two helper macros which simplifies usage:
      
      RR_LOG() is a new macro that wraps rr::Print(), automatically populating the function, file and line parameters and appending a newline to the string.
      
      RR_WATCH() is a new helper macro that prints the name and value of all the supplied arguments. For example, if you had the Int and bool variables 'foo' and 'bar' that you want to print, you can simply write:
      
          RR_WATCH(foo, bar)
      
      When this JIT compiled code is executed, it will print:
          "foo: 1, bar: true"
      
      All of this code is disabled in non-debug builds, or if the reactor backend is not LLVM 7+.
      
      Change-Id: Ia39b1e507b6afaa3bb1d33e40b1333017f4b4f21
      Reviewed-on: https://swiftshader-review.googlesource.com/c/24768Tested-by: 's avatarChris Forbes <chrisforbes@google.com>
      Reviewed-by: 's avatarChris Forbes <chrisforbes@google.com>
      Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
    • VS build fix · 7f6f8912
      Alexis Hetu authored
      Change-Id: I7e6589870b539e775371e8941a07a48ca9e0cad7
      Reviewed-on: https://swiftshader-review.googlesource.com/c/25628Tested-by: 's avatarAlexis Hétu <sugoi@google.com>
      Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
      Reviewed-by: 's avatarChris Forbes <chrisforbes@google.com>
    • Fix point rendering · 54c4772e
      Chris Forbes authored
      - Point size limits were left at [0,0], forcing all points to zero coverage.
        Introduce a config value for the maximum, and plumb this through to drive
        physical device limits query.
      
      - Fix all interpolants being replaced with pointcoord
      
      Bug: b/124177079
      
      Change-Id: I281dd3214537f15858afbd3890cf70f8850fa4aa
      Reviewed-on: https://swiftshader-review.googlesource.com/c/25489Tested-by: 's avatarChris Forbes <chrisforbes@google.com>
      Reviewed-by: 's avatarAlexis Hétu <sugoi@google.com>
      Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
    • OpAccessChain: Remove pointer walking inside loop · 8adf1fcd
      Chris Forbes authored
      This cannot occur. The initial stripping of <base>'s pointer type is
      already handled outside the loop.
      
      Bug: b/124388146
      
      Change-Id: I55ea64e868308bfbab72aaefca0fd367916f6e69
      Reviewed-on: https://swiftshader-review.googlesource.com/c/25488Reviewed-by: 's avatarAlexis Hétu <sugoi@google.com>
      Tested-by: 's avatarChris Forbes <chrisforbes@google.com>
      Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>