Mercurial > octave-libgccjit
view diff-template @ 8964:f4f4d65faaa0
Implement sparse * diagonal and diagonal * sparse operations, double-prec only.
Date: Sun, 8 Mar 2009 16:28:18 -0400
These preserve sparsity, so eye(5) * sprand (5, 5, .2) is *sparse*
and not dense. This may affect people who use multiplication by
eye() rather than full().
The liboctave routines do *not* check if arguments are scalars in
disguise. There is a type problem with checking at that level. I
suspect we want diag * "sparse scalar" to stay diagonal, but we have
to return a sparse matrix at the liboctave. Rather than worrying
about that in liboctave, we cope with it when binding to Octave and
return the correct higher-level type.
The implementation is in Sparse-diag-op-defs.h rather than
Sparse-op-defs.h to limit recompilation. And the implementations
are templates rather than macros to produce better compiler errors
and debugging information.
author | Jason Riedy <jason@acm.org> |
---|---|
date | Mon, 09 Mar 2009 17:49:13 -0400 |
parents | 4a9feb849125 |
children | 66fdc831c580 |
line wrap: on
line source
#!/bin/sh # # To apply this patch, cd to the top level Octave source directory and # run this file through /bin/sh. It will first remove any files that # have been deleted from the source distribution since the last # release and then update the sources with patch(1). # # Diffs for updating *.ps, *.dvi, and *.info* files are not included # because they can be recreated from the Texinfo files using TeX and # makeinfo. # # Diffs for updating parse.cc and y.tab.h are not included because # they can be recreated from the file parse.y using bison. # # Diffs for updating lex.cc are not included because it can be # recreated from lex.l using flex. # # Diffs for updating the configure script are not included because # it can be recreated from configure.in using autoconf. # # John W. Eaton # jwe@bevo.che.wisc.edu # University of Wisconsin-Madison # Department of Chemical Engineering if test -f src/octave.cc ; then true else echo '***********************************************************' 1>&2 echo 'You must run this script in the top-level octave directory!' 1>&2 echo '***********************************************************' 1>&2 exit 1 fi echo 'removing the bsd-math directory' rm -rf bsd-math echo 'creating libcruft/slatec-fn directory' mkdir libcruft/slatec-fn echo 'removing old test files' rm -f test/octave.test/index.exp rm -f test/octave.test/prefer.exp rm -f test/octave.test/zero-one.exp echo 'creating directories for new test files' mkdir test/octave.test/index/dfi-f mkdir test/octave.test/index/dfi-t mkdir test/octave.test/prefer mkdir test/octave.test/zero-one/fff mkdir test/octave.test/zero-one/fft mkdir test/octave.test/zero-one/ftf mkdir test/octave.test/zero-one/tff mkdir test/octave.test/zero-one/ftt mkdir test/octave.test/zero-one/tft mkdir test/octave.test/zero-one/ttf mkdir test/octave.test/zero-one/ttt echo 'patching existing files' patch -p1 << \PATCH_EOF PATCH_EOF