# Assessing the Cloud-RAN in the Linux Kernel: Sharing Computing and Network Resources
## 4 Assessing the vBBU Performance in the Linux Kernel
### Results and Discussion
#### 4.2.2 CPU Management Strategies
In scenarios such as noA and IA, where the bit rate is low, preventing the activation of the NAPI mechanism, each packet is processed using Hard-IRQs, leading to unpredictable latency. The outliers observed in these scenarios are indicative of the unpredictable delays, potentially caused by factors like livelocks [75]. Notably, in noA, the outliers represent 9% of the data, while, in noA-BT, where NAPI is enabled due to the high packet rate flow of BT, outliers account for only 0.3% of the data. Similarly, in IA, outliers represent 11% of the data, while, in IA-BT, with NAPI enabled, outliers represent 6% of the data. This observation underscores the effectiveness of NAPI in mitigating unpredictable latency induced by per-packet Hard-IRQ processing. Certainly, these results suggest that allocating CPU affinity to the NIC enhances the determinism of packet processing in the RT-Kernel. Now, the question is whether the vBBU would benefit from allocating CPU affinity to the NIC port used in the Backhaul. To answer this question, we next evaluate the scheduling latency of vBBU threads while incorporating IA into the CPU affinity allocation scenarios defined for the vBBU: IA-WA and IA-TA. Table 4 presents the scheduling latency events of vBBU threads under CPU affinity allocations IA-WA and IA-TA. As this analysis centers on adopting CPU affinity allocation to the NIC port used in the Backhaul, we specifically evaluate the Kernel scenario, involving the sharing of computing resources with Kernel thread processing generated by incoming packets. These results indicate that the vBBU benefits from allocating CPU affinity to the Backhaul port in mitigating the impact of packet processing in the Linux RT-Kernel. In both scenarios, IA-WA and IA-TA, scheduling latency events of vBBU RT threads shows an increase in the 0-1 interval compared to the results reported in Table 3, where no CPU affinity was allocated to the NIC. In other words, adopting IA to the Backhaul port helps alleviate the impact on the vBBU RT threads scheduling latency caused by packet processing. As mentioned earlier, vBBU RT threads, namely, ru-thread and lte-softmodem, account for a significant portion of the CPU time allocated for the vBBU. In the configuration with both fixed CPU affinity per thread and CPU affinity to the NIC, as, in IA-TA, RT threads ru-thread and lte-softmodem experience lower scheduling latency compared to IA-WA. However, the impact on non-RT threads is the opposite. In IA-WA, non-RT threads can receive CPU time on any of the CPUs in \(C_{W}\), resulting in lower scheduling latency for \begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline \multirow{2}{*}{**Thread**} & \multicolumn{2}{c}{**0-1 (microseconds)**} & \multicolumn{2}{c}{**2-3 (microseconds)**} & \multicolumn{2}{c}{**4-7 (microseconds)**} & \multicolumn{2}{c}{**8-15 (microseconds)**} \\ \cline{2-9}  & \multicolumn{2}{c}{**Kernel**} & \multicolumn{2}{c}{**Kernel**} & \multicolumn{2}{c}{**Kernel**} & \multicolumn{2}{c}{**Kernel**} \\ \cline{2-9}  & **IA-WA** & **IA-TA** & **IA-WA** & **IA-TA** & **IA-WA** & **IA-TA** & **IA-WA** & **IA-TA** \\ \hline ru-thread & 89.4 & 90.8 & 6.5 & 4.5 & 0.4 & 0.34 & 3.5 & 4.3 \\ \hline lte-softmodem & 81 & 93.4 & 7.2 & 5.4 & 0.8 & 0.2 & 1.5 & 0.3 \\ \hline fep\_processing & 86.3 & 80.2 & 11.2 & 17.7 & 0.6 & 0.8 & 0.8 & 1.2 \\ \hline feptx\_thread & 72.9 & 75.9 & 15.6 & 23.4 & 1.2 & 0.4 & 1.4 & 0.1 \\ \hline TASK\_GTP & 74.6 & 0.1 & 9.3 & 56.4 & 4.7 & 32.6 & 2.2 & 4.5 \\ \hline UDP\_TASK & 62.5 & 49.4 & 6.2 & 2.7 & 23 & 32.5 & 3.5 & 14.2 \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Scheduling latency of vBBU’s threads (percentage). Evaluated scenarios: (i) Kernel (sharing computing resources with collocated Kernel thread processing generated by incoming packets)—CPU affinity allocation: IA-WA vs. IA-TA. non-RT threads compared to IA-TA. Consequently, in IA-TA, latency events of non-RT threads even shift beyond the 2-3 microsecond range.