About "setup_pivinfo"

5 views
Skip to first unread message

Aran Nokan

unread,
Mar 10, 2022, 2:03:27 PM3/10/22
to MAGMA User
Hi,

Could you please help me to understand this function? What is the relation between ipiv and pivinfo here? 

setup_pivinfo( magma_int_t *pivinfo, magma_int_t *ipiv,
                 magma_int_t m, magma_int_t nb,
                 magma_queue_t queue)

for (int s =0; s < nchunk; s++)
    {
        if ( (tid + s * MAX_NTHREADS < m) && (tid < MAX_NTHREADS) )
            pivinfo[tid + s * MAX_NTHREADS] = tid + s * MAX_NTHREADS + 1;
    }
    __syncthreads();

    if (tid == 0)
    {  
        int i, itsreplacement, mynewrowid;
        for (i=0; i < nb; i++) {
            mynewrowid          = ipiv[i]-1; //-1 to get the index in C
            itsreplacement      = pivinfo[mynewrowid];
            pivinfo[mynewrowid] = pivinfo[i];
            pivinfo[i]          = itsreplacement;
        }

Best regard,
Aran

Ahmad Abdelfattah

unread,
Mar 10, 2022, 3:05:51 PM3/10/22
to Aran Nokan, MAGMA User
Please refer to section 6.6 of the paper below. 

--
You received this message because you are subscribed to the Google Groups "MAGMA User" group.
To unsubscribe from this group and stop receiving emails from it, send an email to magma-user+...@icl.utk.edu.
To view this discussion on the web visit https://groups.google.com/a/icl.utk.edu/d/msgid/magma-user/CAKHt_YbRXbppMoS4ji9mwogf%2BLA7Wn1hht4Uyd9U1P4V0QGgGA%40mail.gmail.com.

Reply all
Reply to author
Forward
0 new messages