swr/rast: Add tracking for stream out topology
authorGeorge Kyriazis <george.kyriazis@intel.com>
Wed, 28 Feb 2018 23:33:13 +0000 (17:33 -0600)
committerGeorge Kyriazis <george.kyriazis@intel.com>
Fri, 9 Mar 2018 15:36:14 +0000 (09:36 -0600)
Reviewed-by: Bruce Cherniak <bruce.cherniak@intel.com>
src/gallium/drivers/swr/rasterizer/archrast/archrast.cpp
src/gallium/drivers/swr/rasterizer/archrast/events.proto
src/gallium/drivers/swr/rasterizer/archrast/events_private.proto
src/gallium/drivers/swr/rasterizer/core/api.cpp

index af18b161eaf0846ee4c4c3e93754c39f725338b4..1f87dbabcd0cdb5a82bc446c0602c03051c3d01b 100644 (file)
@@ -87,8 +87,8 @@ namespace ArchRast
         {
             DrawInfoEvent e(event.data.drawId, ArchRast::Instanced, event.data.topology, 
                 event.data.numVertices, 0, 0, event.data.startVertex, event.data.numInstances, 
-                event.data.startInstance, event.data.tsEnable, event.data.gsEnable, event.data.soEnable, event.data.splitId);
-
+                event.data.startInstance, event.data.tsEnable, event.data.gsEnable, event.data.soEnable, event.data.soTopology, event.data.splitId);
+            
             EventHandlerFile::Handle(e);
         }
 
@@ -96,7 +96,7 @@ namespace ArchRast
         {
             DrawInfoEvent e(event.data.drawId, ArchRast::IndexedInstanced, event.data.topology, 0,
                 event.data.numIndices, event.data.indexOffset, event.data.baseVertex, event.data.numInstances,
-                event.data.startInstance, event.data.tsEnable, event.data.gsEnable, event.data.soEnable, event.data.splitId);
+                event.data.startInstance, event.data.tsEnable, event.data.gsEnable, event.data.soEnable, event.data.soTopology, event.data.splitId);
 
             EventHandlerFile::Handle(e);
         }
index 45193a33fd30eda8da258cb1ac7fc80f5b6bfcef..7d9a68d502ea32c0c2f95a68f48758a2e8c75b91 100644 (file)
@@ -51,6 +51,7 @@ event DrawInfoEvent
     uint32_t tsEnable;
     uint32_t gsEnable;
     uint32_t soEnable;
+    uint32_t soTopology;
     uint32_t splitId; // Split draw count or id.
 };
 
index 760f7aa4957ecd77f5930df3914d20cf26b88327..f0a93107e5e0c9fdb11a6ee8b7086052e397b9ca 100644 (file)
@@ -131,6 +131,7 @@ event DrawInstancedEvent
     uint32_t tsEnable;
     uint32_t gsEnable;
     uint32_t soEnable;
+    uint32_t soTopology;
     uint32_t splitId; // Split draw count or id.
 };
 
@@ -146,5 +147,6 @@ event DrawIndexedInstancedEvent
     uint32_t tsEnable;
     uint32_t gsEnable;
     uint32_t soEnable;
+    uint32_t soTopology;
     uint32_t splitId; // Split draw count or id.
 };
index 86864f022aa295ff109239ec4212feda3db8000c..b2529598bd1acbddf5fa219c17e524b9836b9559 100644 (file)
@@ -1221,7 +1221,7 @@ void DrawInstanced(
         QueueDraw(pContext);
 
         AR_API_EVENT(DrawInstancedEvent(pDC->drawId, topology, numVertsForDraw, startVertex, numInstances,
-            startInstance, pState->tsState.tsEnable, pState->gsState.gsEnable, pState->soState.soEnable, draw));
+            startInstance, pState->tsState.tsEnable, pState->gsState.gsEnable, pState->soState.soEnable, pState->gsState.outputTopology, draw));
 
         remainingVerts -= numVertsForDraw;
         draw++;
@@ -1366,7 +1366,7 @@ void DrawIndexedInstance(
         QueueDraw(pContext);
 
         AR_API_EVENT(DrawIndexedInstancedEvent(pDC->drawId, topology, numIndicesForDraw, indexOffset, baseVertex,
-            numInstances, startInstance, pState->tsState.tsEnable, pState->gsState.gsEnable, pState->soState.soEnable, draw));
+            numInstances, startInstance, pState->tsState.tsEnable, pState->gsState.gsEnable, pState->soState.soEnable, pState->gsState.outputTopology, draw));
 
         pIB += maxIndicesPerDraw * indexSize;
         remainingIndices -= numIndicesForDraw;