[bug #68174] dlmread performance can be improved with modern C++

"Dmitri A. Sergatskov" <[email protected]>
Newsgroups gmane.comp.gnu.octave.bugs
Message-ID <[email protected]>
Please use the bug tracker to post updates to a bug report.  The mailing list is intended as a read-only notification stream.  Info posted to this mailing list address won't appear in the tracker database where it is most useful.

Follow-up Comment #2, bug #68174 (group octave):

Found a bug. The old tmp_stream intrinsically ignored "\r", "\v", "\f" because
"operator>>" respects std::skipws (which in turn relies on std::isspace).
"std::from_chars does no do whitespace skipping at all.
  
In Octave, when the delimiter is set to whitespace, it strictly means spaces
and tabs (" \t"). If we mix the column separator logic with the token trimming
logic, a stray e.g. "\r" causes the parser to merge rows or incorrectly split
columns. 

Attached CSET (file bug68174_dlmread_fast_20260325_200.cset) has a fix for
that (and a BIST).

Dmitri.
-- 


(file #58398)

    _______________________________________________________

Additional Item Attachment:

Name: bug68174_dlmread_fast_20260325_200.cset Size: 14KiB

<https://file.savannah.gnu.org/file/bug68174_dlmread_fast_20260325_200.cset?file_id=58398>


    AGPL NOTICE

These attachments are served by Savane. You can download the corresponding
source code of Savane at
https://savannah.gnu.org/source/savane-9b684d621d606340ec3f8b1a290873daf3ff5474.tar.gz


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?68174>

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
signature.asc (application/pgp-signature, 228 B)
-----BEGIN PGP SIGNATURE-----

iHUEABYIAB0WIQQk97aszIMMAvLLwm6qLAuaBUf3TgUCacRHigAKCRCqLAuaBUf3
TibQAP9FjWbPTLfzwkSa/AAHzlsCWfTon79C5f5kOvrX7UcnAgEAsxrTsa43emYx
G7PqZoGYizFU4b0LNi3zRIa/vnubqAw=
=sxTP
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.