diff libinterp/corefcn/oct-stream.h @ 17453:669ad11f282d

improve efficiency of fread * oct-stream.cc, oct-stream.h (octave_stream::finalize_read, convert_and_copy): New functions. (TABLE_ELT): New macro. (FILL_TABLE_ROW, conv_fptr): Update to new conversion function. (do_read): Delete function. (octave_stream::read): Read data in bigger chunks. Convert format once all data has been read.
author John W. Eaton <jwe@octave.org>
date Thu, 19 Sep 2013 11:20:28 -0400
parents 6690dba6078a
children d63878346099
line wrap: on
line diff
--- a/libinterp/corefcn/oct-stream.h	Fri Sep 20 17:36:43 2013 +0200
+++ b/libinterp/corefcn/oct-stream.h	Thu Sep 19 11:20:28 2013 -0400
@@ -31,6 +31,7 @@
 #include <iosfwd>
 #include <sstream>
 #include <string>
+#include <list>
 #include <map>
 
 #include "Array.h"
@@ -648,6 +649,15 @@
       if (rep)
         rep->invalid_operation (who, rw);
     }
+
+  octave_value
+  finalize_read (std::list<void *>& input_buf_list,
+                 octave_idx_type input_buf_elts,
+                 octave_idx_type elts_read,
+                 octave_idx_type nr, octave_idx_type nc,
+                 oct_data_conv::data_type input_type,
+                 oct_data_conv::data_type output_type,
+                 oct_mach_info::float_format ffmt);
 };
 
 class