diff options
author | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-06-30 13:40:18 +0200 |
---|---|---|
committer | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-07-07 10:29:12 +0200 |
commit | 16c6ecc3657f62728845764731c189b3cb8daca2 (patch) | |
tree | 58c2b0747081ef600a4fe049a124179dc61e5360 /tests/alloc | |
parent | 5f494b8415ff4e5c9bf323ea7bc8326ad423c7ae (diff) |
alloc: Skip common TS without free USF when rating
Currently the search of the "best" slot combination is done
separately from the UL slot selection, which can lead to an
allocation failure due to USF exhaustion even if another combination
had been possible.
This commit reduces the probability for this event by skipping UL
slots without free USF while calculation the capacity.
Note that the implementation is rather inefficient which will be
fixed by the following commits.
Sponsored-by: On-Waves ehf
Diffstat (limited to 'tests/alloc')
-rw-r--r-- | tests/alloc/AllocTest.cpp | 12 | ||||
-rw-r--r-- | tests/alloc/AllocTest.err | 12 | ||||
-rw-r--r-- | tests/alloc/AllocTest.ok | 72 |
3 files changed, 63 insertions, 33 deletions
diff --git a/tests/alloc/AllocTest.cpp b/tests/alloc/AllocTest.cpp index 10352cf..874f907 100644 --- a/tests/alloc/AllocTest.cpp +++ b/tests/alloc/AllocTest.cpp @@ -565,18 +565,18 @@ static void test_successive_allocation() test_successive_allocation(alloc_algorithm_a, 1, 1, TEST_MODE_UL_AND_DL, 32, "algorithm A (UL and DL)"); test_successive_allocation(alloc_algorithm_b, 10, 10, TEST_MODE_UL_AND_DL, - 30, "algorithm B class 10 (UL and DL)"); + 32, "algorithm B class 10 (UL and DL)"); test_successive_allocation(alloc_algorithm_b, 12, 12, TEST_MODE_UL_AND_DL, - 30, "algorithm B class 12 (UL and DL)"); + 32, "algorithm B class 12 (UL and DL)"); test_successive_allocation(alloc_algorithm_b, 1, 12, TEST_MODE_UL_AND_DL, 32, "algorithm B class 1-12 (UL and DL)"); test_successive_allocation(alloc_algorithm_b, 1, 29, TEST_MODE_UL_AND_DL, - 27, "algorithm B class 1-29 (UL and DL)"); + 32, "algorithm B class 1-29 (UL and DL)"); test_successive_allocation(alloc_algorithm_a, 1, 1, TEST_MODE_DL_AND_UL, 32, "algorithm A (DL and UL)"); test_successive_allocation(alloc_algorithm_b, 10, 10, TEST_MODE_DL_AND_UL, - 15, "algorithm B class 10 (DL and UL)"); + 32, "algorithm B class 10 (DL and UL)"); test_successive_allocation(alloc_algorithm_a, 1, 1, TEST_MODE_DL_AFTER_UL, 32, "algorithm A (DL after UL)"); @@ -586,12 +586,12 @@ static void test_successive_allocation() test_successive_allocation(alloc_algorithm_a, 1, 1, TEST_MODE_UL_AFTER_DL, 32, "algorithm A (UL after DL)"); test_successive_allocation(alloc_algorithm_b, 10, 10, TEST_MODE_UL_AFTER_DL, - 30, "algorithm B class 10 (UL after DL)"); + 32, "algorithm B class 10 (UL after DL)"); test_successive_allocation(alloc_algorithm_a, 1, 1, TEST_MODE_UL_ONLY, 32, "algorithm A (UL only)"); test_successive_allocation(alloc_algorithm_b, 10, 10, TEST_MODE_UL_ONLY, - 30, "algorithm B class 10 (UL only)"); + 32, "algorithm B class 10 (UL only)"); test_successive_allocation(alloc_algorithm_a, 1, 1, TEST_MODE_DL_ONLY, 32, "algorithm A (DL ONLY)"); diff --git a/tests/alloc/AllocTest.err b/tests/alloc/AllocTest.err index 49ae154..af9b134 100644 --- a/tests/alloc/AllocTest.err +++ b/tests/alloc/AllocTest.err @@ -3,17 +3,17 @@ No TFI available. No TFI available. - Failed to allocate a TS, no USF available No TFI available. -No USF available -No USF available No TFI available. -No USF available No TFI available. -No USF available No TFI available. No TFI available. No TFI available. -No USF available No TFI available. -No USF available +No TFI available. +No TFI available. +No TFI available. +No TFI available. +No TFI available. +No TFI available. No TFI available. No TFI available. diff --git a/tests/alloc/AllocTest.ok b/tests/alloc/AllocTest.ok index 8e9620a..cfd0441 100644 --- a/tests/alloc/AllocTest.ok +++ b/tests/alloc/AllocTest.ok @@ -8649,11 +8649,13 @@ Going to test assignment with many TBF, algorithm B class 10 (UL and DL) TBF[23] class 10 reserves .....DDC TBF[24] class 10 reserves ...DCD.. TBF[25] class 10 reserves .....DCD - TBF[26] class 10 reserves ...CD... - TBF[27] class 10 reserves .....DDC - TBF[28] class 10 reserves ...CD... - TBF[29] class 10 reserves ...DDC.. - Successfully allocated 30 UL TBFs + TBF[26] class 10 reserves ...DDCD. + TBF[27] class 10 reserves ...CD... + TBF[28] class 10 reserves .....DDC + TBF[29] class 10 reserves ...CD... + TBF[30] class 10 reserves ...CD... + TBF[31] class 10 reserves ...CD... + Successfully allocated 32 UL TBFs Going to test assignment with many TBF, algorithm B class 12 (UL and DL) TBF[0] class 12 reserves ...DDCD. TBF[1] class 12 reserves .....DCD @@ -8681,11 +8683,13 @@ Going to test assignment with many TBF, algorithm B class 12 (UL and DL) TBF[23] class 12 reserves .....DDC TBF[24] class 12 reserves ...DCD.. TBF[25] class 12 reserves .....DCD - TBF[26] class 12 reserves ...CD... - TBF[27] class 12 reserves .....DDC + TBF[26] class 12 reserves ...DDCD. + TBF[27] class 12 reserves ....DDDC TBF[28] class 12 reserves ...CD... - TBF[29] class 12 reserves ...DDC.. - Successfully allocated 30 UL TBFs + TBF[29] class 12 reserves ...CD... + TBF[30] class 12 reserves ...CD... + TBF[31] class 12 reserves ...CD... + Successfully allocated 32 UL TBFs Going to test assignment with many TBF, algorithm B class 1-12 (UL and DL) TBF[0] class 1 reserves ...C.... TBF[1] class 2 reserves ....DC.. @@ -8748,7 +8752,12 @@ Going to test assignment with many TBF, algorithm B class 1-29 (UL and DL) TBF[24] class 25 reserves ....DDCD TBF[25] class 26 reserves ...DCDD. TBF[26] class 27 reserves ....DCDD - Successfully allocated 27 UL TBFs + TBF[27] class 28 reserves ...DDDDC + TBF[28] class 29 reserves ...DDDDC + TBF[29] class 1 reserves ...C.... + TBF[30] class 2 reserves ......DC + TBF[31] class 3 reserves ...C.... + Successfully allocated 32 UL TBFs Going to test assignment with many TBF, algorithm A (DL and UL) TBF[0] class 1 reserves ...C.... TBF[1] class 1 reserves ....C... @@ -8799,7 +8808,24 @@ Going to test assignment with many TBF, algorithm B class 10 (DL and UL) TBF[12] class 10 reserves ...DCD.. TBF[13] class 10 reserves .....DCD TBF[14] class 10 reserves ...DCD.. - Successfully allocated 15 UL TBFs + TBF[15] class 10 reserves ...DDCD. + TBF[16] class 10 reserves ...DDCD. + TBF[17] class 10 reserves ...DDCD. + TBF[18] class 10 reserves ...DDCD. + TBF[19] class 10 reserves ...DDCD. + TBF[20] class 10 reserves ...DDCD. + TBF[21] class 10 reserves .....DDC + TBF[22] class 10 reserves .....DDC + TBF[23] class 10 reserves .....DDC + TBF[24] class 10 reserves .....DDC + TBF[25] class 10 reserves .....DDC + TBF[26] class 10 reserves ...CD... + TBF[27] class 10 reserves .....DDC + TBF[28] class 10 reserves ...CD... + TBF[29] class 10 reserves ...CD... + TBF[30] class 10 reserves .....DDC + TBF[31] class 10 reserves ...CD... + Successfully allocated 32 UL TBFs Going to test assignment with many TBF, algorithm A (DL after UL) TBF[0] class 1 reserves ...C.... TBF[1] class 1 reserves ....C... @@ -8929,11 +8955,13 @@ Going to test assignment with many TBF, algorithm B class 10 (UL after DL) TBF[23] class 10 reserves .......U TBF[24] class 10 reserves ....U... TBF[25] class 10 reserves ......U. - TBF[26] class 10 reserves ...U.... - TBF[27] class 10 reserves .......U - TBF[28] class 10 reserves ...U.... - TBF[29] class 10 reserves .....U.. - Successfully allocated 30 UL TBFs + TBF[26] class 10 reserves .....U.. + TBF[27] class 10 reserves ...U.... + TBF[28] class 10 reserves .......U + TBF[29] class 10 reserves ...U.... + TBF[30] class 10 reserves ...U.... + TBF[31] class 10 reserves ...U.... + Successfully allocated 32 UL TBFs Going to test assignment with many TBF, algorithm A (UL only) TBF[0] class 1 reserves ...U.... TBF[1] class 1 reserves ....U... @@ -8995,11 +9023,13 @@ Going to test assignment with many TBF, algorithm B class 10 (UL only) TBF[23] class 10 reserves .......U TBF[24] class 10 reserves ....U... TBF[25] class 10 reserves ......U. - TBF[26] class 10 reserves ...U.... - TBF[27] class 10 reserves .......U - TBF[28] class 10 reserves ...U.... - TBF[29] class 10 reserves .....U.. - Successfully allocated 30 UL TBFs + TBF[26] class 10 reserves .....U.. + TBF[27] class 10 reserves ...U.... + TBF[28] class 10 reserves .......U + TBF[29] class 10 reserves ...U.... + TBF[30] class 10 reserves ...U.... + TBF[31] class 10 reserves ...U.... + Successfully allocated 32 UL TBFs Going to test assignment with many TBF, algorithm A (DL ONLY) TBF[0] class 1 reserves ...C.... TBF[1] class 1 reserves ....C... |