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

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

[Octave-bug-tracker] [bug #57033] Replace CXSPARSE with SPQR


From: Markus Mützel
Subject: [Octave-bug-tracker] [bug #57033] Replace CXSPARSE with SPQR
Date: Wed, 6 Jan 2021 06:25:34 -0500 (EST)
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.88 Safari/537.36 Edg/87.0.664.66

Follow-up Comment #38, bug #57033 (project octave):

The 32bit Windows builds are failing with this change.
The reason is that the index (permutation) arguments of the functions in SPQR
are pointers to `SuiteSparse_long`. That type is defined by SuiteSparse to
have the same size as `ptrdiff_t` on all platforms. They seem to be using
`int64_t` for Win64 and `long` for all other platforms.
In our code, we are using pointers to `octave::suitesparse_integer` which we
define to either `SuiteSparse_long` for OCTAVE_ENABLE_64 or `int` otherwise.
Even if `long` and `int` have the same size for win32 targets (ILP32), the
compiler fails on implicitly casting the respective pointers.
That cast would really be safe for win32 targets.

On the other hand, when building for a 64bit target with Octave's indexing
type being set to 32bit, assignments from type `SuiteSparse_long` to
`octave_idx_type` should be carefully checked. It doesn't look like this is
done currently.

Do we already have functions that could be used for both of these issues?

    _______________________________________________________

Reply to this item at:

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

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




reply via email to

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