Skip to content

Fix for llr functions reading/writing outside buffers.

Bartosz Podrygajlo requested to merge fix-llr-segfault into develop

This provides a testcase for testing LLR functions and a fix for nr_ulsch_16/64/256qam_llr

The testcase tests against reference non-avx implementation on random input data.

Testcases added:

[ RUN      ] test_llr.verify_reference_implementation_16qam
[       OK ] test_llr.verify_reference_implementation_16qam (1 ms)
[ RUN      ] test_llr.test_8_res_16qam
[       OK ] test_llr.test_8_res_16qam (0 ms)
[ RUN      ] test_llr.test_4_res_16qam
[       OK ] test_llr.test_4_res_16qam (0 ms)
[ RUN      ] test_llr.test_5_res_16qam
[       OK ] test_llr.test_5_res_16qam (0 ms)
[ RUN      ] test_llr.no_segmentation_fault_at_12_res_16qam
[       OK ] test_llr.no_segmentation_fault_at_12_res_16qam (0 ms)
[ RUN      ] test_llr.no_segmentation_fault_at_36_res_16qam
[       OK ] test_llr.no_segmentation_fault_at_36_res_16qam (0 ms)
[ RUN      ] test_llr.no_segfault_any_number_of_re_16qam
[       OK ] test_llr.no_segfault_any_number_of_re_16qam (143 ms)
[ RUN      ] test_llr.verify_reference_implementation_64qam
[       OK ] test_llr.verify_reference_implementation_64qam (1 ms)
[ RUN      ] test_llr.test_8_res_64qam
[       OK ] test_llr.test_8_res_64qam (0 ms)
[ RUN      ] test_llr.test_4_res_64qam
[       OK ] test_llr.test_4_res_64qam (0 ms)
[ RUN      ] test_llr.no_segmentation_fault_at_12_res_64qam
[       OK ] test_llr.no_segmentation_fault_at_12_res_64qam (0 ms)
[ RUN      ] test_llr.no_segmentation_fault_at_36_res_64qam
[       OK ] test_llr.no_segmentation_fault_at_36_res_64qam (0 ms)
[ RUN      ] test_llr.no_segfault_any_number_of_re_64qam
[       OK ] test_llr.no_segfault_any_number_of_re_64qam (221 ms)
[ RUN      ] test_llr.verify_reference_implementation_256qam
[       OK ] test_llr.verify_reference_implementation_256qam (1 ms)
[ RUN      ] test_llr.test_8_res_256qam
[       OK ] test_llr.test_8_res_256qam (0 ms)
[ RUN      ] test_llr.test_4_res_256qam
[       OK ] test_llr.test_4_res_256qam (0 ms)
[ RUN      ] test_llr.no_segmentation_fault_at_12_res_256qam
[       OK ] test_llr.no_segmentation_fault_at_12_res_256qam (0 ms)
[ RUN      ] test_llr.no_segmentation_fault_at_36_res_256qam
[       OK ] test_llr.no_segmentation_fault_at_36_res_256qam (0 ms)
[ RUN      ] test_llr.no_segfault_any_number_of_re_256qam
[       OK ] test_llr.no_segfault_any_number_of_re_256qam (289 ms)
[ RUN      ] test_llr.check_2_res_256_qam
[       OK ] test_llr.check_2_res_256_qam (0 ms)

build:

cmake -DENABLE_TESTS=ON -DSANITIZE_ADDRESS=ON ../../ -GNinja

cmake --build . --target test_llr

@lthomas, @francescomani for visibility

Edited by Bartosz Podrygajlo

Merge request reports