X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?p=o-du%2Fphy.git;a=blobdiff_plain;f=fhi_lib%2Ftest%2Ftest_xran%2Funittests.cc;h=5b0b02cc6425ef58d566d4c81b581c8ace148d1f;hp=bf543a4470342834b91630f68388667e9f56cb2a;hb=2fbf70096f64af622da983e88c5a64e90ad9bdbd;hpb=9e108bb6d4caf2f6d4e920c640882fa49c15684c diff --git a/fhi_lib/test/test_xran/unittests.cc b/fhi_lib/test/test_xran/unittests.cc index bf543a4..5b0b02c 100644 --- a/fhi_lib/test/test_xran/unittests.cc +++ b/fhi_lib/test/test_xran/unittests.cc @@ -1,43 +1,43 @@ -/****************************************************************************** -* -* Copyright (c) 2019 Intel. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -* -*******************************************************************************/ - -#include -#include "xran_compression.h" -#include "gtest/gtest.h" - -#define MAX_IQ (273*12*2)// 273 RBs, 12 SC, 32bits IQ - -int8_t iCompressionOutput_AVX_A[MAX_IQ + MAX_IQ/24]; /* 273 RB 8 bits IQ + exponent */ -int16_t iDeCompressionOutput_AVX_A[MAX_IQ]; /* 273 RB 16bits IQ */ -int16_t iCompressionInput[MAX_IQ]; /* 273 RB 16bits IQ */ -int16_t iLength = 273*12*2; // total 16bits IQ - -// Tests -/* -TEST(Compression, Zero) { - EXPECT_EQ(0, xran_bfp_comp_avx512_fun_a(iCompressionInput,iCompressionOutput_AVX_A, iLength)); -} - - - -TEST(Decompression, Zero) { - iLength= 24+1; - EXPECT_EQ(0, xran_bfp_decomp_avx512_fun_a(iCompressionOutput_AVX_A,iDeCompressionOutput_AVX_A,iLength)); -}*/ - - +/****************************************************************************** +* +* Copyright (c) 2019 Intel. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +* +*******************************************************************************/ + +#include +#include "xran_compression.h" +#include "gtest/gtest.h" + +#define MAX_IQ (273*12*2)// 273 RBs, 12 SC, 32bits IQ + +int8_t iCompressionOutput_AVX_A[MAX_IQ + MAX_IQ/24]; /* 273 RB 8 bits IQ + exponent */ +int16_t iDeCompressionOutput_AVX_A[MAX_IQ]; /* 273 RB 16bits IQ */ +int16_t iCompressionInput[MAX_IQ]; /* 273 RB 16bits IQ */ +int16_t iLength = 273*12*2; // total 16bits IQ + +// Tests +/* +TEST(Compression, Zero) { + EXPECT_EQ(0, xran_bfp_comp_avx512_fun_a(iCompressionInput,iCompressionOutput_AVX_A, iLength)); +} + + + +TEST(Decompression, Zero) { + iLength= 24+1; + EXPECT_EQ(0, xran_bfp_decomp_avx512_fun_a(iCompressionOutput_AVX_A,iDeCompressionOutput_AVX_A,iLength)); +}*/ + +