Skip to content

The code generated by the JIT for loading 16 bit and 32 bit constants is inefficient.Β #140683

@markshannon

Description

@markshannon

This affects both x86-64 and AArch64.

Most guard micro-ops are checking against 16 or 32 bit version numbers, so this is an important use case.

The code we generate is too large and, on AArch64, performs extra memory accesses.

Constant x86-64 now x86-64 ideal AArch64 now AArch64 ideal
16 bit 1 10 byte instruction 1 5 byte instruction 2 instructions + 1 memory load 1 instruction
32 bit 1 10 byte instruction 1 5 byte instruction 2 instructions + 1 memory load 2 instructions

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.15new features, bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)performancePerformance or resource usagetopic-JIT

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions