diff options
author | Takashi Kokubun <takashikkbn@gmail.com> | 2023-03-06 23:15:30 -0800 |
---|---|---|
committer | Takashi Kokubun <takashikkbn@gmail.com> | 2023-03-06 23:44:01 -0800 |
commit | 2e875549a934fa04b7939810fa0d8a2762702aaa (patch) | |
tree | 116b99056f810d48359ac6fa6a3b06e9ddc65c05 /ruby.c | |
parent | eaccdc1941304d6273397b21c25213174d892185 (diff) |
s/MJIT/RJIT/
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/7462
Diffstat (limited to 'ruby.c')
-rw-r--r-- | ruby.c | 34 |
1 files changed, 17 insertions, 17 deletions
@@ -118,7 +118,7 @@ void rb_warning_category_update(unsigned int mask, unsigned int bits); enum feature_flag_bits { EACH_FEATURES(DEFINE_FEATURE, COMMA), feature_debug_flag_first, -#if defined(MJIT_FORCE_ENABLE) || !USE_YJIT +#if defined(RJIT_FORCE_ENABLE) || !USE_YJIT DEFINE_FEATURE(jit) = feature_mjit, #else DEFINE_FEATURE(jit) = feature_yjit, @@ -213,7 +213,7 @@ cmdline_options_init(ruby_cmdline_options_t *opt) opt->ext.enc.index = -1; opt->intern.enc.index = -1; opt->features.set = DEFAULT_FEATURES; -#ifdef MJIT_FORCE_ENABLE /* to use with: ./configure cppflags="-DMJIT_FORCE_ENABLE" */ +#ifdef RJIT_FORCE_ENABLE /* to use with: ./configure cppflags="-DRJIT_FORCE_ENABLE" */ opt->features.set |= FEATURE_BIT(mjit); #elif defined(YJIT_FORCE_ENABLE) opt->features.set |= FEATURE_BIT(yjit); @@ -286,7 +286,7 @@ usage(const char *name, int help, int highlight, int columns) M("-W[level=2|:category]", "", "set warning level; 0=silence, 1=medium, 2=verbose"), M("-x[directory]", "", "strip off text before #!ruby line and perhaps cd to directory"), M("--jit", "", "enable JIT for the platform, same as " PLATFORM_JIT_OPTION), -#if USE_MJIT +#if USE_RJIT M("--mjit", "", "enable C compiler-based JIT compiler (experimental)"), #endif #if USE_YJIT @@ -321,7 +321,7 @@ usage(const char *name, int help, int highlight, int columns) M("syntax_suggest", "", "syntax_suggest (default: "DEFAULT_RUBYGEMS_ENABLED")"), M("rubyopt", "", "RUBYOPT environment variable (default: enabled)"), M("frozen-string-literal", "", "freeze all string literals (default: disabled)"), -#if USE_MJIT +#if USE_RJIT M("mjit", "", "C compiler-based JIT compiler (default: disabled)"), #endif #if USE_YJIT @@ -332,7 +332,7 @@ usage(const char *name, int help, int highlight, int columns) M("deprecated", "", "deprecated features"), M("experimental", "", "experimental features"), }; -#if USE_MJIT +#if USE_RJIT extern const struct ruby_opt_message mjit_option_messages[]; #endif #if USE_YJIT @@ -370,8 +370,8 @@ usage(const char *name, int help, int highlight, int columns) printf("%s""Warning categories:%s\n", sb, se); for (i = 0; i < numberof(warn_categories); ++i) SHOW(warn_categories[i]); -#if USE_MJIT - printf("%s""MJIT options (experimental):%s\n", sb, se); +#if USE_RJIT + printf("%s""RJIT options (experimental):%s\n", sb, se); for (i = 0; mjit_option_messages[i].str; ++i) SHOW(mjit_option_messages[i]); #endif @@ -957,7 +957,7 @@ feature_option(const char *str, int len, void *arg, const unsigned int enable) goto found; } if (NAME_MATCH_P("all", str, len)) { - // YJIT and MJIT cannot be enabled at the same time. We enable only one for --enable=all. + // YJIT and RJIT cannot be enabled at the same time. We enable only one for --enable=all. mask &= ~feature_jit_mask | FEATURE_BIT(jit); goto found; } @@ -1486,19 +1486,19 @@ proc_options(long argc, char **argv, ruby_cmdline_options_t *opt, int envopt) ruby_verbose = Qtrue; } else if (strcmp("jit", s) == 0) { -#if !USE_MJIT +#if !USE_RJIT rb_warn("Ruby was built without JIT support"); #else FEATURE_SET(opt->features, FEATURE_BIT(jit)); #endif } else if (is_option_with_optarg("mjit", '-', true, false, false)) { -#if USE_MJIT +#if USE_RJIT extern void mjit_setup_options(const char *s, struct mjit_options *mjit_opt); FEATURE_SET(opt->features, FEATURE_BIT(mjit)); mjit_setup_options(s, &opt->mjit); #else - rb_warn("MJIT support is disabled."); + rb_warn("RJIT support is disabled."); #endif } else if (is_option_with_optarg("yjit", '-', true, false, false)) { @@ -1611,8 +1611,8 @@ ruby_opt_init(ruby_cmdline_options_t *opt) rb_warning_category_update(opt->warn.mask, opt->warn.set); -#if USE_MJIT - // rb_call_builtin_inits depends on RubyVM::MJIT.enabled? +#if USE_RJIT + // rb_call_builtin_inits depends on RubyVM::RJIT.enabled? if (opt->mjit.on) mjit_enabled = true; if (opt->mjit.stats) @@ -1625,8 +1625,8 @@ ruby_opt_init(ruby_cmdline_options_t *opt) ruby_init_prelude(); // Initialize JITs after prelude because JITing prelude is typically not optimal. -#if USE_MJIT - // Also, mjit_init is safe only after rb_call_builtin_inits() defines RubyVM::MJIT::Compiler. +#if USE_RJIT + // Also, mjit_init is safe only after rb_call_builtin_inits() defines RubyVM::RJIT::Compiler. if (opt->mjit.on) mjit_init(&opt->mjit); #endif @@ -1935,11 +1935,11 @@ process_options(int argc, char **argv, ruby_cmdline_options_t *opt) #endif } if (MULTI_BITS_P(FEATURE_SET_BITS(opt->features) & feature_jit_mask)) { - rb_warn("MJIT and YJIT cannot both be enabled at the same time. Exiting"); + rb_warn("RJIT and YJIT cannot both be enabled at the same time. Exiting"); return Qfalse; } -#if USE_MJIT +#if USE_RJIT if (FEATURE_SET_P(opt->features, mjit)) { opt->mjit.on = true; // set opt->mjit.on for Init_ruby_description() and calling mjit_init() } |