mirror of
				https://git.haproxy.org/git/haproxy.git/
				synced 2025-10-26 22:20:59 +01:00 
			
		
		
		
	OPTIM: buffers: align the buffer pool to 64
This struct is used by memcpy() and friends, particularly during the early recv() and send(). By keeping it 64-byte aligned, we let the underlying libs/kernel use optimal operations (e.g. AVX512) for memory copies while right now it's just random (buffers are found to be equally aligned to 32 and 64 in practice).
This commit is contained in:
		
							parent
							
								
									c471de7964
								
							
						
					
					
						commit
						77335f52fc
					
				| @ -32,7 +32,7 @@ int init_buffer() | ||||
| 	int done; | ||||
| 	int i; | ||||
| 
 | ||||
| 	pool_head_buffer = create_pool("buffer", global.tune.bufsize, MEM_F_SHARED|MEM_F_EXACT); | ||||
| 	pool_head_buffer = create_aligned_pool("buffer", global.tune.bufsize, 64, MEM_F_SHARED|MEM_F_EXACT); | ||||
| 	if (!pool_head_buffer) | ||||
| 		return 0; | ||||
| 
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user