Compute Library
 21.08
load_store_utility.h File Reference

Go to the source code of this file.

Macros

#define COMPUTE_M0_START_ROW(y, M0, PARTIAL_STORE_M0)   ((uint)(y * M0))
 
STORE_ROW_n

Store the 0 to (n-1)th rows of the given variables

Parameters
[in]N0The width of the passed in vector. Supported: 1, 2, 3, 4, 8, 16
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
#define STORE_ROW_1(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_2(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_3(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_4(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_5(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_6(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_7(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_8(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_9(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_10(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_11(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_12(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_13(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_14(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_15(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_16(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
CONVERT_STORE_ROW_n

Convert and store the 0th to (n-1)th rows of the given variables

Parameters
[in]N0The size of the vectors
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
#define CONVERT_STORE_ROW_1(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_2(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_3(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_4(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_5(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_6(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_7(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_8(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_9(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_10(N0, DATA, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_11(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_12(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_13(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_14(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_15(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_ROW_16(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
STORE_BLOCK

Store a block of the given size M0xN0

Supported cases are M0=1,2,3,...,16 and N0=2,3,4,8,16.

The data to store is expected to have consecutive names for each row. E.g., for M0=3 and basename=c, the expected names are c0, c1 and c2. The Z offset is expected to have consecutive names. E.g., for M0=3 and Z=zin, the expected z offset names are zin0, zin1 and zin2.

Parameters
[in]M0The number of rows to store
[in]N0The size of each vector
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
#define STORE_BLOCK_STR(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)   STORE_ROW_##M0(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_BLOCK(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)   STORE_BLOCK_STR(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
CONVERT_STORE_BLOCK

Convert and store a block of the given size M0xN0

Supported cases are M0=1,2,3,...,16 and N0=2,3,4,8,16.

The data to store is expected to have consecutive names for each row. E.g., for M0=3 and basename=c, the expected names are c0, c1 and c2. The Z offset is expected to have consecutive names. E.g., for M0=3 and Z=zin, the expected z offset names are zin0, zin1 and zin2.

Parameters
[in]M0The number of rows to store
[in]N0The size of each vector
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
#define CONVERT_STORE_BLOCK_STR(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)   CONVERT_STORE_ROW_##M0(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define CONVERT_STORE_BLOCK(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)   CONVERT_STORE_BLOCK_STR(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
STORE_ROW_PARTIAL_n

Partially store the 0 to (n-1)th rows of the given variables

Within each row, store the lower STORE_N0 elements of vectors of width N0

Note
in case STORE_N0 != 1, 2, 3, 4, 8, 16, extra vstore(s) will be invoked, thus incurring small performance penalty.
Parameters
[in]N0The width of the passed in vector. Supported: 1, 2, 3, 4, 8, 16
[in]STORE_N0The lower size of the vectors to store. Supported: [1-16 and <= N0
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
#define STORE_ROW_PARTIAL_1(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_2(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_3(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_4(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_5(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_6(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_7(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_8(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_9(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_10(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_11(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_12(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_13(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_14(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_15(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_ROW_PARTIAL_16(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
STORE_BLOCK_PARTIAL

Partially store a block of the given size STORE_M0xSTORE_N0

Note
The vector width N0 is also required for correct partial storing behaviour.
in case STORE_N0 != 1, 2, 3, 4, 8, 16, extra vstore(s) will be invoked, thus incurring small performance penalty.

The data to store is expected to have consecutive names for each row. E.g., for STORE_M0=3 and basename=c, the expected names are c0, c1 and c2. The Z offset is expected to have consecutive names. E.g., for STORE_M0=3 and Z=zin, the expected z offset names are zin0, zin1 and zin2.

Parameters
[in]STORE_M0The number of rows to store. Supported: 1-16
[in]STORE_N0The lower number of elements of vectors to store. Supported: 1-16 and <= N0
[in]N0The size of each vector. Supported: 1, 2, 3, 4, 8, 16
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
#define STORE_BLOCK_PARTIAL_STR(STORE_M0, STORE_N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)   STORE_ROW_PARTIAL_##STORE_M0(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_BLOCK_PARTIAL(STORE_M0, STORE_N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)   STORE_BLOCK_PARTIAL_STR(STORE_M0, STORE_N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
 
#define STORE_BLOCK_PARTIAL_IN_X_AND_Y(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z, PARTIAL_STORE_M0, PARTIAL_STORE_N0, PARTIAL_COND_Y, PARTIAL_COND_X)
 Store a block that can be partial in both x and y dimensions. More...
 
#define STORE_BLOCK_PARTIAL_IN_X(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z, PARTIAL_STORE_N0, PARTIAL_COND_X)
 Store a block that can only be partial in x but not y. More...
 
#define STORE_BLOCK_PARTIAL_IN_Y(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z, PARTIAL_STORE_M0, PARTIAL_COND_Y)
 Store a block that can only be partial in y but not x. More...
 
#define STORE_VECTOR_SELECT(basename, data_type, ptr, vec_size, leftover, cond)   STORE_BLOCK_PARTIAL_IN_X(1, vec_size, data_type, basename, ptr, 0, 0, leftover, cond)
 Store a vector that can only be partial in x. More...
 

Macro Definition Documentation

◆ COMPUTE_M0_START_ROW

#define COMPUTE_M0_START_ROW (   y,
  M0,
  PARTIAL_STORE_M0 
)    ((uint)(y * M0))

Definition at line 564 of file load_store_utility.h.

◆ CONVERT_STORE_BLOCK

#define CONVERT_STORE_BLOCK (   M0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)    CONVERT_STORE_BLOCK_STR(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 249 of file load_store_utility.h.

◆ CONVERT_STORE_BLOCK_STR

#define CONVERT_STORE_BLOCK_STR (   M0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)    CONVERT_STORE_ROW_##M0(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 248 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_1

#define CONVERT_STORE_ROW_1 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
VSTORE(N0) \
(CONVERT_SAT((BASENAME##0), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 0 * STRIDE_Y + Z##0));
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VSTORE(size)
Definition: helpers.h:249
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 127 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_10

#define CONVERT_STORE_ROW_10 (   N0,
  DATA,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_9(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##9), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 9 * STRIDE_Y + Z##9));
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define CONVERT_STORE_ROW_9(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 171 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_11

#define CONVERT_STORE_ROW_11 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_10(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##A), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 10 * STRIDE_Y + Z##A));
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define CONVERT_STORE_ROW_10(N0, DATA, BASENAME, PTR, STRIDE_Y, Z)
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 176 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_12

#define CONVERT_STORE_ROW_12 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_11(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##B), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 11 * STRIDE_Y + Z##B));
#define CONVERT_STORE_ROW_11(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 181 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_13

#define CONVERT_STORE_ROW_13 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_12(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##C), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 12 * STRIDE_Y + Z##C));
#define CONVERT_STORE_ROW_12(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 186 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_14

#define CONVERT_STORE_ROW_14 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_13(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##D), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 13 * STRIDE_Y + Z##D));
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define CONVERT_STORE_ROW_13(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 191 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_15

#define CONVERT_STORE_ROW_15 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_14(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##E), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 14 * STRIDE_Y + Z##E));
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define CONVERT_STORE_ROW_14(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 196 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_16

#define CONVERT_STORE_ROW_16 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_15(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##F), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 15 * STRIDE_Y + Z##F));
#define CONVERT_STORE_ROW_15(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 201 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_2

#define CONVERT_STORE_ROW_2 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_1(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##1), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 1 * STRIDE_Y + Z##1));
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define CONVERT_STORE_ROW_1(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 131 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_3

#define CONVERT_STORE_ROW_3 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_2(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##2), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 2 * STRIDE_Y + Z##2));
#define CONVERT_STORE_ROW_2(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 136 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_4

#define CONVERT_STORE_ROW_4 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_3(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##3), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 3 * STRIDE_Y + Z##3));
#define CONVERT_STORE_ROW_3(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 141 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_5

#define CONVERT_STORE_ROW_5 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_4(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##4), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 4 * STRIDE_Y + Z##4));
#define CONVERT_STORE_ROW_4(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 146 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_6

#define CONVERT_STORE_ROW_6 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_5(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##5), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 5 * STRIDE_Y + Z##5));
#define CONVERT_STORE_ROW_5(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 151 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_7

#define CONVERT_STORE_ROW_7 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_6(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##6), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 6 * STRIDE_Y + Z##6));
#define CONVERT_STORE_ROW_6(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 156 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_8

#define CONVERT_STORE_ROW_8 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_7(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##7), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 7 * STRIDE_Y + Z##7));
#define CONVERT_STORE_ROW_7(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 161 of file load_store_utility.h.

◆ CONVERT_STORE_ROW_9

#define CONVERT_STORE_ROW_9 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
CONVERT_STORE_ROW_8(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(CONVERT_SAT((BASENAME##8), VEC_DATA_TYPE(DATA_TYPE, N0)), 0, (__global DATA_TYPE *)(PTR + 8 * STRIDE_Y + Z##8));
#define CONVERT_STORE_ROW_8(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)
#define CONVERT_SAT(x, type)
Definition: helpers.h:525
#define VEC_DATA_TYPE(type, size)
Definition: helpers.h:519

Definition at line 166 of file load_store_utility.h.

◆ STORE_BLOCK

#define STORE_BLOCK (   M0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)    STORE_BLOCK_STR(M0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 227 of file load_store_utility.h.

◆ STORE_BLOCK_PARTIAL

#define STORE_BLOCK_PARTIAL (   STORE_M0,
  STORE_N0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)    STORE_BLOCK_PARTIAL_STR(STORE_M0, STORE_N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 369 of file load_store_utility.h.

◆ STORE_BLOCK_PARTIAL_IN_X

#define STORE_BLOCK_PARTIAL_IN_X (   M0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
  Z,
  PARTIAL_STORE_N0,
  PARTIAL_COND_X 
)
Value:
if(!(PARTIAL_COND_X)) \
{ \
STORE_BLOCK_PARTIAL(M0, N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z); \
} \
else \
{ \
STORE_BLOCK_PARTIAL(M0, PARTIAL_STORE_N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z); \
}
#define PARTIAL_STORE_N0
Definition: transpose.cl:25

Store a block that can only be partial in x but not y.

Note
in case N0 or PARTIAL_STORE_N0 != 1, 2, 3, 4, 8, 16, extra vstore(s) will be invoked, thus incurring small performance penalty.

The data to store is expected to have consecutive names for each row. E.g., for M0=3 and basename=c, the expected names are c0, c1 and c2. The Z offset is expected to have consecutive names. E.g., for M0=3 and Z=zin, the expected z offset names are zin0, zin1 and zin2.

Parameters
[in]M0The number of rows to store, for non-partial blocks. Supported: 1-16
[in]N0The size of each vector, for non-partial blocks. Supported: 1, 2, 3, 4, 8, 16
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
[in]PARTIAL_STORE_N0The partial size in x, for partial blocks. Supported range: [1, N0)
[in]PARTIAL_COND_XCondition on the x axis to perform the partial store X. True to use PARTIAL_STORE_N0 rather than N0.

Definition at line 427 of file load_store_utility.h.

◆ STORE_BLOCK_PARTIAL_IN_X_AND_Y

#define STORE_BLOCK_PARTIAL_IN_X_AND_Y (   M0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
  Z,
  PARTIAL_STORE_M0,
  PARTIAL_STORE_N0,
  PARTIAL_COND_Y,
  PARTIAL_COND_X 
)
Value:
if(!(PARTIAL_COND_X) && !(PARTIAL_COND_Y)) \
{ \
STORE_BLOCK_PARTIAL(M0, N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z); \
} \
else if((PARTIAL_COND_Y) && !(PARTIAL_COND_X)) \
{ \
STORE_BLOCK_PARTIAL(PARTIAL_STORE_M0, N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z); \
} \
else if(!(PARTIAL_COND_Y) && (PARTIAL_COND_X)) \
{ \
STORE_BLOCK_PARTIAL(M0, PARTIAL_STORE_N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z); \
} \
else \
{ \
STORE_BLOCK_PARTIAL(PARTIAL_STORE_M0, PARTIAL_STORE_N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z); \
}
#define PARTIAL_STORE_M0
Definition: transpose.cl:24
#define PARTIAL_STORE_N0
Definition: transpose.cl:25

Store a block that can be partial in both x and y dimensions.

Note
in cases PARTIAL_STORE_N0 != 1, 2, 3, 4, 8, 16, extra vstore(s) will be invoked, thus incurring small performance penalty.

The data to store is expected to have consecutive names for each row. E.g., for M0=3 and basename=c, the expected names are c0, c1 and c2. The Z offset is expected to have consecutive names. E.g., for M0=3 and Z=zin, the expected z offset names are zin0, zin1 and zin2.

Parameters
[in]M0The number of rows to store, for non-partial blocks. Supported: 1-16
[in]N0The size of each vector, for non-partial blocks. Supported: 1, 2, 3, 4, 8, 16
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
[in]PARTIAL_STORE_M0The partial size in y, for partial blocks. Supported range: [1, M0)
[in]PARTIAL_STORE_N0The partial size in x, for partial blocks. Supported range: [1, N0)
[in]PARTIAL_COND_YCondition on the y axis to perform the partial store Y. True to use PARTIAL_STORE_M0 rather than M0.
[in]PARTIAL_COND_XCondition on the x axis to perform the partial store X. True to use PARTIAL_STORE_N0 rather than N0.

Definition at line 391 of file load_store_utility.h.

◆ STORE_BLOCK_PARTIAL_IN_Y

#define STORE_BLOCK_PARTIAL_IN_Y (   M0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
  Z,
  PARTIAL_STORE_M0,
  PARTIAL_COND_Y 
)
Value:
if(!(PARTIAL_COND_Y)) \
{ \
STORE_BLOCK_PARTIAL(M0, N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z); \
} \
else \
{ \
STORE_BLOCK_PARTIAL(PARTIAL_STORE_M0, N0, N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z); \
}
#define PARTIAL_STORE_M0
Definition: transpose.cl:24

Store a block that can only be partial in y but not x.

Note
in case N0 or PARTIAL_STORE_N0 != 1, 2, 3, 4, 8, 16, extra vstore(s) will be invoked, thus incurring small performance penalty.

The data to store is expected to have consecutive names for each row. E.g., for M0=3 and basename=c, the expected names are c0, c1 and c2. The Z offset is expected to have consecutive names. E.g., for M0=3 and Z=zin, the expected z offset names are zin0, zin1 and zin2.

Parameters
[in]M0The number of rows to store, for non-partial blocks. Supported: 1-16
[in]N0The size of each vector, for non-partial blocks. Supported: 1, 2, 3, 4, 8, 16
[in]DATA_TYPEThe data type of the vectors
[in]BASENAMEThe basename of the variables
[in]PTRThe base pointer
[in]STRIDE_YThe stride value in y-axis direction
[in]ZThe offset in z-axis direction
[in]PARTIAL_STORE_M0The partial size in y, for partial blocks. Supported range: [1, M0)
[in]PARTIAL_COND_YCondition on the y axis to perform the partial store Y. True to use PARTIAL_STORE_M0 rather than M0.

Definition at line 455 of file load_store_utility.h.

◆ STORE_BLOCK_PARTIAL_STR

#define STORE_BLOCK_PARTIAL_STR (   STORE_M0,
  STORE_N0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)    STORE_ROW_PARTIAL_##STORE_M0(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 368 of file load_store_utility.h.

◆ STORE_BLOCK_STR

#define STORE_BLOCK_STR (   M0,
  N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)    STORE_ROW_##M0(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 226 of file load_store_utility.h.

◆ STORE_ROW_1

#define STORE_ROW_1 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
VSTORE(N0) \
(BASENAME##0, 0, (__global DATA_TYPE *)(PTR + 0 * STRIDE_Y + Z##0));
#define VSTORE(size)
Definition: helpers.h:249

Definition at line 36 of file load_store_utility.h.

◆ STORE_ROW_10

#define STORE_ROW_10 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_9(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##9, 0, (__global DATA_TYPE *)(PTR + 9 * STRIDE_Y + Z##9));
#define STORE_ROW_9(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 80 of file load_store_utility.h.

◆ STORE_ROW_11

#define STORE_ROW_11 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_10(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##A, 0, (__global DATA_TYPE *)(PTR + 10 * STRIDE_Y + Z##A));
#define STORE_ROW_10(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 85 of file load_store_utility.h.

◆ STORE_ROW_12

#define STORE_ROW_12 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_11(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##B, 0, (__global DATA_TYPE *)(PTR + 11 * STRIDE_Y + Z##B));
#define STORE_ROW_11(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 90 of file load_store_utility.h.

◆ STORE_ROW_13

#define STORE_ROW_13 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_12(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##C, 0, (__global DATA_TYPE *)(PTR + 12 * STRIDE_Y + Z##C));
#define STORE_ROW_12(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 95 of file load_store_utility.h.

◆ STORE_ROW_14

#define STORE_ROW_14 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_13(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##D, 0, (__global DATA_TYPE *)(PTR + 13 * STRIDE_Y + Z##D));
#define STORE_ROW_13(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 100 of file load_store_utility.h.

◆ STORE_ROW_15

#define STORE_ROW_15 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_14(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##E, 0, (__global DATA_TYPE *)(PTR + 14 * STRIDE_Y + Z##E));
#define STORE_ROW_14(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 105 of file load_store_utility.h.

◆ STORE_ROW_16

#define STORE_ROW_16 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_15(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##F, 0, (__global DATA_TYPE *)(PTR + 15 * STRIDE_Y + Z##F));
#define STORE_ROW_15(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 110 of file load_store_utility.h.

◆ STORE_ROW_2

#define STORE_ROW_2 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_1(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##1, 0, (__global DATA_TYPE *)(PTR + 1 * STRIDE_Y + Z##1));
#define STORE_ROW_1(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 40 of file load_store_utility.h.

◆ STORE_ROW_3

#define STORE_ROW_3 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_2(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##2, 0, (__global DATA_TYPE *)(PTR + 2 * STRIDE_Y + Z##2));
#define STORE_ROW_2(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 45 of file load_store_utility.h.

◆ STORE_ROW_4

#define STORE_ROW_4 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_3(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##3, 0, (__global DATA_TYPE *)(PTR + 3 * STRIDE_Y + Z##3));
#define STORE_ROW_3(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 50 of file load_store_utility.h.

◆ STORE_ROW_5

#define STORE_ROW_5 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_4(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##4, 0, (__global DATA_TYPE *)(PTR + 4 * STRIDE_Y + Z##4));
#define STORE_ROW_4(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 55 of file load_store_utility.h.

◆ STORE_ROW_6

#define STORE_ROW_6 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_5(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##5, 0, (__global DATA_TYPE *)(PTR + 5 * STRIDE_Y + Z##5));
#define STORE_ROW_5(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 60 of file load_store_utility.h.

◆ STORE_ROW_7

#define STORE_ROW_7 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_6(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##6, 0, (__global DATA_TYPE *)(PTR + 6 * STRIDE_Y + Z##6));
#define STORE_ROW_6(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 65 of file load_store_utility.h.

◆ STORE_ROW_8

#define STORE_ROW_8 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_7(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##7, 0, (__global DATA_TYPE *)(PTR + 7 * STRIDE_Y + Z##7));
#define STORE_ROW_7(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 70 of file load_store_utility.h.

◆ STORE_ROW_9

#define STORE_ROW_9 (   N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_8(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE(N0) \
(BASENAME##8, 0, (__global DATA_TYPE *)(PTR + 8 * STRIDE_Y + Z##8));
#define STORE_ROW_8(N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 75 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_1

#define STORE_ROW_PARTIAL_1 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##0, 0, (__global DATA_TYPE *)(PTR + 0 * STRIDE_Y + Z##0));
#define VSTORE_PARTIAL(size, store_size)
Definition: helpers.h:282

Definition at line 267 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_10

#define STORE_ROW_PARTIAL_10 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_9(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##9, 0, (__global DATA_TYPE *)(PTR + 9 * STRIDE_Y + Z##9));
#define STORE_ROW_PARTIAL_9(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 311 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_11

#define STORE_ROW_PARTIAL_11 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_10(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##A, 0, (__global DATA_TYPE *)(PTR + 10 * STRIDE_Y + Z##A));
#define STORE_ROW_PARTIAL_10(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 316 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_12

#define STORE_ROW_PARTIAL_12 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_11(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##B, 0, (__global DATA_TYPE *)(PTR + 11 * STRIDE_Y + Z##B));
#define STORE_ROW_PARTIAL_11(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 321 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_13

#define STORE_ROW_PARTIAL_13 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_12(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##C, 0, (__global DATA_TYPE *)(PTR + 12 * STRIDE_Y + Z##C));
#define STORE_ROW_PARTIAL_12(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 326 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_14

#define STORE_ROW_PARTIAL_14 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_13(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##D, 0, (__global DATA_TYPE *)(PTR + 13 * STRIDE_Y + Z##D));
#define STORE_ROW_PARTIAL_13(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 331 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_15

#define STORE_ROW_PARTIAL_15 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_14(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##E, 0, (__global DATA_TYPE *)(PTR + 14 * STRIDE_Y + Z##E));
#define STORE_ROW_PARTIAL_14(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 336 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_16

#define STORE_ROW_PARTIAL_16 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_15(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##F, 0, (__global DATA_TYPE *)(PTR + 15 * STRIDE_Y + Z##F));
#define STORE_ROW_PARTIAL_15(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 341 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_2

#define STORE_ROW_PARTIAL_2 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_1(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##1, 0, (__global DATA_TYPE *)(PTR + 1 * STRIDE_Y + Z##1));
#define STORE_ROW_PARTIAL_1(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 271 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_3

#define STORE_ROW_PARTIAL_3 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_2(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##2, 0, (__global DATA_TYPE *)(PTR + 2 * STRIDE_Y + Z##2));
#define STORE_ROW_PARTIAL_2(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 276 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_4

#define STORE_ROW_PARTIAL_4 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_3(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##3, 0, (__global DATA_TYPE *)(PTR + 3 * STRIDE_Y + Z##3));
#define STORE_ROW_PARTIAL_3(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 281 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_5

#define STORE_ROW_PARTIAL_5 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_4(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##4, 0, (__global DATA_TYPE *)(PTR + 4 * STRIDE_Y + Z##4));
#define STORE_ROW_PARTIAL_4(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 286 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_6

#define STORE_ROW_PARTIAL_6 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_5(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##5, 0, (__global DATA_TYPE *)(PTR + 5 * STRIDE_Y + Z##5));
#define STORE_ROW_PARTIAL_5(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 291 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_7

#define STORE_ROW_PARTIAL_7 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_6(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##6, 0, (__global DATA_TYPE *)(PTR + 6 * STRIDE_Y + Z##6));
#define STORE_ROW_PARTIAL_6(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 296 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_8

#define STORE_ROW_PARTIAL_8 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_7(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##7, 0, (__global DATA_TYPE *)(PTR + 7 * STRIDE_Y + Z##7));
#define STORE_ROW_PARTIAL_7(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 301 of file load_store_utility.h.

◆ STORE_ROW_PARTIAL_9

#define STORE_ROW_PARTIAL_9 (   N0,
  STORE_N0,
  DATA_TYPE,
  BASENAME,
  PTR,
  STRIDE_Y,
 
)
Value:
STORE_ROW_PARTIAL_8(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z) \
VSTORE_PARTIAL(N0, STORE_N0) \
(BASENAME##8, 0, (__global DATA_TYPE *)(PTR + 8 * STRIDE_Y + Z##8));
#define STORE_ROW_PARTIAL_8(N0, STORE_N0, DATA_TYPE, BASENAME, PTR, STRIDE_Y, Z)

Definition at line 306 of file load_store_utility.h.

◆ STORE_VECTOR_SELECT

#define STORE_VECTOR_SELECT (   basename,
  data_type,
  ptr,
  vec_size,
  leftover,
  cond 
)    STORE_BLOCK_PARTIAL_IN_X(1, vec_size, data_type, basename, ptr, 0, 0, leftover, cond)

Store a vector that can only be partial in x.

Note
in case vec_size or leftover != 1, 2, 3, 4, 8, 16, extra vstore(s) will be invoked, thus incurring small performance penalty.

The data to store is expected to end in a 0. E.g., for basename=c, the expected name is c0.

Parameters
[in]basenameThe name of the variable without trailing 0
[in]data_typeThe data type of the vector
[in]ptrThe base pointer
[in]vec_sizeThe vector size if cond = false. Supported: 1, 2, 3, 4, 8, 16
[in]leftoverThe vector size if cond = true. Supported range: [1, vec_size0)
[in]condCondition to select either vec_size0 or vec_size1

Definition at line 584 of file load_store_utility.h.

Referenced by cast_down(), and cast_up().