aboutsummaryrefslogtreecommitdiffstats
path: root/mjit_worker.c
Commit message (Collapse)AuthorAgeFilesLines
* mjit_worker.c: revert r64322 and r64323k0kubun2018-08-181-12/+5
| | | | | | | | | | | | I gave up to introduce the optimization that skips pc motion by checking C code's line number. The same code can often be shared by multiple program counters and it's so hard to achieve the optimization in MJIT's architecture. Reverting to improve performance by removing -g1 and to remove so file when it becomes not necessary. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64424 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Makefile.in: drop MJIT_DLDFLAGS_NOCOMPRESSk0kubun2018-08-131-3/+0
| | | | | | which is obsoleted by r64331 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64335 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* configure.ac: MJIT_DLDFLAGS_NOCOMPRESSk0kubun2018-08-121-1/+1
| | | | | | | | | | | | | | is configured now, to force -Wl,--compress-debug-sections=no for MJIT only when the option is used in MJIT_DLDFLAGS. This needs to be done in configure.ac to resolve build failure like https://travis-ci.org/ruby/ruby/builds/415120662. Makefile.in: define it in mjit_config.h mjit_worker.c: replace hard-coded flag to MJIT_DLDFLAGS_NOCOMPRESS git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64325 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: lazily delete so filek0kubun2018-08-121-20/+20
| | | | | | | | | on ELF. I need symbol name and line number to lazily create program counter for optimization on ELF binary. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64323 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: allow showing line numberk0kubun2018-08-121-1/+10
| | | | | | | | | on addr2line.c, if --jit-save-temps is specified. I'm going to use the line number to lazily create program counter to improve the performance degraded in r64283. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64322 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: remove redundant cast for calloc/allocak0kubun2018-08-111-8/+8
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64305 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: handle calloc failurek0kubun2018-08-111-0/+6
| | | | | | | | Unlike ZALLOC, it's not automatically handled. mjit.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64304 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: never trigger GC on MJIT workerk0kubun2018-08-111-3/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64302 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: don't use ruby_strdupk0kubun2018-08-111-3/+12
| | | | | | | | on MJIT worker. That may trigger GC. And handled strdup failure instead. mjit_compile.c: update comment about GC git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64301 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: share MJIT warning logick0kubun2018-08-111-19/+28
| | | | | | | | as mjit_warning(). mjit.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64298 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: resurrect more static declarationsk0kubun2018-08-111-32/+28
| | | | | | | | and remove old mjit_ prefixes again. mjit.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64292 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: reorder functions and variablesk0kubun2018-08-111-133/+129
| | | | | | | | so that related things are placed closely. Sorry for mixing them in previous commits... git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64291 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit.c: make some variables static againk0kubun2018-08-111-72/+95
| | | | | | | | and remove redundant mjit_ prefixes. mjit_worker.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64290 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit.c: include mjit_worker.ck0kubun2018-08-111-1/+238
| | | | | | | | | | | | | | | instead of linking functions with mjit_worker.o. In the r64285's structure, we needed to publish some variables with mjit_ prefix. But ideally those variables should be completely private in mjit.o (or old mjit_worker.o), and it was hard. So I chose an approach similar to vm*.c for mjit.c and mjit_worker.c. I believe mjit_compile.c is still nice to be separated. After this commit, I'll remove the mjit_ prefix again... git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64289 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit.c: exclude mjit_valid_class_serial_pk0kubun2018-08-111-2/+13
| | | | | | | | from mjit.c because it's executed only on MJIT worker thread. Instead of that, `valid_class_serials` is shared with mjit_ prefix. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64288 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: prefix mjit_ to pch_statusk0kubun2018-08-111-6/+14
| | | | | | | | | | which was just forgotten. mjit.c: ditto mjit_internal.h: moved some macros only used by mjit_worker.c to it. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64287 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: carve out worker-related codek0kubun2018-08-111-0/+896
The motivation of this change is to make sure rb_funcall or GC-related functions are not called on worker-related code. Currently such functions are used in some places and I believe it's partly because it's hard to identify which part is called on MJIT worker thread. Now, mjit.c is safe to use them but we know we need to safely deal with mjit_compile.c, mjit_worker.c and mjit_internal.h. mjit_compile.c: update the comment about it git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64285 b2dd03c8-39d4-4d8f-98ff-823fe69b080e