Skip to content

ZJIT: Stop running trampolines and stubs through full LIR backend #963

@tekknolagi

Description

@tekknolagi

We have two different ways of generating code:

  • Ruby->HIR->LIR->machine code
  • LIR->machine code

They have very different needs. The former needs a register allocator, linearization, etc. The latter is often just writing one or two instructions into a buffer.

We should not pay for the full LIR pipeline cost if all we are doing is writing out a jump instruction somewhere. Additionally, we should have finer-grained control over when and where we do mprotect and icache coherence stuff.

ruby#16563 is a partial split into a new interface for sketching purposes but it's possible we should have a Compiler layer over the existing Assembler and just let Assembler be lower-level.

Thoughts?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions