summaryrefslogtreecommitdiff
path: root/yjit_core.h
Commit message (Collapse)AuthorAgeFilesLines
* YJIT code pages refactoring for code GC (#5073)Maxime Chevalier-Boisvert2021-11-041-10/+6
| | | | | | | | | | | | | | | * New code page allocation logic * Fix leaked globals * Fix leaked symbols, yjit asm tests * Make COUNTED_EXIT take a jit argument, so we can eliminate global ocb * Remove extra whitespace * Change block start_pos/end_pos to be pointers instead of uint32_t * Change branch end_pos and start_pos to end_addr, start_addr
* Fix typosNobuyoshi Nakada2021-11-021-1/+1
|
* Put YJIT into a single compilation unitAlan Wu2021-10-201-52/+4
| | | | | | | | | | | | | | | | | | | | | For upstreaming, we want functions we export either prefixed with "rb_" or made static. Historically we haven't been following this rule, so we were "leaking" a lot of symbols as `make leak-globals` would tell us. This change unifies everything YJIT into a single compilation unit, yjit.o, and makes everything unprefixed static to pass `make leak-globals`. This manual "unified build" setup is similar to that of vm.o. Having everything in one compilation unit allows static functions to be visible across YJIT files and removes the need for declarations in headers in some cases. Unnecessary declarations were removed. Other changes of note: - switched to MJIT_SYMBOL_EXPORT_BEGIN which indicates stuff as being off limits for native extensions - the first include of each YJIT file is change to be "internal.h" - undefined MAP_STACK before explicitly redefining it since it collide's with a definition in system headers. Consider renaming?
* Fix changes from rebaseNoah Gibbs2021-10-201-1/+2
|
* Step 2 to remove the global cb/ocb objects.Maxime Chevalier-Boisvert2021-10-201-4/+39
|
* Store block callee_cme in darrayJohn Hawthorn2021-10-201-4/+12
| | | | This allows a block version to have dependencies on multiple CMEs.
* Use callee-saved regs for REG_SP, REG_EP, REG_CFPJohn Hawthorn2021-10-201-6/+4
|
* Move yjit_type_of_value into yjit_core.cJohn Hawthorn2021-10-201-0/+1
|
* Implement verify_ctx for debuggingJohn Hawthorn2021-10-201-0/+2
|
* Introduce ctx_{get,set}_opnd_mappingJohn Hawthorn2021-10-201-0/+11
|
* Rename to ctx_upgrade_opnd_typeJohn Hawthorn2021-10-201-1/+1
|
* Change register definitions to match the entry point calling conventionAaron Patterson2021-10-201-2/+2
| | | | | The JIT entry point passes the CFP as RSI and the EC as RDI. Lets match that so we don't have to shuffle registers around.
* First pass at code page GC object.Maxime Chevalier-Boisvert2021-10-201-0/+4
|
* Add FLONUM detectionJohn Hawthorn2021-10-201-0/+2
|
* Support guards against symbols and integersJohn Hawthorn2021-10-201-0/+1
| | | | This adds guards
* Add concatstrings to yjit codegen (#58)John Hawthorn2021-10-201-1/+5
| | | | | | | | | * Add ETYPE_TRUE and ETYPE_FALSE * Implement checktype * Implement concatstrings * Update deps
* Merge pull request #50 from jhawthorn/detect_typeJohn Hawthorn2021-10-201-0/+1
| | | Detect types from putobject and getinlinecache
* Implement getblockparamproxyAlan Wu2021-10-201-0/+2
| | | | | | | | | | | | | * Implement getblockparamproxy * Parallel runner: wait for timeout thread to terminate after killing Or else the leak cheaker could sees the thread as running and cause test failures in test-tool. * Add a comment, use jne * Comment about where 0x3 comes from
* Malloc branch entries (#112)Maxime Chevalier-Boisvert2021-10-201-7/+14
| | | | | | | | | | | * Malloc branch entries * Add ASM comment for stack overflow check * WIP * Fix branch GC code. Add rb_darray_remove_unordered(). * Fix block end_pos after branch rewriting. Remove dst_patched bits.
* Re-enable local type tracking, until first callMaxime Chevalier-Boisvert2021-10-201-0/+1
|
* Remove unnamed enums because MSVC suxMaxime Chevalier-Boisvert2021-10-201-19/+19
|
* Introduce concept of YJIT instruction operandsMaxime Chevalier-Boisvert2021-10-201-27/+39
|
* YJIT: Fancier opt_getinlinecacheAlan Wu2021-10-201-0/+1
| | | | | | | Make sure `opt_getinlinecache` is in a block all on its own, and invalidate it from the interpreter when `opt_setinlinecache`. It will recompile with a filled cache the second time around. This lets YJIT runs well when the IC for constant is cold.
* Add flag bits to avoid compiling stubs multiple times.Maxime Chevalier-Boisvert2021-10-201-1/+5
| | | | Fixes bug involving ractors and branch stubs.
* Keep track of local types in the contextMaxime Chevalier-Boisvert2021-10-201-0/+2
|
* Add ctcx_stack_push_local()Maxime Chevalier-Boisvert2021-10-201-2/+3
|
* YJIT: adjust branch shape properly when target already existsAlan Wu2021-10-201-1/+1
| | | | | | | | | The old code decides branch->shape based on the write position of the native code block, which is unsound in case the block already exists and no new code is written to the write position. Make this decision with the start address of the target block instead. Also handle when the branch becomes smaller after patching.
* use ctx_stack_push_self()Maxime Chevalier-Boisvert2021-10-201-2/+5
|
* Part 1 of improved type tracking logicMaxime Chevalier-Boisvert2021-10-201-41/+31
|
* WIPMaxime Chevalier-Boisvert2021-10-201-1/+5
|
* Commit WIPMaxime Chevalier-Boisvert2021-10-201-8/+21
|
* First sketch at temp type mappingMaxime Chevalier-Boisvert2021-10-201-0/+69
|
* Get rid of dependency on rb_call_cacheAlan Wu2021-10-201-5/+4
|
* Yjit: rename context structAlan Wu2021-10-201-1/+1
|
* Yet Another Ruby JIT!Jose Narvaez2021-10-201-0/+178
Renaming uJIT to YJIT. AKA s/ujit/yjit/g.