mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 18:12:43 +00:00 
			
		
		
		
	 f7f0195fae
			
		
	
	
		f7f0195fae
		
	
	
	
	
		
			
			LibMain is dynamically linked in every binary. This results in a slightly slower load time. In the past people have pegged this at 0.7 ms on some hardware. This change makes it statically linked and eliminates 0.6 ms of run-time on my machine. This is tested by running a script which just executed `/bin/true` in a loop 10,000 times. Before this patch it reliably executed in ~90,000 ms. After this patch it is ~84,000 ms. This is a speed up of 6,000 ms over 10,000 executions, or 0.6 ms per execution.
		
			
				
	
	
		
			6 lines
		
	
	
	
		
			98 B
		
	
	
	
		
			CMake
		
	
	
	
	
	
			
		
		
	
	
			6 lines
		
	
	
	
		
			98 B
		
	
	
	
		
			CMake
		
	
	
	
	
	
| set(SOURCES
 | |
|     Main.cpp
 | |
| )
 | |
| 
 | |
| serenity_lib_static(LibMain main)
 | |
| target_link_libraries(LibMain LibC)
 |