1. 21 Nov, 2017 4 commits
    • D3D11: Lazy evaluation for draw call vertex params. · 378734c5
      Jamie Madill authored
      The vertex params are the 'start' vertex index and the number of
      vertices in the draw call. For indexed draws, they sometimes mean we
      need to compute the index range. In other cases, we don't. Defer
      computing the index range as long as possible so we don't end up
      computing the index range when we don't have to.
      
      BUG=angleproject:2229
      
      Change-Id: I8e125416ef6767787a14509b322efa8dcd8e4a34
      Reviewed-on: https://chromium-review.googlesource.com/764676
      Commit-Queue: Jamie Madill <jmadill@chromium.org>
      Reviewed-by: 's avatarYuly Novikov <ynovikov@chromium.org>
    • Remove unreferenced struct types from the AST · 39f74df5
      Olli Etuaho authored
      This expands pruning unreferenced variables so that unreferenced named
      struct types can also be removed from the AST.
      
      Includes a small cleanup in GLSL output so that the output code
      matching tests can test against clean output.
      
      BUG=chromium:786535
      TEST=angle_unittests
      
      Change-Id: I20974ac99a797e478d82f9203c179d2d58fac268
      Reviewed-on: https://chromium-review.googlesource.com/779519
      Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
      Reviewed-by: 's avatarCorentin Wallez <cwallez@chromium.org>
    • D3D11: Push index range computation deeper. · 03fd0356
      Jamie Madill authored
      If we can make the index range computation happen as late as possible,
      we won't have to check it during the fastest draw call paths.
      
      This change makes it easier to skip re-computing some index range
      checks by only checking it in one place in IndexDataManager, and by
      making it a lazy check; the check is never evaluated if the primitive
      restart workaround is not enabled.
      
      Future work can also push the index range computation for vertex info
      later, so we only evaluate it in the cases where we need it.
      
      BUG=angleproject:2229
      
      Change-Id: Ic55fac9e23fd35a119ddff475355a43095d2e3e9
      Reviewed-on: https://chromium-review.googlesource.com/764675
      Commit-Queue: Jamie Madill <jmadill@chromium.org>
      Reviewed-by: 's avatarYuly Novikov <ynovikov@chromium.org>
      Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org>
    • Revert "Make TType store a const char * for mangled name." · c7965001
      Jamie Madill authored
      This reverts commit dc7bffd0.
      
      Reason for revert: Causes a memory leak, detected by ASAN bot:
      
      https://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_asan_rel_ng/builds/494713
      
      Direct leak of 24 byte(s) in 1 object(s) allocated from:
          #0 0x847aa2 in operator new(unsigned long) /b/build/slave/linux_upload_clang/build/src/third_party/llvm/compiler-rt/lib/asan/asan_new_delete.cc:92:3
          #1 0x193a833 in sh::TType::buildMangledName() const third_party/angle/src/compiler/translator/Types.cpp:545:21
          #2 0x193d2e8 in getMangledName third_party/angle/src/compiler/translator/Types.cpp:751:24
          #3 0x193d2e8 in sh::TType::realize() third_party/angle/src/compiler/translator/Types.cpp:759
          #4 0x1834474 in sh::TCache::getType(sh::TBasicType, sh::TPrecision, sh::TQualifier, unsigned char, unsigned char) third_party/angle/src/compiler/translator/Cache.cpp:89:11
          #5 0x1859ac7 in getType third_party/angle/src/compiler/translator/Cache.h:36:16
          #6 0x1859ac7 in sh::InsertBuiltInFunctions(unsigned int, ShShaderSpec, ShBuiltInResources const&, sh::TSymbolTable&) third_party/angle/src/compiler/translator/Initialize.cpp:28
      
      Bug: angleproject:1432
      
      Original change's description:
      > Make TType store a const char * for mangled name.
      > 
      > We would only ever use the c_str value from the mangled name. This
      > makes it easier to make constexpr TTypes.
      > 
      > Bug: angleproject:1432
      > Change-Id: I147b3a85f9b8b2453e2d7f4a713d767b22036cc9
      > Reviewed-on: https://chromium-review.googlesource.com/776277
      > Commit-Queue: Jamie Madill <jmadill@chromium.org>
      > Reviewed-by: Kai Ninomiya <kainino@chromium.org>
      
      TBR=jmadill@chromium.org,kainino@chromium.org
      
      # Not skipping CQ checks because original CL landed > 1 day ago.
      
      Bug: angleproject:1432
      Change-Id: Ib112a2ce9871a4f4afc53101ac1a3ddd166008cf
      Reviewed-on: https://chromium-review.googlesource.com/780420Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org>
  2. 20 Nov, 2017 9 commits
  3. 18 Nov, 2017 4 commits
  4. 17 Nov, 2017 6 commits
  5. 16 Nov, 2017 7 commits
  6. 15 Nov, 2017 7 commits
  7. 14 Nov, 2017 3 commits