1. 28 Sep, 2016 1 commit
    • Fix handling integer overflow in constant folding · 1be4d493
      Olli Etuaho authored
      Integer operations that overflow are defined to wrap in the ESSL
      3.00.6 spec. Constant folding that happens inside the shader
      translator should also follow the wrapping rules.
      
      The new implementations of wrapping integer addition and subtraction
      use unsigned integers to perform calculations. Unsigned integers are
      defined to implement arithmetic in modulo 2^n in the C++ spec. This
      behavior is also leveraged to implement wrapping unsigned integer
      multiplication.
      
      The implementation of wrapping signed integer multiplication is
      slightly trickier. The operands are casted to a wider type to perform
      the multiplication in a way that doesn't overflow, and then the result
      is truncated and casted back to the narrower integer type.
      
      Incorrect tests that expected errors to be generated from integer
      overflow in constant folding are removed.
      
      BUG=chromium:637050
      TEST=angle_unittests
      
      Change-Id: I0de7e25881d254803455fbf22907c192f49d09ff
      Reviewed-on: https://chromium-review.googlesource.com/390252
      Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
      Reviewed-by: 's avatarCorentin Wallez <cwallez@chromium.org>
  2. 27 Sep, 2016 5 commits
  3. 26 Sep, 2016 2 commits
  4. 23 Sep, 2016 5 commits
  5. 22 Sep, 2016 10 commits
  6. 21 Sep, 2016 3 commits
  7. 20 Sep, 2016 3 commits
  8. 19 Sep, 2016 3 commits
  9. 16 Sep, 2016 3 commits
  10. 15 Sep, 2016 4 commits
  11. 14 Sep, 2016 1 commit