Commit 4df14dcb authored by Tomáš Oberhuber's avatar Tomáš Oberhuber Committed by Jakub Klinkovský
Browse files

Added method print to Segments for better use with output streams.

parent d5984f14
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -35,7 +35,7 @@ void SegmentsExample()
    * Print the data managed by the segments.
    */
   auto fetch = [=] __cuda_callable__ ( int globalIdx ) -> double { return data_view[ globalIdx ]; };
   printSegments( segments, fetch, std::cout );
   std::cout << segments.print( fetch ) << std::endl;
}

int main( int argc, char* argv[] )
+1 −1
Original line number Diff line number Diff line
@@ -34,7 +34,7 @@ void SegmentsExample()
    * Print the data managed by the segments.
    */
   auto fetch = [=] __cuda_callable__ ( int globalIdx ) -> double { return data_view[ globalIdx ]; };
   printSegments( segments, fetch, std::cout );
   std::cout << segments.print( fetch ) << std::endl;
}

int main( int argc, char* argv[] )
+1 −1
Original line number Diff line number Diff line
@@ -33,7 +33,7 @@ void SegmentsExample()
    * Print the data managed by the segments.
    */
   auto fetch = [=] __cuda_callable__ ( int globalIdx ) -> double { return data_view[ globalIdx ]; };
   printSegments( segments, fetch, std::cout );
   std::cout << segments.print( fetch ) << std::endl;
}

int main( int argc, char* argv[] )
+1 −1
Original line number Diff line number Diff line
@@ -36,7 +36,7 @@ void SegmentsExample()
    * Print the data managed by the segments.
    */
   auto fetch = [=] __cuda_callable__ ( int globalIdx ) -> double { return data_view[ globalIdx ]; };
   printSegments( segments, fetch, std::cout );
   std::cout << segments.print( fetch ) << std::endl;
}

int main( int argc, char* argv[] )
+1 −1
Original line number Diff line number Diff line
@@ -36,7 +36,7 @@ void SegmentsExample()
    * Print the data managed by the segments.
    */
   auto fetch = [=] __cuda_callable__ ( IndexType globalIdx ) -> double { return data_view[ globalIdx ]; };
   printSegments( segments, fetch, std::cout );
   std::cout << segments.print( fetch ) << std::endl;

   /***
    * Compute sums of elements in particular segments.
Loading