性能 #2574
下行代码走读发现的问题,进行优化
0%
描述
1.msg->data = static_cast<char*>(mem_alloc(m_buff_len)); udp上行和下行和信令面,根据实际情况分配
2.char* temp = (char*)msg->data; temp[nbytes] = '\0'; 可以删除
3.message_t* msg = new message_t();在udp_rx_ul线程内是否可以不用new
4.pdcp_dl_data_delivery_status_ind* pdcp_dl_data_delivery_status_ind =
new(gnb::mem_pools::USER_PLANE_UL_MSG_POOL_ID) gnb::pdcp_dl_data_delivery_status_ind(rx_rb->get_opaque_mgr_id()); 不用new
5.if (egtpu_data_rx_params.pdu_info[pdu_idx].nr_ran_container_ext_hdr.size())没有break;
6.pdcp_dl_data_delivery_status_ind* pdcp_dl_data_delivery_status_ind =
new(gnb::mem_pools::USER_PLANE_UL_MSG_POOL_ID) gnb::pdcp_dl_data_delivery_status_ind(rx_rb->get_opaque_mgr_id());
gnb::pdcp_dl_data_delivery_status_ind_info& dl_data_delivery_status_ind_info =
pdcp_dl_data_delivery_status_ind->get_msg(); 和发送放到if (egtpu_data_rx_params.pdu_info[pdu_idx].nr_ran_container_ext_hdr.size())里面
7.process_nrup_data处理ddds数据
8.rx_rb->get_rb_state_machine().process_event(rx_rb, rx_inst,
pdcp_rx_rb::rx_event::EVENT_RB_DATA_RX_IND_RECEIVED, static_cast<void*>(&egtpu_data_rx_params)); 可以写成多态,暂时不实现
9.将m_shm_mgr设置到udp_rx_ul中,不要作为参数传入到run中udp_rx_ul->run(&m_shm_mgr);