Rename GrMesh to GrSimpleMesh

Change-Id: Ib164ff3ec41cb798385f2feea8ad09c037dbc30d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/276837
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
diff --git a/bench/VertexColorSpaceBench.cpp b/bench/VertexColorSpaceBench.cpp
index d73ceed..5ef3f2d 100644
--- a/bench/VertexColorSpaceBench.cpp
+++ b/bench/VertexColorSpaceBench.cpp
@@ -270,7 +270,7 @@
     SkColor4f fColor4f;
     sk_sp<GrColorSpaceXform> fColorSpaceXform;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/gm/beziereffects.cpp b/gm/beziereffects.cpp
index 61fe200..32786bc 100644
--- a/gm/beziereffects.cpp
+++ b/gm/beziereffects.cpp
@@ -127,7 +127,7 @@
     const SkPMColor4f& color() const { return fColor; }
 
 protected:
-    GrMesh*              fMesh = nullptr;  // filled in by the derived classes
+    GrSimpleMesh*        fMesh = nullptr;  // filled in by the derived classes
 
 private:
     SkRect               fRect;
diff --git a/gn/gpu.gni b/gn/gpu.gni
index bcb522d..6c778e9 100644
--- a/gn/gpu.gni
+++ b/gn/gpu.gni
@@ -113,7 +113,6 @@
   "$_src/gpu/GrManagedResource.h",
   "$_src/gpu/GrMemoryPool.cpp",
   "$_src/gpu/GrMemoryPool.h",
-  "$_src/gpu/GrMesh.h",
   "$_src/gpu/GrNativeRect.h",
   "$_src/gpu/GrNonAtomicRef.h",
   "$_src/gpu/GrOnFlushResourceProvider.cpp",
@@ -184,6 +183,7 @@
   "$_src/gpu/GrShaderUtils.h",
   "$_src/gpu/GrShaderVar.cpp",
   "$_src/gpu/GrShaderVar.h",
+  "$_src/gpu/GrSimpleMesh.h",
   "$_src/gpu/GrSoftwarePathRenderer.cpp",
   "$_src/gpu/GrSoftwarePathRenderer.h",
   "$_src/gpu/GrStencilAttachment.cpp",
diff --git a/src/gpu/GrGpu.cpp b/src/gpu/GrGpu.cpp
index b44b518..6ae5308 100644
--- a/src/gpu/GrGpu.cpp
+++ b/src/gpu/GrGpu.cpp
@@ -19,7 +19,6 @@
 #include "src/gpu/GrContextPriv.h"
 #include "src/gpu/GrDataUtils.h"
 #include "src/gpu/GrGpuResourcePriv.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrNativeRect.h"
 #include "src/gpu/GrPathRendering.h"
 #include "src/gpu/GrPipeline.h"
diff --git a/src/gpu/GrGpu.h b/src/gpu/GrGpu.h
index aa10bd8..3a96c26 100644
--- a/src/gpu/GrGpu.h
+++ b/src/gpu/GrGpu.h
@@ -27,7 +27,6 @@
 class GrContext;
 struct GrContextOptions;
 class GrGLContext;
-class GrMesh;
 class GrPath;
 class GrPathRenderer;
 class GrPathRendererChain;
diff --git a/src/gpu/GrOpFlushState.cpp b/src/gpu/GrOpFlushState.cpp
index 10d7b45..a67b379 100644
--- a/src/gpu/GrOpFlushState.cpp
+++ b/src/gpu/GrOpFlushState.cpp
@@ -131,7 +131,7 @@
 
 void GrOpFlushState::recordDraw(
         const GrGeometryProcessor* gp,
-        const GrMesh meshes[],
+        const GrSimpleMesh meshes[],
         int meshCnt,
         const GrPipeline::FixedDynamicState* fixedDynamicState,
         const GrPipeline::DynamicStateArrays* dynamicStateArrays,
diff --git a/src/gpu/GrOpFlushState.h b/src/gpu/GrOpFlushState.h
index 123e6d3..a59d98e 100644
--- a/src/gpu/GrOpFlushState.h
+++ b/src/gpu/GrOpFlushState.h
@@ -116,7 +116,7 @@
 
     /** Overrides of GrMeshDrawOp::Target. */
     void recordDraw(const GrGeometryProcessor*,
-                    const GrMesh[],
+                    const GrSimpleMesh[],
                     int meshCnt,
                     const GrPipeline::FixedDynamicState*,
                     const GrPipeline::DynamicStateArrays*,
@@ -175,7 +175,7 @@
         const GrGeometryProcessor* fGeometryProcessor = nullptr;
         const GrPipeline::FixedDynamicState* fFixedDynamicState = nullptr;
         const GrPipeline::DynamicStateArrays* fDynamicStateArrays = nullptr;
-        const GrMesh* fMeshes = nullptr;
+        const GrSimpleMesh* fMeshes = nullptr;
         const GrOp* fOp = nullptr;
         int fMeshCnt = 0;
         GrPrimitiveType fPrimitiveType;
diff --git a/src/gpu/GrOpsRenderPass.cpp b/src/gpu/GrOpsRenderPass.cpp
index d0f352f..2c17828 100644
--- a/src/gpu/GrOpsRenderPass.cpp
+++ b/src/gpu/GrOpsRenderPass.cpp
@@ -13,11 +13,11 @@
 #include "src/gpu/GrContextPriv.h"
 #include "src/gpu/GrFixedClip.h"
 #include "src/gpu/GrGpu.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrPrimitiveProcessor.h"
 #include "src/gpu/GrProgramInfo.h"
 #include "src/gpu/GrRenderTarget.h"
 #include "src/gpu/GrRenderTargetPriv.h"
+#include "src/gpu/GrSimpleMesh.h"
 #include "src/gpu/GrTexturePriv.h"
 
 void GrOpsRenderPass::clear(const GrFixedClip& clip, const SkPMColor4f& color) {
@@ -157,7 +157,7 @@
     this->bindTextures(primProc, &ptr, pipeline);
 }
 
-void GrOpsRenderPass::drawMeshes(const GrProgramInfo& programInfo, const GrMesh meshes[],
+void GrOpsRenderPass::drawMeshes(const GrProgramInfo& programInfo, const GrSimpleMesh meshes[],
                                  int meshCount) {
     if (programInfo.hasFixedScissor()) {
         this->setScissorRect(programInfo.fixedScissor());
diff --git a/src/gpu/GrOpsRenderPass.h b/src/gpu/GrOpsRenderPass.h
index 9ecc22f..b0dc9d6 100644
--- a/src/gpu/GrOpsRenderPass.h
+++ b/src/gpu/GrOpsRenderPass.h
@@ -15,7 +15,7 @@
 class GrOpFlushState;
 class GrFixedClip;
 class GrGpu;
-class GrMesh;
+class GrSimpleMesh;
 class GrPipeline;
 class GrPrimitiveProcessor;
 class GrProgramInfo;
@@ -87,7 +87,7 @@
     //
     // NOTE: This method will soon be deleted. While it continues to exist, it takes care of calling
     // setScissor() and bindTextures() on the client's behalf.
-    void drawMeshes(const GrProgramInfo&, const GrMesh[], int meshCount);
+    void drawMeshes(const GrProgramInfo&, const GrSimpleMesh[], int meshCount);
 
     // These methods issue draws using the current pipeline state. Before drawing, the caller must
     // configure the pipeline and dynamic state:
diff --git a/src/gpu/GrPipeline.h b/src/gpu/GrPipeline.h
index 0f8eaa9..4ef08e1 100644
--- a/src/gpu/GrPipeline.h
+++ b/src/gpu/GrPipeline.h
@@ -32,7 +32,7 @@
 /**
  * This immutable object contains information needed to set build a shader program and set API
  * state for a draw. It is used along with a GrPrimitiveProcessor and a source of geometric
- * data (GrMesh or GrPath) to draw.
+ * data to draw.
  */
 class GrPipeline {
 public:
@@ -92,7 +92,7 @@
 
     /**
      * Any non-null array overrides the FixedDynamicState on a mesh-by-mesh basis. Arrays must
-     * have one entry for each GrMesh.
+     * have one entry for each GrSimpleMesh.
      */
     struct DynamicStateArrays {
         const SkIRect* fScissorRects = nullptr;
diff --git a/src/gpu/GrProgramInfo.cpp b/src/gpu/GrProgramInfo.cpp
index a63e614..a33254e 100644
--- a/src/gpu/GrProgramInfo.cpp
+++ b/src/gpu/GrProgramInfo.cpp
@@ -22,7 +22,6 @@
 }
 
 #ifdef SK_DEBUG
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrTexturePriv.h"
 
 void GrProgramInfo::validate(bool flushTime) const {
diff --git a/src/gpu/GrProgramInfo.h b/src/gpu/GrProgramInfo.h
index 5127a49..6fde1a8 100644
--- a/src/gpu/GrProgramInfo.h
+++ b/src/gpu/GrProgramInfo.h
@@ -12,7 +12,6 @@
 #include "src/gpu/GrPipeline.h"
 #include "src/gpu/GrPrimitiveProcessor.h"
 
-class GrMesh;
 class GrStencilSettings;
 
 class GrProgramInfo {
diff --git a/src/gpu/GrMesh.h b/src/gpu/GrSimpleMesh.h
similarity index 74%
rename from src/gpu/GrMesh.h
rename to src/gpu/GrSimpleMesh.h
index 5104ec9..8be1c47 100644
--- a/src/gpu/GrMesh.h
+++ b/src/gpu/GrSimpleMesh.h
@@ -5,8 +5,8 @@
  * found in the LICENSE file.
  */
 
-#ifndef GrMesh_DEFINED
-#define GrMesh_DEFINED
+#ifndef GrSimpleMesh_DEFINED
+#define GrSimpleMesh_DEFINED
 
 #include "src/gpu/GrBuffer.h"
 #include "src/gpu/GrGpuBuffer.h"
@@ -15,12 +15,10 @@
 class GrPrimitiveProcessor;
 
 /**
- * Used to communicate index and vertex buffers, counts, and offsets for a draw from GrOp to
- * GrGpu. It also holds the primitive type for the draw. TODO: Consider moving ownership of this
- * and draw-issuing responsibility to GrPrimitiveProcessor. The rest of the vertex info lives there
- * already (stride, attribute mappings).
+ * Used to communicate simple (non-instanced, direct) draws from GrOp to GrOpsRenderPass.
+ * TODO: Consider migrating every Op to make the appropriate draw directly on GrOpsRenderPass.
  */
-class GrMesh {
+class GrSimpleMesh {
 public:
     const GrBuffer* indexBuffer() const { return fIndexBuffer.get(); }
     const GrBuffer* vertexBuffer() const { return fVertexBuffer.get(); }
@@ -53,7 +51,7 @@
     SkDEBUGCODE(bool fIsInitialized = false;)
 };
 
-inline void GrMesh::set(sk_sp<const GrBuffer> vertexBuffer, int vertexCount, int baseVertex) {
+inline void GrSimpleMesh::set(sk_sp<const GrBuffer> vertexBuffer, int vertexCount, int baseVertex) {
     SkASSERT(baseVertex >= 0);
     fIndexBuffer.reset();
     fVertexBuffer = std::move(vertexBuffer);
@@ -62,10 +60,10 @@
     SkDEBUGCODE(fIsInitialized = true;)
 }
 
-inline void GrMesh::setIndexed(sk_sp<const GrBuffer> indexBuffer, int indexCount, int baseIndex,
-                               uint16_t minIndexValue, uint16_t maxIndexValue,
-                               GrPrimitiveRestart primitiveRestart,
-                               sk_sp<const GrBuffer> vertexBuffer, int baseVertex) {
+inline void GrSimpleMesh::setIndexed(sk_sp<const GrBuffer> indexBuffer, int indexCount,
+                                     int baseIndex, uint16_t minIndexValue, uint16_t maxIndexValue,
+                                     GrPrimitiveRestart primitiveRestart,
+                                     sk_sp<const GrBuffer> vertexBuffer, int baseVertex) {
     SkASSERT(indexBuffer);
     SkASSERT(indexCount >= 1);
     SkASSERT(baseIndex >= 0);
@@ -83,11 +81,10 @@
     SkDEBUGCODE(fIsInitialized = true;)
 }
 
-inline void GrMesh::setIndexedPatterned(sk_sp<const GrBuffer> indexBuffer, int indexCount,
-                                        int patternRepeatCount,
-                                        int maxPatternRepetitionsInIndexBuffer,
-                                        sk_sp<const GrBuffer> vertexBuffer,
-                                        int patternVertexCount, int baseVertex) {
+inline void GrSimpleMesh::setIndexedPatterned(
+        sk_sp<const GrBuffer> indexBuffer, int indexCount, int patternRepeatCount,
+        int maxPatternRepetitionsInIndexBuffer, sk_sp<const GrBuffer> vertexBuffer,
+        int patternVertexCount, int baseVertex) {
     SkASSERT(indexBuffer);
     SkASSERT(indexCount >= 1);
     SkASSERT(patternVertexCount >= 1);
@@ -105,7 +102,7 @@
     SkDEBUGCODE(fIsInitialized = true;)
 }
 
-inline void GrMesh::draw(GrOpsRenderPass* opsRenderPass) const {
+inline void GrSimpleMesh::draw(GrOpsRenderPass* opsRenderPass) const {
     SkASSERT(fIsInitialized);
 
     if (!fIndexBuffer) {
diff --git a/src/gpu/d3d/GrD3DOpsRenderPass.h b/src/gpu/d3d/GrD3DOpsRenderPass.h
index c25bce2..65e745d 100644
--- a/src/gpu/d3d/GrD3DOpsRenderPass.h
+++ b/src/gpu/d3d/GrD3DOpsRenderPass.h
@@ -12,7 +12,6 @@
 
 #include "include/gpu/GrTypes.h"
 #include "include/private/GrTypesPriv.h"
-#include "src/gpu/GrMesh.h"
 
 class GrD3DGpu;
 
diff --git a/src/gpu/dawn/GrDawnGpu.cpp b/src/gpu/dawn/GrDawnGpu.cpp
index 907b719..b212d42 100644
--- a/src/gpu/dawn/GrDawnGpu.cpp
+++ b/src/gpu/dawn/GrDawnGpu.cpp
@@ -12,7 +12,6 @@
 #include "include/gpu/GrContextOptions.h"
 #include "src/gpu/GrGeometryProcessor.h"
 #include "src/gpu/GrGpuResourceCacheAccess.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrPipeline.h"
 #include "src/gpu/GrRenderTargetPriv.h"
 #include "src/gpu/GrSemaphore.h"
diff --git a/src/gpu/dawn/GrDawnOpsRenderPass.cpp b/src/gpu/dawn/GrDawnOpsRenderPass.cpp
index f8dbb9a..0b60a07 100644
--- a/src/gpu/dawn/GrDawnOpsRenderPass.cpp
+++ b/src/gpu/dawn/GrDawnOpsRenderPass.cpp
@@ -8,7 +8,6 @@
 #include "src/gpu/dawn/GrDawnOpsRenderPass.h"
 
 #include "src/gpu/GrFixedClip.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrOpFlushState.h"
 #include "src/gpu/GrPipeline.h"
 #include "src/gpu/GrRenderTargetPriv.h"
diff --git a/src/gpu/dawn/GrDawnOpsRenderPass.h b/src/gpu/dawn/GrDawnOpsRenderPass.h
index e473edd..60b3b93 100644
--- a/src/gpu/dawn/GrDawnOpsRenderPass.h
+++ b/src/gpu/dawn/GrDawnOpsRenderPass.h
@@ -12,7 +12,6 @@
 
 #include "include/gpu/GrTypes.h"
 #include "src/gpu/GrColor.h"
-#include "src/gpu/GrMesh.h"
 #include "dawn/webgpu_cpp.h"
 
 class GrDawnGpu;
diff --git a/src/gpu/gl/GrGLGpu.cpp b/src/gpu/gl/GrGLGpu.cpp
index 92820b7..f3c8dc8 100644
--- a/src/gpu/gl/GrGLGpu.cpp
+++ b/src/gpu/gl/GrGLGpu.cpp
@@ -24,7 +24,6 @@
 #include "src/gpu/GrDataUtils.h"
 #include "src/gpu/GrFixedClip.h"
 #include "src/gpu/GrGpuResourcePriv.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrPipeline.h"
 #include "src/gpu/GrProgramInfo.h"
 #include "src/gpu/GrRenderTargetPriv.h"
diff --git a/src/gpu/gl/GrGLGpu.h b/src/gpu/gl/GrGLGpu.h
index fef400e..33fc73a 100644
--- a/src/gpu/gl/GrGLGpu.h
+++ b/src/gpu/gl/GrGLGpu.h
@@ -13,7 +13,6 @@
 #include "include/private/SkTArray.h"
 #include "src/core/SkLRUCache.h"
 #include "src/gpu/GrGpu.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrNativeRect.h"
 #include "src/gpu/GrProgramDesc.h"
 #include "src/gpu/GrWindowRectsState.h"
@@ -398,9 +397,9 @@
     int numTextureUnits() const { return this->caps()->shaderCaps()->maxFragmentSamplers(); }
 
     // Binds a texture to a target on the "scratch" texture unit to use for texture operations
-    // other than usual draw flow (i.e. a GrGLProgram derived from a GrPipeline used to draw
-    // GrMesh). It ensures that such operations don't negatively interact with draws.
-    // The active texture unit and the binding for 'target' will change.
+    // other than usual draw flow (i.e. a GrGLProgram derived from a GrPipeline used to draw). It
+    // ensures that such operations don't negatively interact with draws. The active texture unit
+    // and the binding for 'target' will change.
     void bindTextureToScratchUnit(GrGLenum target, GrGLint textureID);
 
     // The passed bounds contains the render target's color values that will subsequently be
diff --git a/src/gpu/mtl/GrMtlOpsRenderPass.h b/src/gpu/mtl/GrMtlOpsRenderPass.h
index 8bd4c28..ef8700a 100644
--- a/src/gpu/mtl/GrMtlOpsRenderPass.h
+++ b/src/gpu/mtl/GrMtlOpsRenderPass.h
@@ -8,7 +8,6 @@
 #ifndef GrMtlOpsRenderPass_DEFINED
 #define GrMtlOpsRenderPass_DEFINED
 
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrOpFlushState.h"
 #include "src/gpu/GrOpsRenderPass.h"
 #include "src/gpu/mtl/GrMtlGpu.h"
diff --git a/src/gpu/ops/GrAAConvexPathRenderer.cpp b/src/gpu/ops/GrAAConvexPathRenderer.cpp
index 76724ff..d1feaca 100644
--- a/src/gpu/ops/GrAAConvexPathRenderer.cpp
+++ b/src/gpu/ops/GrAAConvexPathRenderer.cpp
@@ -833,7 +833,7 @@
             GrVertexColor color(args.fColor, fWideColor);
             create_vertices(segments, fanPt, color, &draws, verts, idxs, kVertexStride);
 
-            GrMesh* meshes = target->allocMeshes(draws.count());
+            GrSimpleMesh* meshes = target->allocMeshes(draws.count());
             for (int j = 0; j < draws.count(); ++j) {
                 const Draw& draw = draws[j];
                 meshes[j].setIndexed(indexBuffer, draw.fIndexCnt, firstIndex, 0,
@@ -886,8 +886,8 @@
     bool fWideColor;
 
     struct MeshDraw {
-        GrMesh* fMeshes;
-        int     fMeshCount;
+        GrSimpleMesh* fMeshes;
+        int fMeshCount;
     };
 
     SkTDArray<MeshDraw> fDraws;
diff --git a/src/gpu/ops/GrAAHairLinePathRenderer.cpp b/src/gpu/ops/GrAAHairLinePathRenderer.cpp
index 7e98529..620e0b4 100644
--- a/src/gpu/ops/GrAAHairLinePathRenderer.cpp
+++ b/src/gpu/ops/GrAAHairLinePathRenderer.cpp
@@ -1105,7 +1105,7 @@
                                                            geometryProcessorViewM,
                                                            geometryProcessorLocalM);
 
-            GrMesh* mesh = target->allocMesh();
+            GrSimpleMesh* mesh = target->allocMesh();
             mesh->setIndexedPatterned(quadsIndexBuffer, kIdxsPerQuad, quadCount,
                                       kQuadsNumInIdxBuffer, vertexBuffer, kQuadNumVertices,
                                       firstVertex);
@@ -1118,7 +1118,7 @@
                                                              geometryProcessorViewM,
                                                              geometryProcessorLocalM);
 
-            GrMesh* mesh = target->allocMesh();
+            GrSimpleMesh* mesh = target->allocMesh();
             mesh->setIndexedPatterned(std::move(quadsIndexBuffer), kIdxsPerQuad, conicCount,
                                       kQuadsNumInIdxBuffer, std::move(vertexBuffer),
                                       kQuadNumVertices, firstVertex);
diff --git a/src/gpu/ops/GrAALinearizingConvexPathRenderer.cpp b/src/gpu/ops/GrAALinearizingConvexPathRenderer.cpp
index 2581fc7b..adeefce 100644
--- a/src/gpu/ops/GrAALinearizingConvexPathRenderer.cpp
+++ b/src/gpu/ops/GrAALinearizingConvexPathRenderer.cpp
@@ -249,7 +249,7 @@
             return;
         }
         memcpy(idxs, indices, indexCount * sizeof(uint16_t));
-        GrMesh* mesh = target->allocMesh();
+        GrSimpleMesh* mesh = target->allocMesh();
         mesh->setIndexed(std::move(indexBuffer), indexCount, firstIndex, 0, vertexCount - 1,
                          GrPrimitiveRestart::kNo, std::move(vertexBuffer), firstVertex);
         fMeshes.push_back(mesh);
@@ -361,8 +361,8 @@
     Helper fHelper;
     bool fWideColor;
 
-    SkTDArray<GrMesh*> fMeshes;
-    GrProgramInfo*     fProgramInfo = nullptr;
+    SkTDArray<GrSimpleMesh*> fMeshes;
+    GrProgramInfo*           fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
 };
diff --git a/src/gpu/ops/GrAtlasTextOp.cpp b/src/gpu/ops/GrAtlasTextOp.cpp
index b40bd0d..ae57bf7 100644
--- a/src/gpu/ops/GrAtlasTextOp.cpp
+++ b/src/gpu/ops/GrAtlasTextOp.cpp
@@ -511,7 +511,7 @@
         }
     }
     int maxGlyphsPerDraw = static_cast<int>(flushInfo->fIndexBuffer->size() / sizeof(uint16_t) / 6);
-    GrMesh* mesh = target->allocMesh();
+    GrSimpleMesh* mesh = target->allocMesh();
     mesh->setIndexedPatterned(flushInfo->fIndexBuffer, kIndicesPerGlyph, flushInfo->fGlyphsToFlush,
                               maxGlyphsPerDraw, flushInfo->fVertexBuffer, kVerticesPerGlyph,
                               flushInfo->fVertexOffset);
diff --git a/src/gpu/ops/GrDashOp.cpp b/src/gpu/ops/GrDashOp.cpp
index f7fc1b3..f43af78 100644
--- a/src/gpu/ops/GrDashOp.cpp
+++ b/src/gpu/ops/GrDashOp.cpp
@@ -721,7 +721,7 @@
     GrProcessorSet fProcessorSet;
     const GrUserStencilSettings* fStencilSettings;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/src/gpu/ops/GrDefaultPathRenderer.cpp b/src/gpu/ops/GrDefaultPathRenderer.cpp
index 0b676c2..60606eb 100644
--- a/src/gpu/ops/GrDefaultPathRenderer.cpp
+++ b/src/gpu/ops/GrDefaultPathRenderer.cpp
@@ -17,10 +17,10 @@
 #include "src/gpu/GrDefaultGeoProcFactory.h"
 #include "src/gpu/GrDrawOpTest.h"
 #include "src/gpu/GrFixedClip.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrOpFlushState.h"
 #include "src/gpu/GrProgramInfo.h"
 #include "src/gpu/GrRenderTargetContextPriv.h"
+#include "src/gpu/GrSimpleMesh.h"
 #include "src/gpu/GrStyle.h"
 #include "src/gpu/GrSurfaceContextPriv.h"
 #include "src/gpu/geometry/GrPathUtils.h"
@@ -69,7 +69,7 @@
 public:
     PathGeoBuilder(GrPrimitiveType primitiveType,
                    GrMeshDrawOp::Target* target,
-                   SkTDArray<GrMesh*>* meshes)
+                   SkTDArray<GrSimpleMesh*>* meshes)
             : fPrimitiveType(primitiveType)
             , fTarget(target)
             , fVertexStride(sizeof(SkPoint))
@@ -270,7 +270,7 @@
         SkASSERT(vertexCount <= fVerticesInChunk);
         SkASSERT(indexCount <= fIndicesInChunk);
 
-        GrMesh* mesh = nullptr;
+        GrSimpleMesh* mesh = nullptr;
         if (this->isIndexed() ? SkToBool(indexCount) : SkToBool(vertexCount)) {
             mesh = fTarget->allocMesh();
             if (!this->isIndexed()) {
@@ -333,7 +333,7 @@
     uint16_t* fCurIdx;
     uint16_t fSubpathIndexStart;
 
-    SkTDArray<GrMesh*>* fMeshes;
+    SkTDArray<GrSimpleMesh*>* fMeshes;
 };
 
 class DefaultPathOp final : public GrMeshDrawOp {
@@ -524,8 +524,8 @@
     SkMatrix fViewMatrix;
     bool fIsHairline;
 
-    SkTDArray<GrMesh*> fMeshes;
-    GrProgramInfo*     fProgramInfo = nullptr;
+    SkTDArray<GrSimpleMesh*> fMeshes;
+    GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
 };
diff --git a/src/gpu/ops/GrDrawAtlasOp.cpp b/src/gpu/ops/GrDrawAtlasOp.cpp
index 7e17115..5ceabe0 100644
--- a/src/gpu/ops/GrDrawAtlasOp.cpp
+++ b/src/gpu/ops/GrDrawAtlasOp.cpp
@@ -83,7 +83,7 @@
     int fQuadCount;
     bool fHasColors;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh* fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/src/gpu/ops/GrDrawVerticesOp.cpp b/src/gpu/ops/GrDrawVerticesOp.cpp
index 6adae7b..5bad9f8 100644
--- a/src/gpu/ops/GrDrawVerticesOp.cpp
+++ b/src/gpu/ops/GrDrawVerticesOp.cpp
@@ -149,7 +149,7 @@
     ColorArrayType fColorArrayType;
     sk_sp<GrColorSpaceXform> fColorSpaceXform;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/src/gpu/ops/GrFillRectOp.cpp b/src/gpu/ops/GrFillRectOp.cpp
index e1b5fba..255bd0d 100644
--- a/src/gpu/ops/GrFillRectOp.cpp
+++ b/src/gpu/ops/GrFillRectOp.cpp
@@ -450,7 +450,7 @@
     GrQuadBuffer<ColorAndAA> fQuads;
     char* fPrePreparedVertices = nullptr;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
     ColorType      fColorType;
 
diff --git a/src/gpu/ops/GrLatticeOp.cpp b/src/gpu/ops/GrLatticeOp.cpp
index 9b90934..0e2972a 100644
--- a/src/gpu/ops/GrLatticeOp.cpp
+++ b/src/gpu/ops/GrLatticeOp.cpp
@@ -365,7 +365,7 @@
     GrSamplerState::Filter fFilter;
     bool fWideColor;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/src/gpu/ops/GrMeshDrawOp.h b/src/gpu/ops/GrMeshDrawOp.h
index 5a8e65e..0a2fbee 100644
--- a/src/gpu/ops/GrMeshDrawOp.h
+++ b/src/gpu/ops/GrMeshDrawOp.h
@@ -11,7 +11,7 @@
 #include "src/core/SkArenaAlloc.h"
 #include "src/gpu/GrAppliedClip.h"
 #include "src/gpu/GrGeometryProcessor.h"
-#include "src/gpu/GrMesh.h"
+#include "src/gpu/GrSimpleMesh.h"
 #include "src/gpu/ops/GrDrawOp.h"
 #include <type_traits>
 
@@ -60,7 +60,7 @@
                         const GrPipeline::FixedDynamicState*) const;
 
         void* vertices() const { return fVertices; }
-        GrMesh* mesh() { return fMesh; }
+        GrSimpleMesh* mesh() { return fMesh; }
 
     protected:
         PatternHelper() = default;
@@ -70,7 +70,7 @@
 
     private:
         void* fVertices = nullptr;
-        GrMesh* fMesh = nullptr;
+        GrSimpleMesh* fMesh = nullptr;
         GrPrimitiveType fPrimitiveType;
     };
 
@@ -132,18 +132,18 @@
 
     /** Adds a draw of a mesh. */
     virtual void recordDraw(const GrGeometryProcessor*,
-                            const GrMesh[],
+                            const GrSimpleMesh[],
                             int meshCnt,
                             const GrPipeline::FixedDynamicState*,
                             const GrPipeline::DynamicStateArrays*,
                             GrPrimitiveType) = 0;
 
     /**
-     * Helper for drawing GrMesh(es) with zero primProc textures and no dynamic state besides the
-     * scissor clip.
+     * Helper for drawing GrSimpleMesh(es) with zero primProc textures and no dynamic state besides
+     * the scissor clip.
      */
     void recordDraw(const GrGeometryProcessor* gp,
-                    const GrMesh meshes[],
+                    const GrSimpleMesh meshes[],
                     int meshCnt,
                     GrPrimitiveType primitiveType) {
         static constexpr int kZeroPrimProcTextures = 0;
@@ -190,8 +190,8 @@
     virtual void putBackIndices(int indices) = 0;
     virtual void putBackVertices(int vertices, size_t vertexStride) = 0;
 
-    GrMesh* allocMesh() { return this->allocator()->make<GrMesh>(); }
-    GrMesh* allocMeshes(int n) { return this->allocator()->makeArray<GrMesh>(n); }
+    GrSimpleMesh* allocMesh() { return this->allocator()->make<GrSimpleMesh>(); }
+    GrSimpleMesh* allocMeshes(int n) { return this->allocator()->makeArray<GrSimpleMesh>(n); }
 
     static GrPipeline::DynamicStateArrays* AllocDynamicStateArrays(SkArenaAlloc*,
                                                                    int numMeshes,
diff --git a/src/gpu/ops/GrOvalOpFactory.cpp b/src/gpu/ops/GrOvalOpFactory.cpp
index 1fb885b..a43d222 100644
--- a/src/gpu/ops/GrOvalOpFactory.cpp
+++ b/src/gpu/ops/GrOvalOpFactory.cpp
@@ -1490,7 +1490,7 @@
     bool fRoundCaps;
     bool fWideColor;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
@@ -1798,7 +1798,7 @@
     int fIndexCount;
     bool fWideColor;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
@@ -2080,7 +2080,7 @@
     bool fUseScale;
     SkSTArray<1, Ellipse, true> fEllipses;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
@@ -2348,7 +2348,7 @@
     bool fUseScale;
     SkSTArray<1, Ellipse, true> fEllipses;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
@@ -2808,7 +2808,7 @@
     bool fWideColor;
     SkSTArray<1, RRect, true> fRRects;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
@@ -3117,7 +3117,7 @@
     bool fUseScale;
     SkSTArray<1, RRect, true> fRRects;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/src/gpu/ops/GrQuadPerEdgeAA.cpp b/src/gpu/ops/GrQuadPerEdgeAA.cpp
index 42162f8..c0141ae 100644
--- a/src/gpu/ops/GrQuadPerEdgeAA.cpp
+++ b/src/gpu/ops/GrQuadPerEdgeAA.cpp
@@ -392,7 +392,7 @@
     SkUNREACHABLE;
 }
 
-void ConfigureMesh(const GrCaps& caps, GrMesh* mesh, const VertexSpec& spec,
+void ConfigureMesh(const GrCaps& caps, GrSimpleMesh* mesh, const VertexSpec& spec,
                    int runningQuadCount, int quadsInDraw, int maxVerts,
                    sk_sp<const GrBuffer> vertexBuffer,
                    sk_sp<const GrBuffer> indexBuffer, int absVertBufferOffset) {
diff --git a/src/gpu/ops/GrQuadPerEdgeAA.h b/src/gpu/ops/GrQuadPerEdgeAA.h
index 3a04bc3..174fa69 100644
--- a/src/gpu/ops/GrQuadPerEdgeAA.h
+++ b/src/gpu/ops/GrQuadPerEdgeAA.h
@@ -192,7 +192,7 @@
     // @param quadCount         the number of quads that will be drawn by the provided 'mesh'.
     //                          A subsequent ConfigureMesh call would the use
     //                          'runningQuadCount' + 'quadCount' for its new 'runningQuadCount'.
-    void ConfigureMesh(const GrCaps&, GrMesh*, const VertexSpec&, int runningQuadCount,
+    void ConfigureMesh(const GrCaps&, GrSimpleMesh*, const VertexSpec&, int runningQuadCount,
                        int quadCount, int maxVerts, sk_sp<const GrBuffer> vertexBuffer,
                        sk_sp<const GrBuffer> indexBuffer, int absVertBufferOffset);
 
diff --git a/src/gpu/ops/GrRegionOp.cpp b/src/gpu/ops/GrRegionOp.cpp
index 4a097a5..7af7579 100644
--- a/src/gpu/ops/GrRegionOp.cpp
+++ b/src/gpu/ops/GrRegionOp.cpp
@@ -190,7 +190,7 @@
     SkSTArray<1, RegionInfo, true> fRegions;
     bool fWideColor;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/src/gpu/ops/GrShadowRRectOp.cpp b/src/gpu/ops/GrShadowRRectOp.cpp
index 119addd..e099e8e 100644
--- a/src/gpu/ops/GrShadowRRectOp.cpp
+++ b/src/gpu/ops/GrShadowRRectOp.cpp
@@ -654,7 +654,7 @@
     int fIndexCount;
     GrSurfaceProxyView fFalloffView;
 
-    GrMesh*            fMesh = nullptr;
+    GrSimpleMesh*      fMesh = nullptr;
     GrProgramInfo*     fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/src/gpu/ops/GrSmallPathRenderer.cpp b/src/gpu/ops/GrSmallPathRenderer.cpp
index d3d4df6..f13757d 100644
--- a/src/gpu/ops/GrSmallPathRenderer.cpp
+++ b/src/gpu/ops/GrSmallPathRenderer.cpp
@@ -817,7 +817,7 @@
         }
 
         if (flushInfo->fInstancesToFlush) {
-            GrMesh* mesh = target->allocMesh();
+            GrSimpleMesh* mesh = target->allocMesh();
             mesh->setIndexedPatterned(flushInfo->fIndexBuffer,
                                       GrResourceProvider::NumIndicesPerNonAAQuad(),
                                       flushInfo->fInstancesToFlush,
diff --git a/src/gpu/ops/GrStrokeRectOp.cpp b/src/gpu/ops/GrStrokeRectOp.cpp
index 7bb9d29..c9757bb 100644
--- a/src/gpu/ops/GrStrokeRectOp.cpp
+++ b/src/gpu/ops/GrStrokeRectOp.cpp
@@ -261,7 +261,7 @@
     SkMatrix       fViewMatrix;
     SkRect         fRect;
     SkScalar       fStrokeWidth;
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     const static int kVertsPerHairlineRect = 5;
@@ -507,7 +507,7 @@
     Helper         fHelper;
     SkSTArray<1, RectInfo, true> fRects;
     SkMatrix       fViewMatrix;
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
     bool           fMiterStroke;
     bool           fWideColor;
diff --git a/src/gpu/ops/GrTessellatingPathRenderer.cpp b/src/gpu/ops/GrTessellatingPathRenderer.cpp
index a39cb00..c84910e 100644
--- a/src/gpu/ops/GrTessellatingPathRenderer.cpp
+++ b/src/gpu/ops/GrTessellatingPathRenderer.cpp
@@ -15,11 +15,11 @@
 #include "src/gpu/GrDefaultGeoProcFactory.h"
 #include "src/gpu/GrDrawOpTest.h"
 #include "src/gpu/GrEagerVertexAllocator.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrOpFlushState.h"
 #include "src/gpu/GrProgramInfo.h"
 #include "src/gpu/GrResourceCache.h"
 #include "src/gpu/GrResourceProvider.h"
+#include "src/gpu/GrSimpleMesh.h"
 #include "src/gpu/GrStyle.h"
 #include "src/gpu/GrTessellator.h"
 #include "src/gpu/geometry/GrPathUtils.h"
@@ -405,7 +405,7 @@
     SkIRect        fDevClipBounds;
     bool           fAntiAlias;
 
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/src/gpu/ops/GrTextureOp.cpp b/src/gpu/ops/GrTextureOp.cpp
index 672e6ea..1ab4dbd 100644
--- a/src/gpu/ops/GrTextureOp.cpp
+++ b/src/gpu/ops/GrTextureOp.cpp
@@ -682,7 +682,7 @@
     }
 
     static bool FillInData(const GrCaps& caps, TextureOp* texOp, PrePreparedDesc* desc,
-                           char* pVertexData, GrMesh* meshes, int absBufferOffset,
+                           char* pVertexData, GrSimpleMesh* meshes, int absBufferOffset,
                            sk_sp<const GrBuffer> vertexBuffer,
                            sk_sp<const GrBuffer> indexBuffer) {
         int totQuadsSeen = 0;
@@ -898,7 +898,7 @@
         }
 
         // Note: this allocation is always in the flush-time arena (i.e., the flushState)
-        GrMesh* meshes = target->allocMeshes(desc.fNumProxies);
+        GrSimpleMesh* meshes = target->allocMeshes(desc.fNumProxies);
 
         bool result;
         if (fPrePreparedDesc) {
diff --git a/src/gpu/vk/GrVkGpu.cpp b/src/gpu/vk/GrVkGpu.cpp
index 03f1505..c978589 100644
--- a/src/gpu/vk/GrVkGpu.cpp
+++ b/src/gpu/vk/GrVkGpu.cpp
@@ -18,7 +18,6 @@
 #include "src/gpu/GrDataUtils.h"
 #include "src/gpu/GrGeometryProcessor.h"
 #include "src/gpu/GrGpuResourceCacheAccess.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrNativeRect.h"
 #include "src/gpu/GrPipeline.h"
 #include "src/gpu/GrRenderTargetContext.h"
diff --git a/src/gpu/vk/GrVkOpsRenderPass.cpp b/src/gpu/vk/GrVkOpsRenderPass.cpp
index e078c30..a315f13 100644
--- a/src/gpu/vk/GrVkOpsRenderPass.cpp
+++ b/src/gpu/vk/GrVkOpsRenderPass.cpp
@@ -12,7 +12,6 @@
 #include "include/gpu/GrBackendDrawableInfo.h"
 #include "src/gpu/GrContextPriv.h"
 #include "src/gpu/GrFixedClip.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrOpFlushState.h"
 #include "src/gpu/GrPipeline.h"
 #include "src/gpu/GrRenderTargetPriv.h"
diff --git a/src/gpu/vk/GrVkOpsRenderPass.h b/src/gpu/vk/GrVkOpsRenderPass.h
index e5d37e2..ffdd4b1 100644
--- a/src/gpu/vk/GrVkOpsRenderPass.h
+++ b/src/gpu/vk/GrVkOpsRenderPass.h
@@ -13,7 +13,6 @@
 #include "include/gpu/GrTypes.h"
 #include "include/gpu/vk/GrVkTypes.h"
 #include "src/gpu/GrColor.h"
-#include "src/gpu/GrMesh.h"
 #include "src/gpu/GrTRecorder.h"
 #include "src/gpu/vk/GrVkPipelineState.h"
 
diff --git a/src/gpu/vk/GrVkUniformHandler.h b/src/gpu/vk/GrVkUniformHandler.h
index 7d39c2f..ac217ea 100644
--- a/src/gpu/vk/GrVkUniformHandler.h
+++ b/src/gpu/vk/GrVkUniformHandler.h
@@ -23,7 +23,7 @@
         /**
          * Binding a descriptor set invalidates all higher index descriptor sets. We must bind
          * in the order of this enumeration. Samplers are after Uniforms because GrOps can specify
-         * GP textures as dynamic state, meaning they get rebound for each GrMesh in a draw while
+         * GP textures as dynamic state, meaning they get rebound for each draw in a pipeline while
          * uniforms are bound once before all the draws.
          */
         kUniformBufferDescSet = 0,
diff --git a/tests/GrMeshTest.cpp b/tests/GrMeshTest.cpp
index 7aa5790..59499fd 100644
--- a/tests/GrMeshTest.cpp
+++ b/tests/GrMeshTest.cpp
@@ -79,10 +79,11 @@
 ////////////////////////////////////////////////////////////////////////////////////////////////////
 
 /**
- * This is a GPU-backend specific test. It tries to test all possible usecases of GrMesh. The test
- * works by drawing checkerboards of colored boxes, reading back the pixels, and comparing with
- * expected results. The boxes are drawn on integer boundaries and the (opaque) colors are chosen
- * from the set (r,g,b) = (0,255)^3, so the GPU renderings ought to produce exact matches.
+ * This is a GPU-backend specific test. It tries to test all possible usecases of
+ * GrOpsRenderPass::draw*. The test works by drawing checkerboards of colored boxes, reading back
+ * the pixels, and comparing with expected results. The boxes are drawn on integer boundaries and
+ * the (opaque) colors are chosen from the set (r,g,b) = (0,255)^3, so the GPU renderings ought to
+ * produce exact matches.
  */
 
 static void run_test(GrContext* context, const char* testName, skiatest::Reporter*,
diff --git a/tests/GrPipelineDynamicStateTest.cpp b/tests/GrPipelineDynamicStateTest.cpp
index 6752847..4c7ffd6 100644
--- a/tests/GrPipelineDynamicStateTest.cpp
+++ b/tests/GrPipelineDynamicStateTest.cpp
@@ -149,9 +149,9 @@
     void onExecute(GrOpFlushState* flushState, const SkRect& chainBounds) override {
         GrPipeline pipeline(fScissorTest, SkBlendMode::kSrc,
                             flushState->drawOpArgs().outputSwizzle());
-        SkSTArray<kNumMeshes, GrMesh> meshes;
+        SkSTArray<kNumMeshes, GrSimpleMesh> meshes;
         for (int i = 0; i < kNumMeshes; ++i) {
-            GrMesh& mesh = meshes.push_back();
+            GrSimpleMesh& mesh = meshes.push_back();
             mesh.set(fVertexBuffer, 4, 4 * i);
         }
         GrPipeline::DynamicStateArrays dynamicState;
diff --git a/tests/OnFlushCallbackTest.cpp b/tests/OnFlushCallbackTest.cpp
index 3be24da..9a3ef71 100644
--- a/tests/OnFlushCallbackTest.cpp
+++ b/tests/OnFlushCallbackTest.cpp
@@ -196,7 +196,7 @@
     }
 
     Helper         fHelper;
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/tests/PrimitiveProcessorTest.cpp b/tests/PrimitiveProcessorTest.cpp
index 3990385..476d19a 100644
--- a/tests/PrimitiveProcessorTest.cpp
+++ b/tests/PrimitiveProcessorTest.cpp
@@ -158,7 +158,7 @@
     }
 
     int            fNumAttribs;
-    GrMesh*        fMesh = nullptr;
+    GrSimpleMesh*  fMesh = nullptr;
     GrProgramInfo* fProgramInfo = nullptr;
 
     typedef GrMeshDrawOp INHERITED;
diff --git a/tools/gpu/TestOps.cpp b/tools/gpu/TestOps.cpp
index 9c926aa..291ee3e 100644
--- a/tools/gpu/TestOps.cpp
+++ b/tools/gpu/TestOps.cpp
@@ -121,7 +121,7 @@
     // If this op is prePrepared the created programInfo will be stored here for use in
     // onExecute. In the prePrepared case it will have been stored in the record-time arena.
     GrProgramInfo* fProgramInfo = nullptr;
-    GrMesh*        fMesh        = nullptr;
+    GrSimpleMesh*  fMesh        = nullptr;
 
     friend class ::GrOpMemoryPool;
 };