HPL_dlaswp01T(3)

πŸ“¦ version 2.2, in fedora 43, fedora 44

πŸ’– NAME πŸ’–

HPL_dlaswp01T β€” copies rows of A into itself and into U. (she's from the HPL Library Functions lineup, bestie πŸ’…)


✨ SYNOPSIS ✨

#include "hpl.h"

void HPL_dlaswp01T( const int M, const int N, double * A, const int LDA,
double * U, const int LDU, const int * LINDXA, const int * LINDXAU );

πŸ¦‹ DESCRIPTION πŸ¦‹

Okay so real talk: HPL_dlaswp01T takes scattered rows of A and copies them into A itself and into an array U. Like, both. At once. Multitasking queen πŸ‘‘

The row offsets in A of the source rows? Those are specified by LINDXA. And where those rows are headed? That's LINDXAU's whole job.

Here's the vibe check on LINDXAU: a positive value means the destination is U. Anything else means it's A. Periodt.

And the lil plot twist 🌸 β€” rows of A are stored as columns in U. Yes bestie, transposed, we love a layout switcheroo.


πŸ‘‘ ARGUMENTS πŸ‘‘

  • M (local input) β€” const int. On entry, M says how many rows of A should be moved within A or copied into U. M must be at least zero. No negatives, she doesn't do that πŸ’€
  • N (local input) β€” const int. On entry, N is the length of the rows of A that should be moved within A or copied into U. N must be at least zero too. Rules are rules πŸŽ€
  • A (local input/output) β€” double *. On entry, A points to an array of dimension (LDA,N). The rows of this array specified by LINDXA should be moved within A or copied into U. She's both the source and the destination, main character energy fr fr ✨
  • LDA (local input) β€” const int. On entry, LDA is the leading dimension of the array A. LDA must be at least MAX(1,M). Do not skip this, the math will simply not math πŸ™ˆ
  • U (local input/output) β€” double *. On entry, U points to an array of dimension (LDU,M). The rows of A specified by LINDXA are copied within this array U at the positions indicated by positive values of LINDXAU. The rows of A are stored as columns in U. Iconic behaviour honestly πŸ’œ
  • LDU (local input) β€” const int. On entry, LDU is the leading dimension of the array U. LDU must be at least MAX(1,N). Yes it's N here and M up there for LDA β€” that's not a typo, that's just the assignment bestie 😭
  • LINDXA (local input) β€” const int *. On entry, LINDXA is an array of dimension M that contains the local row indexes of A that should be moved within A or copied into U. She's the "where from" list πŸ“
  • LINDXAU (local input) β€” const int *. On entry, LINDXAU is an array of dimension M that contains the local row indexes of U where the rows of A should be copied at. This array also contains the local row offsets in A where some of the rows of A should be moved to. A positive value of LINDXAU[i] indicates that the row LINDXA[i] of A should be copied into U at the position LINDXAU[i]; otherwise the row LINDXA[i] of A should be moved at the position -LINDXAU[i] within A. She's the "where to" list and she's carrying a sign bit like a lil secret 🧚
Ngl the LINDXAU sign thing is the whole trick of this function. Positive β†’ into U. Otherwise β†’ moved inside A at -LINDXAU[i]. Read it twice if you need to, no shame πŸ’–

🌈 SEE ALSO 🌈

The whole friend group, go say hi πŸ‘‹


That's the whole page, bestie, you ate it up 🫢 This one's from HPL 2.2, dated February 24, 2016 β€” old enough to have a driver's license but still slaying ⭐

πŸ“¦ where this page comes from