Переименование типов на на общепринятый формат, отказ от суффикса _t, так как он зарезервирован POSIX
This commit is contained in:
parent
3805354611
commit
0027924f86
26 changed files with 574 additions and 571 deletions
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
// ========== Matrix Product 2x2 at 3x2 ========= //
|
||||
|
||||
void bgc_matrix_product_2x2_at_3x2_fp32(const bgc_matrix2x2_fp32_t* matrix1, const bgc_matrix3x2_fp32_t* matrix2, bgc_matrix3x2_fp32_t* result)
|
||||
void bgc_matrix_product_2x2_at_3x2_fp32(const BgcMatrix2x2FP32* matrix1, const BgcMatrix3x2FP32* matrix2, BgcMatrix3x2FP32* result)
|
||||
{
|
||||
const float r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1;
|
||||
const float r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2;
|
||||
|
|
@ -21,7 +21,7 @@ void bgc_matrix_product_2x2_at_3x2_fp32(const bgc_matrix2x2_fp32_t* matrix1, con
|
|||
result->r2c3 = r2c3;
|
||||
}
|
||||
|
||||
void bgc_matrix_product_2x2_at_3x2_fp64(const bgc_matrix2x2_fp64_t* matrix1, const bgc_matrix3x2_fp64_t* matrix2, bgc_matrix3x2_fp64_t* result)
|
||||
void bgc_matrix_product_2x2_at_3x2_fp64(const BgcMatrix2x2FP64* matrix1, const BgcMatrix3x2FP64* matrix2, BgcMatrix3x2FP64* result)
|
||||
{
|
||||
const double r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1;
|
||||
const double r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2;
|
||||
|
|
@ -42,7 +42,7 @@ void bgc_matrix_product_2x2_at_3x2_fp64(const bgc_matrix2x2_fp64_t* matrix1, con
|
|||
|
||||
// ========== Matrix Product 2x3 at 2x2 ========= //
|
||||
|
||||
void bgc_matrix_product_2x3_at_2x2_fp32(const bgc_matrix2x3_fp32_t* matrix1, const bgc_matrix2x2_fp32_t* matrix2, bgc_matrix2x3_fp32_t* result)
|
||||
void bgc_matrix_product_2x3_at_2x2_fp32(const BgcMatrix2x3FP32* matrix1, const BgcMatrix2x2FP32* matrix2, BgcMatrix2x3FP32* result)
|
||||
{
|
||||
const float r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1;
|
||||
const float r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2;
|
||||
|
|
@ -63,7 +63,7 @@ void bgc_matrix_product_2x3_at_2x2_fp32(const bgc_matrix2x3_fp32_t* matrix1, con
|
|||
result->r3c2 = r3c2;
|
||||
}
|
||||
|
||||
void bgc_matrix_product_2x3_at_2x2_fp64(const bgc_matrix2x3_fp64_t* matrix1, const bgc_matrix2x2_fp64_t* matrix2, bgc_matrix2x3_fp64_t* result)
|
||||
void bgc_matrix_product_2x3_at_2x2_fp64(const BgcMatrix2x3FP64* matrix1, const BgcMatrix2x2FP64* matrix2, BgcMatrix2x3FP64* result)
|
||||
{
|
||||
const double r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1;
|
||||
const double r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2;
|
||||
|
|
@ -86,7 +86,7 @@ void bgc_matrix_product_2x3_at_2x2_fp64(const bgc_matrix2x3_fp64_t* matrix1, con
|
|||
|
||||
// ========== Matrix Product 2x3 at 3x2 ========= //
|
||||
|
||||
void bgc_matrix_product_2x3_at_3x2_fp32(const bgc_matrix2x3_fp32_t* matrix1, const bgc_matrix3x2_fp32_t* matrix2, bgc_matrix3x3_fp32_t* result)
|
||||
void bgc_matrix_product_2x3_at_3x2_fp32(const BgcMatrix2x3FP32* matrix1, const BgcMatrix3x2FP32* matrix2, BgcMatrix3x3FP32* result)
|
||||
{
|
||||
result->r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1;
|
||||
result->r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2;
|
||||
|
|
@ -101,7 +101,7 @@ void bgc_matrix_product_2x3_at_3x2_fp32(const bgc_matrix2x3_fp32_t* matrix1, con
|
|||
result->r3c3 = matrix1->r3c1 * matrix2->r1c3 + matrix1->r3c2 * matrix2->r2c3;
|
||||
}
|
||||
|
||||
void bgc_matrix_product_2x3_at_3x2_fp64(const bgc_matrix2x3_fp64_t* matrix1, const bgc_matrix3x2_fp64_t* matrix2, bgc_matrix3x3_fp64_t* result)
|
||||
void bgc_matrix_product_2x3_at_3x2_fp64(const BgcMatrix2x3FP64* matrix1, const BgcMatrix3x2FP64* matrix2, BgcMatrix3x3FP64* result)
|
||||
{
|
||||
result->r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1;
|
||||
result->r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2;
|
||||
|
|
@ -118,7 +118,7 @@ void bgc_matrix_product_2x3_at_3x2_fp64(const bgc_matrix2x3_fp64_t* matrix1, con
|
|||
|
||||
// ========== Matrix Product 3x2 at 2x3 ========= //
|
||||
|
||||
void bgc_matrix_product_3x2_at_2x3_fp32(const bgc_matrix3x2_fp32_t* matrix1, const bgc_matrix2x3_fp32_t* matrix2, bgc_matrix2x2_fp32_t* result)
|
||||
void bgc_matrix_product_3x2_at_2x3_fp32(const BgcMatrix3x2FP32* matrix1, const BgcMatrix2x3FP32* matrix2, BgcMatrix2x2FP32* result)
|
||||
{
|
||||
result->r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1 + matrix1->r1c3 * matrix2->r3c1;
|
||||
result->r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2 + matrix1->r1c3 * matrix2->r3c2;
|
||||
|
|
@ -127,7 +127,7 @@ void bgc_matrix_product_3x2_at_2x3_fp32(const bgc_matrix3x2_fp32_t* matrix1, con
|
|||
result->r2c2 = matrix1->r2c1 * matrix2->r1c2 + matrix1->r2c2 * matrix2->r2c2 + matrix1->r2c3 * matrix2->r3c2;
|
||||
}
|
||||
|
||||
void bgc_matrix_product_3x2_at_2x3_fp64(const bgc_matrix3x2_fp64_t* matrix1, const bgc_matrix2x3_fp64_t* matrix2, bgc_matrix2x2_fp64_t* result)
|
||||
void bgc_matrix_product_3x2_at_2x3_fp64(const BgcMatrix3x2FP64* matrix1, const BgcMatrix2x3FP64* matrix2, BgcMatrix2x2FP64* result)
|
||||
{
|
||||
result->r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1 + matrix1->r1c3 * matrix2->r3c1;
|
||||
result->r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2 + matrix1->r1c3 * matrix2->r3c2;
|
||||
|
|
@ -138,7 +138,7 @@ void bgc_matrix_product_3x2_at_2x3_fp64(const bgc_matrix3x2_fp64_t* matrix1, con
|
|||
|
||||
// ========== Matrix Product 3x2 at 3x3 ========= //
|
||||
|
||||
void bgc_matrix_product_3x2_at_3x3_fp32(const bgc_matrix3x2_fp32_t* matrix1, const bgc_matrix3x3_fp32_t* matrix2, bgc_matrix3x2_fp32_t* result)
|
||||
void bgc_matrix_product_3x2_at_3x3_fp32(const BgcMatrix3x2FP32* matrix1, const BgcMatrix3x3FP32* matrix2, BgcMatrix3x2FP32* result)
|
||||
{
|
||||
const float r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1 + matrix1->r1c3 * matrix2->r3c1;
|
||||
const float r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2 + matrix1->r1c3 * matrix2->r3c2;
|
||||
|
|
@ -157,7 +157,7 @@ void bgc_matrix_product_3x2_at_3x3_fp32(const bgc_matrix3x2_fp32_t* matrix1, con
|
|||
result->r2c3 = r2c3;
|
||||
}
|
||||
|
||||
void bgc_matrix_product_3x2_at_3x3_fp64(const bgc_matrix3x2_fp64_t* matrix1, const bgc_matrix3x3_fp64_t* matrix2, bgc_matrix3x2_fp64_t* result)
|
||||
void bgc_matrix_product_3x2_at_3x3_fp64(const BgcMatrix3x2FP64* matrix1, const BgcMatrix3x3FP64* matrix2, BgcMatrix3x2FP64* result)
|
||||
{
|
||||
const double r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1 + matrix1->r1c3 * matrix2->r3c1;
|
||||
const double r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2 + matrix1->r1c3 * matrix2->r3c2;
|
||||
|
|
@ -178,7 +178,7 @@ void bgc_matrix_product_3x2_at_3x3_fp64(const bgc_matrix3x2_fp64_t* matrix1, con
|
|||
|
||||
// ========== Matrix Product 3x3 at 2x3 ========= //
|
||||
|
||||
void bgc_matrix_product_3x3_at_2x3_fp32(const bgc_matrix3x3_fp32_t* matrix1, const bgc_matrix2x3_fp32_t* matrix2, bgc_matrix2x3_fp32_t* result)
|
||||
void bgc_matrix_product_3x3_at_2x3_fp32(const BgcMatrix3x3FP32* matrix1, const BgcMatrix2x3FP32* matrix2, BgcMatrix2x3FP32* result)
|
||||
{
|
||||
const float r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1 + matrix1->r1c3 * matrix2->r3c1;
|
||||
const float r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2 + matrix1->r1c3 * matrix2->r3c2;
|
||||
|
|
@ -199,7 +199,7 @@ void bgc_matrix_product_3x3_at_2x3_fp32(const bgc_matrix3x3_fp32_t* matrix1, con
|
|||
result->r3c2 = r3c2;
|
||||
}
|
||||
|
||||
void bgc_matrix_product_3x3_at_2x3_fp64(const bgc_matrix3x3_fp64_t* matrix1, const bgc_matrix2x3_fp64_t* matrix2, bgc_matrix2x3_fp64_t* result)
|
||||
void bgc_matrix_product_3x3_at_2x3_fp64(const BgcMatrix3x3FP64* matrix1, const BgcMatrix2x3FP64* matrix2, BgcMatrix2x3FP64* result)
|
||||
{
|
||||
const double r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1 + matrix1->r1c3 * matrix2->r3c1;
|
||||
const double r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2 + matrix1->r1c3 * matrix2->r3c2;
|
||||
|
|
@ -222,7 +222,7 @@ void bgc_matrix_product_3x3_at_2x3_fp64(const bgc_matrix3x3_fp64_t* matrix1, con
|
|||
|
||||
// ========== Matrix Product 3x3 at 3x3 ========= //
|
||||
|
||||
void bgc_matrix_product_3x3_at_3x3_fp32(const bgc_matrix3x3_fp32_t* matrix1, const bgc_matrix3x3_fp32_t* matrix2, bgc_matrix3x3_fp32_t* result)
|
||||
void bgc_matrix_product_3x3_at_3x3_fp32(const BgcMatrix3x3FP32* matrix1, const BgcMatrix3x3FP32* matrix2, BgcMatrix3x3FP32* result)
|
||||
{
|
||||
const float r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1 + matrix1->r1c3 * matrix2->r3c1;
|
||||
const float r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2 + matrix1->r1c3 * matrix2->r3c2;
|
||||
|
|
@ -249,7 +249,7 @@ void bgc_matrix_product_3x3_at_3x3_fp32(const bgc_matrix3x3_fp32_t* matrix1, con
|
|||
result->r3c3 = r3c3;
|
||||
}
|
||||
|
||||
void bgc_matrix_product_3x3_at_3x3_fp64(const bgc_matrix3x3_fp64_t* matrix1, const bgc_matrix3x3_fp64_t* matrix2, bgc_matrix3x3_fp64_t* result)
|
||||
void bgc_matrix_product_3x3_at_3x3_fp64(const BgcMatrix3x3FP64* matrix1, const BgcMatrix3x3FP64* matrix2, BgcMatrix3x3FP64* result)
|
||||
{
|
||||
const double r1c1 = matrix1->r1c1 * matrix2->r1c1 + matrix1->r1c2 * matrix2->r2c1 + matrix1->r1c3 * matrix2->r3c1;
|
||||
const double r1c2 = matrix1->r1c1 * matrix2->r1c2 + matrix1->r1c2 * matrix2->r2c2 + matrix1->r1c3 * matrix2->r3c2;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue