equal
deleted
inserted
replaced
413 stop_compilation = 0, |
413 stop_compilation = 0, |
414 run_compilation = 1, |
414 run_compilation = 1, |
415 shutdown_compilaton = 2 |
415 shutdown_compilaton = 2 |
416 }; |
416 }; |
417 |
417 |
|
418 static jint get_compilation_activity_mode() { return _should_compile_new_jobs; } |
418 static bool should_compile_new_jobs() { return UseCompiler && (_should_compile_new_jobs == run_compilation); } |
419 static bool should_compile_new_jobs() { return UseCompiler && (_should_compile_new_jobs == run_compilation); } |
419 static bool set_should_compile_new_jobs(jint new_state) { |
420 static bool set_should_compile_new_jobs(jint new_state) { |
420 // Return success if the current caller set it |
421 // Return success if the current caller set it |
421 jint old = Atomic::cmpxchg(new_state, &_should_compile_new_jobs, 1-new_state); |
422 jint old = Atomic::cmpxchg(new_state, &_should_compile_new_jobs, 1-new_state); |
422 return (old == (1-new_state)); |
423 return (old == (1-new_state)); |