Sounds good.

On Sep 11, 2007, at 12:06 PM, Ethan Mallove wrote:

On Tue, Sep/11/2007 11:46:36AM, Ethan Mallove wrote:
On Tue, Sep/11/2007 10:50:35AM, Jeff Squyres wrote:
Ethan --

Could you show the use case that motivated this change?


This test_executable was problematic: "src/mpi2c++".

--Calling: $ret = MTT::Values::Functions::MPI::OMPI::find_network (MTT::Values::Functions::test_command_line(), MTT::Values::Functions::t
  est_executable());
&test_command_line returning: mpirun --mca btl self,sm,tcp -- host burl-ct-v40z-0,burl-ct-v40z-0,burl-ct-v40z-0,burl-ct- v40z-0,burl-ct-v40z -1,burl-ct-v40z-1,burl-ct-v40z-1,burl-ct-v40z-1 -np 8 --prefix / opt/SUNWhpc src/mpi2c++_test
  &test_executable returning: src/mpi2c++_test
&MPI::OMPI::find_network: got mpirun --mca btl self,sm,tcp -- host burl-ct-v40z-0,burl-ct-v40z-0,burl-ct-v40z-0,burl-ct- v40z-0,burl-ct-v40z -1,burl-ct-v40z-1,burl-ct-v40z-1,burl-ct-v40z-1 -np 8 --prefix / opt/SUNWhpc src/mpi2c++_test src/mpi2c++_test *** ERROR: Could not evaluate: $ret = MTT::Values::Functions::MPI::OMPI::find_network (MTT::Values::Functions::test_command_line(), MTT::Va lues::Functions::test_executable());: Nested quantifiers in regex; marked by <-- HERE in m/^(.+)\s*src/mpi2c++ <-- HERE _test.+ $/ at /worksp ace/em162155/hpc/mtt/cron/jms-new-parser/lib/MTT/Values/ Functions/MPI/OMPI.pm line 102.


Actually, maybe $final should get run through "quotemeta"
instead (http://perldoc.perl.org/functions/quotemeta.html).

-Ethan


-Ethan

Thanks.


On Sep 7, 2007, at 11:52 AM, emall...@osl.iu.edu wrote:

Author: emallove
Date: 2007-09-07 11:52:04 EDT (Fri, 07 Sep 2007)
New Revision: 998
URL: https://svn.open-mpi.org/trac/mtt/changeset/998

Log:
Escape the Perl regular expression quantifiers in
`&MPI::OMPI::find_network` (for test names such as
`mpic++`).

Text files modified:
tmp/jms-new-parser/lib/MTT/Values/Functions/MPI/OMPI.pm | 3 +++
   1 files changed, 3 insertions(+), 0 deletions(-)

Modified: tmp/jms-new-parser/lib/MTT/Values/Functions/MPI/OMPI.pm
=================================================================== ===
========
--- tmp/jms-new-parser/lib/MTT/Values/Functions/MPI/OMPI.pm (original)
+++ tmp/jms-new-parser/lib/MTT/Values/Functions/MPI/OMPI.pm     
2007-09-07 11:52:04 EDT (Fri, 07 Sep 2007)
@@ -98,6 +98,9 @@
     # Ignore argv[0]
     $str =~ s/^\s*\S+\s*(.+)$/\1/;

+    # Escape the quantifiers (for test names such as "mpi2c++")
+    $final =~ s/(\?|\*|\+|\{|\})/\\$1/g;
+
     # Ignore everything beyond $final
     $str =~ s/^(.+)\s*$final.+$/\1/;
     Debug("Examining: $str\n");
_______________________________________________
mtt-svn mailing list
mtt-...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/mtt-svn


--
Jeff Squyres
Cisco Systems

_______________________________________________
mtt-devel mailing list
mtt-de...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/mtt-devel
_______________________________________________
mtt-devel mailing list
mtt-de...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/mtt-devel
_______________________________________________
mtt-devel mailing list
mtt-de...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/mtt-devel


--
Jeff Squyres
Cisco Systems

Reply via email to