mirror of
				https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
				synced 2025-11-03 09:01:50 -05:00 
			
		
		
		
	modules: Micro-optimisation for rewind_requested paths
Since some devices can be chatty with regards to how often they return from poll(), this adds a PA_UNLIKELY() to all the the rewind_requested checks in our sink modules to make the general case (no rewind was requested) the fast path.
This commit is contained in:
		
							parent
							
								
									29f064aa3d
								
							
						
					
					
						commit
						e5953fb0dd
					
				
					 12 changed files with 12 additions and 12 deletions
				
			
		| 
						 | 
				
			
			@ -1081,7 +1081,7 @@ static void thread_func(void *userdata) {
 | 
			
		|||
 | 
			
		||||
        if (u->sink && PA_SINK_IS_LINKED(u->sink->thread_info.state)) {
 | 
			
		||||
 | 
			
		||||
            if (u->sink->thread_info.rewind_requested)
 | 
			
		||||
            if (PA_UNLIKELY(u->sink->thread_info.rewind_requested))
 | 
			
		||||
                pa_sink_process_rewind(u->sink, 0);
 | 
			
		||||
 | 
			
		||||
            if (pollfd) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue