HPL_indxg2l(3)
π HPL_indxg2l β bestie edition π
okay so this is a page from the HPL Library Functions manual (that's the manual name, we're folding it in here, you're welcome π«Ά) and it's all about one lil' function called HPL_indxg2l. and yes the name is a mouthful, but it's literally just "index global β local" and honestly? iconic. let's get into it β¨
β¨ NAME β¨
HPL_indxg2l β maps a global index into a local one. that's it. that's the whole job. slay π
πΈ SYNOPSIS πΈ
#include "hpl.h"
int HPL_indxg2l( const int IG, const int INB, const int NB, const int
SRCPROC, const int NPROCS );
there she is. five const ints and a dream π
π¦ DESCRIPTION π¦
so HPL_indxg2l computes the local index of a matrix entry that's being pointed to by the global index IG.
and here's the cute part, the detail you cannot miss: this local index it hands back is the same in all processes. like, everyone gets the same answer, no drama, no "well it depends on who's asking" energy. consistency is the vibe, periodt π
π ARGUMENTS π
IG(input)const intβ on entry,IGspecifies the global index of the matrix entry. it must be at least zero. no negative vibes allowed, bestie, fr fr πINB(input)const intβ on entry,INBspecifies the size of the first block of the global matrix. it must be at least one.NB(input)const intβ on entry,NBis the blocking factor used to partition and distribute the matrix. it must be larger than one. yes, strictly larger, so1does not pass the vibe check πSRCPROC(input)const intβ on entry, ifSRCPROC = -1, then the data is not distributed but replicated, in which case this routine just returnsIGin all processes. otherwise, the value ofSRCPROCis ignored. like it's there but it said nothing, we move on π§NPROCS(input)const intβ on entry,NPROCSspecifies the total number of process rows or columns over which the matrix is distributed. it must be at least one.
ok real talk, those "must be" constraints aren't decoration, they're the contract. feed this thing a bad value and you're on your own, no cap π
π SEE ALSO π
HPL_indxg2lp(3)HPL_indxg2p(3)HPL_indxl2g(3)HPL_numroc(3)HPL_numrocI(3)
the whole index-math friend group, all showing up together, we love a supportive squad π«Ά
and that's the page!! before you go, the receipts: this is HPL 2.2, dated February 24, 2016, from the HPL Library Functions collection, filed under HPL_indxg2l(3). go forth and map those indices, bestie, you got this ππβ¨
π¦ where this page comes from
- fedora 43: hpl-doc 2.2-22.fc43 Β· LicenseRef-Callaway-BSD-with-advertising
- fedora 44: hpl-doc 2.2-23.fc44 Β· LicenseRef-Callaway-BSD-with-advertising
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms