Переход на версию 0.3: изменение подхода к именованию сущностей, добавление, изменение и удаление ряда функций

This commit is contained in:
Andrey Pokidov 2026-01-30 19:37:49 +07:00
parent d33daf4e2d
commit f7e41645fe
87 changed files with 4580 additions and 4051 deletions

View file

@ -8,14 +8,14 @@
static const int _TEST_FP32_COMPLEX_AMOUNT = 4;
static const BgcComplexFP32 _TEST_FP32_COMPLEX_LIST1[] = {
static const BGC_FP32_Complex _TEST_FP32_COMPLEX_LIST1[] = {
{ 3.0f, 4.0f },
{ -2.0f, -1.0f },
{ -244.8f, 100.0f },
{ 1000.32f, -100.1f }
};
static const BgcComplexFP32 _TEST_FP32_COMPLEX_LIST2[] = {
static const BGC_FP32_Complex _TEST_FP32_COMPLEX_LIST2[] = {
{ 5.3f, 1003.28f },
{ -0.0032f, 891.3f },
{ 5.322f, 0.9275f },
@ -24,15 +24,15 @@ static const BgcComplexFP32 _TEST_FP32_COMPLEX_LIST2[] = {
void test_complex_swap_fp32()
{
BgcComplexFP32 compleimaginary, complex2;
BGC_FP32_Complex compleimaginary, complex2;
print_testing_name("bgc_complex_swap_fp32");
print_testing_name("bgc_fp32_complex_swap");
for (int i = 0; i < _TEST_FP32_COMPLEX_AMOUNT; i++) {
bgc_complex_copy_fp32(&_TEST_FP32_COMPLEX_LIST1[i], &compleimaginary);
bgc_complex_copy_fp32(&_TEST_FP32_COMPLEX_LIST2[i], &complex2);
bgc_fp32_complex_copy(&_TEST_FP32_COMPLEX_LIST1[i], &compleimaginary);
bgc_fp32_complex_copy(&_TEST_FP32_COMPLEX_LIST2[i], &complex2);
bgc_complex_swap_fp32(&compleimaginary, &complex2);
bgc_fp32_complex_swap(&compleimaginary, &complex2);
if (compleimaginary.real != _TEST_FP32_COMPLEX_LIST2[i].real ||
compleimaginary.imaginary != _TEST_FP32_COMPLEX_LIST2[i].imaginary ||
@ -50,14 +50,14 @@ void test_complex_swap_fp32()
static const int _TEST_FP64_COMPLEX_AMOUNT = 4;
static const BgcComplexFP64 _TEST_FP64_COMPLEX_LIST1[] = {
static const BGC_FP64_Complex _TEST_FP64_COMPLEX_LIST1[] = {
{ 1.0, 4.0 },
{ -4.0, -3.0 },
{ -244.8, 344.7 },
{ 1000.32, -271.3 }
};
static const BgcComplexFP64 _TEST_FP64_COMPLEX_LIST2[] = {
static const BGC_FP64_Complex _TEST_FP64_COMPLEX_LIST2[] = {
{ -0.123, 1003.28 },
{ 204.07, -781.89 },
{ 5.322, 0.9275 },
@ -66,15 +66,15 @@ static const BgcComplexFP64 _TEST_FP64_COMPLEX_LIST2[] = {
void test_complex_swap_fp64()
{
BgcComplexFP64 compleimaginary, complex2;
BGC_FP64_Complex compleimaginary, complex2;
print_testing_name("bgc_complex_swap_fp64");
print_testing_name("bgc_fp64_complex_swap");
for (int i = 0; i < _TEST_FP64_COMPLEX_AMOUNT; i++) {
bgc_complex_copy_fp64(&_TEST_FP64_COMPLEX_LIST1[i], &compleimaginary);
bgc_complex_copy_fp64(&_TEST_FP64_COMPLEX_LIST2[i], &complex2);
bgc_fp64_complex_copy(&_TEST_FP64_COMPLEX_LIST1[i], &compleimaginary);
bgc_fp64_complex_copy(&_TEST_FP64_COMPLEX_LIST2[i], &complex2);
bgc_complex_swap_fp64(&compleimaginary, &complex2);
bgc_fp64_complex_swap(&compleimaginary, &complex2);
if (compleimaginary.real != _TEST_FP64_COMPLEX_LIST2[i].real ||
compleimaginary.imaginary != _TEST_FP64_COMPLEX_LIST2[i].imaginary ||