octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #64975] Octave for Windows extremely slow


From: Markus Mützel
Subject: [Octave-bug-tracker] [bug #64975] Octave for Windows extremely slow
Date: Fri, 8 Dec 2023 07:54:48 -0500 (EST)

Follow-up Comment #19, bug#64975 (group octave):

Thank you for the feedback. I'll try and update the patch.

Regarding the difference in pattern matching on Windows and on other
platforms: Implementing the '*' and '?' wildcards was possible in a couple of
lines. Implementing `[]` group and range matches from scratch (in a POSIX
compatible way) is probably more tricky. See the complexity and performance of
the implementation from gnulib. I was hoping we could avoid that complexity
and use something simple but fast (given that this function will apparently be
called thousands of times).

One option to have the same behavior on all platforms would be to use that
manual matching function everywhere (not just on Windows).
But it might be that the implementation of fnmatch on Linux is actually more
performant than the function that is added for Windows in this patch.
Alternatively: Is there a POSIX function that does efficient pattern matching
with only '*' and '?' wildcard characters (no '[]' groups or ranges)?

The glob_match class has a member function `glob`. That member function
doesn't make sense for the symbol_match class (imho).
I'm also unsure if we need the overloads for string_vector input or the second
(optional) input argument for the constructors. 
Other than that, I agree that it might be a good idea to keep the interfaces
of the two classes similar and to move them to the same files in liboctave.



    _______________________________________________________

Reply to this item at:

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

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]