Skip to content

Optimize case === dispatch for core types #9167

@headius

Description

@headius

We can optimize case/when dispatch of === for core types when we know that the method has not been redefined. This one came along back in Ruby 2.3: ruby/ruby@4ebab10

Relates to #9123 for checking the overrides. If we can eliminate the need for === deoptimization (pessimistically to support Regexp matches setting $~) we could see a large improvement in the performance of methods that contain case/when.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions