зеркало из https://github.com/github/ruby.git
MJIT: Change default --mjit-max-cache back to 100
These days we benchmark MJIT using yjit-bench. The warmup duration in yjit-bench is very short, so compiling many methods comes at a cost even while it's actually optimal for MJIT to compile everything / tens of thousands of methods once it reaches the peak performance. yjit-bench doesn't necessarily represent the peak performance on production. It measures the performance of Ruby 30~60s after boot. If your JIT takes more than 1 minute to warm up, there's no way for the JIT to make the numbers good on yjit-bench. Until we make MJIT's compilation much faster, we don't afford compiling 10,000 methods on yjit-bench. This change alone makes MJIT's benchmark number on railsbench 2x better :p
This commit is contained in:
Родитель
3c16f33ffd
Коммит
ac4d00df82
1
NEWS.md
1
NEWS.md
|
@ -445,6 +445,7 @@ The following deprecated APIs are removed.
|
||||||
* As a result, Microsoft Visual Studio (MSWIN) is no longer supported.
|
* As a result, Microsoft Visual Studio (MSWIN) is no longer supported.
|
||||||
* MinGW is no longer supported. [[Feature #18824]]
|
* MinGW is no longer supported. [[Feature #18824]]
|
||||||
* Rename `--mjit-min-calls` to `--mjit-call-threshold`.
|
* Rename `--mjit-min-calls` to `--mjit-call-threshold`.
|
||||||
|
* Change default `--mjit-max-cache` back from 10000 to 100.
|
||||||
|
|
||||||
## Static analysis
|
## Static analysis
|
||||||
|
|
||||||
|
|
2
mjit.c
2
mjit.c
|
@ -1626,7 +1626,7 @@ system_tmpdir(void)
|
||||||
// Minimum value for JIT cache size.
|
// Minimum value for JIT cache size.
|
||||||
#define MIN_CACHE_SIZE 10
|
#define MIN_CACHE_SIZE 10
|
||||||
// Default permitted number of units with a JIT code kept in memory.
|
// Default permitted number of units with a JIT code kept in memory.
|
||||||
#define DEFAULT_MAX_CACHE_SIZE 10000
|
#define DEFAULT_MAX_CACHE_SIZE 100
|
||||||
// A default threshold used to add iseq to JIT.
|
// A default threshold used to add iseq to JIT.
|
||||||
#define DEFAULT_CALL_THRESHOLD 10000
|
#define DEFAULT_CALL_THRESHOLD 10000
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче