1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

mjit.c: prefix "_ruby" to precompiled header too

for consistency and to clarify who created it.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
k0kubun 2018-02-06 16:16:25 +00:00
parent 75eff5002d
commit e31eedbdb8

8
mjit.c
View file

@ -683,6 +683,8 @@ load_func_from_so(const char *so_file, const char *funcname, struct rb_mjit_unit
return func;
}
#define MJIT_TMP_PREFIX "_ruby_mjit_"
/* Compile ISeq in UNIT and return function pointer of JIT-ed code.
It may return NOT_COMPILABLE_JIT_ISEQ_FUNC if something went wrong. */
static mjit_func_t
@ -694,8 +696,8 @@ convert_unit_to_func(struct rb_mjit_unit *unit)
void *func;
double start_time, end_time;
sprint_uniq_filename(c_file, unit->id, "_ruby_mjit", ".c");
sprint_uniq_filename(so_file, unit->id, "_ruby_mjit", ".so");
sprint_uniq_filename(c_file, unit->id, MJIT_TMP_PREFIX, ".c");
sprint_uniq_filename(so_file, unit->id, MJIT_TMP_PREFIX, ".so");
sprintf(funcname, "_mjit%d", unit->id);
f = fopen(c_file, "w");
@ -1171,7 +1173,7 @@ mjit_init(struct mjit_options *opts)
}
init_header_filename();
pch_file = get_uniq_filename(0, "_mjit_h", ".h.gch");
pch_file = get_uniq_filename(0, MJIT_TMP_PREFIX "h", ".h.gch");
if (header_file == NULL || pch_file == NULL) {
mjit_init_p = FALSE;
verbose(1, "Failure in MJIT header file name initialization\n");