Font Size: a A A

A Research On Performance Optimization For Inter-CPU Message In Microkernel Multicore System

Posted on:2020-08-28Degree:MasterType:Thesis
Country:ChinaCandidate:F XueFull Text:PDF
GTID:2428330578463118Subject:Computer Science and Technology
Abstract/Summary:PDF Full Text Request
Although microkernel system has significant advantages on reliability,security and scalability,the system has been suffering from poor performance for a long time since its birth,which is caused mainly by the overhead of messages.Message is the only way for IPC in microkernel system,which is used by the user programs to commu-nicate with the server programs,also used for communication between user programs.Message dilivering is very frequent in microkernel system because it is the only way for IPC,the overhead of message dilivery has an important influence on the performace of whole system.When the sender and the receiver of messages are running on different CPUs,message delivering will cause cache coherence problem,which causes performance loss.Every thread has its own mailbox for saving pending message,the core operation of message dilivery is to copy message from the mailbox of the sender to the receiver,which is took on the CPU running the sender or the receiver.If the sender and the receiver is running on different CPUs,the mailbox is shared by the two CPUs,which is the cause of the cache coherence problem.The scheduler of microkernel system should put threads which have message com-munication on the same CPU to avoid performance loss caused by cache coherence problem.However,this strategy will cause serious load imbalance problem in multi-core system,which incurs new loss of performance.This paper puts forward the LPATH method to reduce inter-CPU messages,which include two ways.First,LPATH implements all server programs using multiple threads and make sure every server thread bind with a CPU,then user thread can olny commu-nicate with the server thread running on the same CPU,which eliminates all the inter-CPU messages related to server programs.Second,LPATH trys to shedule threads that communicate with each other on the same CPU,it can't violate thread load balance or thead-CPU affinity meanwhile.This paper uses a graph partion problem with the spe-cific requirement to model the scheduling optimization problem and gives a solution.Besides.the receiver handles pending messages in the order of the time they comes which is the most common policy in current,this policy may cause that the message sent by a thread with high priority is blocked until the message sent by a thread with low priority is handled,this happens when the message sent by a low priority thread comes first.In other words,this policy causes a priority inversion problem.This paper puts forward the PPATH method to solve the PI problem,PPATH makes the receiver handle the message sent by the thread with a highest priority firstly,it also has the starvation prevention mechanism,in case that the messages sent by low threads wait forever.To sum up,the contribution made by this paper includes following items:1.This paper makes a detailed analysis of the cache coherence problem caused by inter-CPU messages,which dose a damage to the performace of the system.2.This paper puts forward the LPATH method to reduce the performance loss caused by the inter-CPU messages,which effectively cuts down the number of inter-CPU messages in two aspects,message distribution and thread scheduling.3.This paper uses a graph partion problem with the specific requirement to model the scheduling optimization problem,this model can be used in most current microker-nel systems.4.This paper makes a detailed description to the risk that the current message queueing policy took by most microkernel systems may cause priority inversion problem.This paper also gives the PPATH method to solve it.5.This paper implements the LPATH and PPATH in the seL4 system and runs it on the Nvidia tx2 development board.This paper designs experiments to test and verity the effectivity of the LPATH and PPATH.
Keywords/Search Tags:Microkernel, Message, Performance Optimization, Priority Inversion
PDF Full Text Request
Related items