swr: [rasterizer archrast] move to pass by value
authorTim Rowley <timothy.o.rowley@intel.com>
Wed, 9 Nov 2016 23:29:00 +0000 (17:29 -0600)
committerTim Rowley <timothy.o.rowley@intel.com>
Mon, 14 Nov 2016 15:03:04 +0000 (09:03 -0600)
Move to pass by value since most events are very small in size.

We can look at pass by reference but will need to create multiple
versions to handle temp objects.

Reviewed-by: Bruce Cherniak <bruce.cherniak@intel.com>
src/gallium/drivers/swr/rasterizer/scripts/templates/ar_eventhandler_h.template
src/gallium/drivers/swr/rasterizer/scripts/templates/ar_eventhandlerfile_h.template

index abde3c028bd9050c7ffa44d761c0d24278ff313e..dd4e2f5c19235654c91f101cfc4746f471df39ec 100644 (file)
@@ -43,7 +43,7 @@ namespace ArchRast
         virtual ~EventHandler() {}
 
 % for name in protos['event_names']:
-        virtual void Handle(${name}&& event) {}
+        virtual void Handle(${name} event) {}
 % endfor
     };
 }
index ada134d01c3ae6588338b0888a293963df0c1c40..87674bfc99839713f71ad07bafca6b142f686d65 100644 (file)
@@ -128,7 +128,7 @@ namespace ArchRast
 % for name in protos['event_names']:
         //////////////////////////////////////////////////////////////////////////
         /// @brief Handle ${name} event
-        virtual void Handle(${name}&& event)
+        virtual void Handle(${name} event)
         {
 % if protos['events'][name]['num_fields'] == 0:
             Write(${protos['events'][name]['event_id']}, (char*)&event.data, 0);