From 0dc3bba6f2b2b1b23e1ec9dd2ec29f932c292db0 Mon Sep 17 00:00:00 2001 From: Jean Boussier Date: Tue, 24 Aug 2021 12:32:07 +0200 Subject: Allow to compile with --yjit-stats support but not the full RUBY_DEBUG RUBY_DEBUG have a very significant performance overhead. Enough that YJIT with RUBY_DEBUG is noticeably slower than the interpreter without RUBY_DEBUG. This makes it hard to collect yjit-stats in production environments. By allowing to collect JIT statistics without the RUBy_DEBUG overhead, I hope to make such use cases smoother. --- yjit_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'yjit_core.c') diff --git a/yjit_core.c b/yjit_core.c index 519da41230..ee3914acc6 100644 --- a/yjit_core.c +++ b/yjit_core.c @@ -522,7 +522,7 @@ add_block_version(blockid_t blockid, block_t* block) rb_bug("allocation failed"); } -#if RUBY_DEBUG +#if YJIT_STATS // First block compiled for this iseq yjit_runtime_counters.compiled_iseq_count++; #endif -- cgit v1.2.3