Opened 13 years ago

Closed 12 years ago

#30627 closed defect (fixed)

octave-devel crashes on mismatched matrix dimensions

Reported by: jmrosenstock@… Owned by: michaelld (Michael Dickens)
Priority: Normal Milestone:
Component: ports Version: 2.0.1
Keywords: Cc:
Port: octave-devel

Description (last modified by mf2k (Frank Schima))

I reported this to octave: https://savannah.gnu.org/bugs/index.php?33943

They think something with catching exceptions isn't right with the macports configuration, perhaps related to exception handling.

"The xgemm function is part of Octave (liboctave/dMatrix.cc). When it detects a dimension mismatch, it calls gripe_nonconformant (liboctave/lo-array-gripes.cc). That function calls an error handler using the function pointer current_liboctave_error_with_id_handler. Normally, that is set to lo_error_with_id_handler (set in the function initialize_error_handlers in src/octave.cc). That function ultimately calls octave_throw_execution_exception (libcruft/misc/quit.cc) which ultimately throws a C++ exception which should be caught in the main_loop function (src/toplev.cc). I'd guess the abort is happening because the exception is not caught as it should be."

GNU Octave, version 3.4.2 
Octave was configured for "i386-apple-darwin9.8.0". 
octave:1> [ 1 2 ] * [ 1 2 3 ] 

Program received signal SIGABRT, Aborted. 
0x915b1d52 in __kill () 
(gdb) bt 
#0 0x915b1d52 in __kill () 
#1 0x915b1d44 in kill$UNIX2003 () 
#2 0x91624242 in raise () 
#3 0x91630681 in abort () 
#4 0x970c4a2a in _Unwind_Resume () 
#5 0x023636cd in xgemm () 
#6 0x02363760 in operator* () 
#7 0x017343be in oct_binop_mul () 
#8 0x0145676a in do_binary_op () 
#9 0x014f4832 in tree_binary_expression::rvalue1 () 
#10 0x011ffcce in fold () 
#11 0x012038dd in octave_parse () 
#12 0x012ea641 in main_loop () 
#13 0x0127b92e in octave_main () 
#14 0x00001ff0 in main () 

Change History (9)

comment:1 Changed 13 years ago by mf2k (Frank Schima)

Description: modified (diff)
Owner: changed from macports-tickets@… to michaelld@…

comment:2 Changed 13 years ago by michaelld (Michael Dickens)

Interesting. I have octave-devel installed, and it seems to work for me (see below). I think the main difference is that I'm using GCC 4.4 while you're using GCC 4.5. Can you try reinstalling using GCC 4.4?

bash% octave
GNU Octave, version 3.4.2
Copyright (C) 2011 John W. Eaton and others.
This is free software; see the source code for copying conditions.
There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.  For details, type `warranty'.

Octave was configured for "x86_64-apple-darwin10.7.0".

Additional information about Octave is available at http://www.octave.org.

Please contribute if you find this software useful.
For more information, visit http://www.octave.org/help-wanted.html

Read http://www.octave.org/bugs.html to learn how to submit bug reports.

For information about changes from previous versions, type `news'.

octave:1> [ 1 2 ] * [ 1 2 3 ]
error: operator *: nonconformant arguments (op1 is 1x2, op2 is 1x3)
octave:1>

comment:3 Changed 13 years ago by sebastian@…

No problem here using Lion and the following ports/versions

gcc45 @4.5.3_0 octave-devel @3.4.2_2+docs+fltk+gcc45+x11

comment:4 Changed 13 years ago by jmrosenstock@…

gcc 4.4 works. I uninstalled my 4.5 to make space, so I can't say what version it was exactly. I also tried with 4.6.1 and that failed. Perhaps the newer ones don't work properly on Leopard.

comment:5 Changed 13 years ago by michaelld (Michael Dickens)

I just updated octave-devel to 3.4.3. Is this still an issue for others? It seems to be related to the compiler version, but maybe there are internal changes that make the issue moot?

comment:6 Changed 13 years ago by jmrosenstock@…

Still a problem with octave-devel @3.4.3_0+gcc46.

comment:7 Changed 13 years ago by michaelld (Michael Dickens)

I just installed via MacPorts this morning "octave-devel +fltk +atlas +gcc45". FLTK(-devel) is @1.3.x-r9204; gcc45 is @4.5.3. This was a clean install, with only minimal other ports installed -- so, any port depending on the variants was installed using those variants. I did not get the mismatch dimensions crash. I'm wondering if the OP has the same variants for octave-devel, atlas, and qrupdate? That would certainly be an issue if not.

comment:8 Changed 12 years ago by michaelld (Michael Dickens)

We're now up to Octave 3.6.3 revision 0. All of the GCC ports have recently been updated. I've never been able to replicate this issue, though clearly it was an issue for some folks once upon a time. Can anyone confirm that it is still an issue?

comment:9 Changed 12 years ago by michaelld (Michael Dickens)

Resolution: fixed
Status: newclosed

Given the lack of response, I'm closing this ticket as fixed; reopen if you disagree.

Note: See TracTickets for help on using tickets.