mirror of
				https://github.com/ruby/ruby.git
				synced 2022-11-09 12:17:21 -05:00 
			
		
		
		
	MJIT is enabled whenever an MJIT header is used
```
$ benchmark-driver -v --rbenv 'before --jit;after --jit' --repeat-count=4 --alternate --output=all benchmark.yml
before --jit: ruby 3.0.0dev (2020-12-22T05:16:39Z master 692af8e8f8) +JIT [x86_64-linux]
after --jit: ruby 3.0.0dev (2020-12-22T06:05:59Z master d2ca23fdbc) +JIT [x86_64-linux]
last_commit=MJIT is enabled whenever an MJIT header is used
Calculating -------------------------------------
                             before --jit           after --jit
Optcarrot 180 frames    86.61115328062763     91.49245232931852 fps
                        90.18653732453176     92.31139517827663
                        91.29817884736318     93.84437713805814
                        92.76118222412521     93.91929147901106
```
			
			
This commit is contained in:
		
							parent
							
								
									95acd3c030
								
							
						
					
					
						commit
						15b81edd86
					
				
					 1 changed files with 5 additions and 1 deletions
				
			
		
							
								
								
									
										6
									
								
								mjit.h
									
										
									
									
									
								
							
							
						
						
									
										6
									
								
								mjit.h
									
										
									
									
									
								
							| 
						 | 
				
			
			@ -187,7 +187,11 @@ mjit_exec(rb_execution_context_t *ec)
 | 
			
		|||
 | 
			
		||||
void mjit_child_after_fork(void);
 | 
			
		||||
 | 
			
		||||
#  ifdef MJIT_HEADER
 | 
			
		||||
#define mjit_enabled true
 | 
			
		||||
#  else // MJIT_HEADER
 | 
			
		||||
extern bool mjit_enabled;
 | 
			
		||||
#  endif // MJIT_HEADER
 | 
			
		||||
VALUE mjit_pause(bool wait_p);
 | 
			
		||||
VALUE mjit_resume(void);
 | 
			
		||||
void mjit_finish(bool close_handle_p);
 | 
			
		||||
| 
						 | 
				
			
			@ -207,7 +211,7 @@ static inline void mjit_remove_class_serial(rb_serial_t class_serial){}
 | 
			
		|||
static inline VALUE mjit_exec(rb_execution_context_t *ec) { return Qundef; /* unreachable */ }
 | 
			
		||||
static inline void mjit_child_after_fork(void){}
 | 
			
		||||
 | 
			
		||||
#define mjit_enabled 0
 | 
			
		||||
#define mjit_enabled false
 | 
			
		||||
static inline VALUE mjit_pause(bool wait_p){ return Qnil; } // unreachable
 | 
			
		||||
static inline VALUE mjit_resume(void){ return Qnil; } // unreachable
 | 
			
		||||
static inline void mjit_finish(bool close_handle_p){}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue