#13151: fix pickling of Matrix_modn_dense_double on SPARC
---------------------------------+------------------------------------------
       Reporter:  malb           |         Owner:  drkirkby
           Type:  defect         |        Status:  new     
       Priority:  major          |     Milestone:  sage-5.9
      Component:  porting        |    Resolution:          
       Keywords:  Solaris SPARC  |   Work issues:          
Report Upstream:  N/A            |     Reviewers:          
        Authors:                 |     Merged in:          
   Dependencies:                 |      Stopgaps:          
---------------------------------+------------------------------------------

Comment (by jpflori):

 Replying to [comment:7 jdemeyer]:
 > eplying to [comment:2 vbraun]:
 > > I tried `gcc -munaligned-doubles` but that didn't help.
 > >
 > > The problem seems to be that malloc on 32-bit SPARC solaris generally
 returns 4-byte aligned buffers.
 > That's not necessarily the case.  The string `<char*>s` isn't directly
 generated from a `malloc`, instead it is the result of a
 `PyString_AsString()` call.  That isn't guaranteed to be 8-bytes aligned.
 >
 > The obvious solution is to allocate a buffer ourselves, fill that and
 pass the result to `PyString_FromStringAndSize(buf, size)`. This will
 cause an extra `memcpy()` but that might be unavoidable.
 So should we go with that solution?

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/13151#comment:23>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to