Skip to content

Conversation

@vtjnash
Copy link
Member

@vtjnash vtjnash commented Aug 4, 2024

Reverts #55124 as this turns out to hurt performance quite a bit

Closes #55374

@giordano giordano added performance Must go faster revert This reverts a previously merged PR. collections Data structures holding multiple items, e.g. sets labels Aug 4, 2024
ntuple(Val{N}()) do i
t[end+1-i]
end::NTuple
end
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you leave this part in? It's just an unconditional type assert, so it shouldn't cause any harm.

Copy link
Member

@KristofferC KristofferC Aug 6, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's get back to a known good state and we can re-add this if it is shown with the benchmarks the regressed to be ok.

@KristofferC KristofferC merged commit 0717a94 into master Aug 6, 2024
@KristofferC KristofferC deleted the revert-55124-better_return_type_inference_for_tail_front_circshift_reverse branch August 6, 2024 10:53
nsajko added a commit to nsajko/julia that referenced this pull request Aug 6, 2024
Just adds an `::NTuple` type assertion to the result.

Before the return type of `reverse(::NTuple)` inferred as `Tuple`, now
it's more precise, inferring as `NTuple`.

This is a partial reland of JuliaLang#55124 and partial revert of JuliaLang#55375.

Updates JuliaLang#54495
lazarusA pushed a commit to lazarusA/julia that referenced this pull request Aug 17, 2024
…rgs" (JuliaLang#55375)

Reverts JuliaLang#55124 as this turns out to hurt performance
quite a bit

Closes JuliaLang#55374
nsajko added a commit to nsajko/julia that referenced this pull request Feb 5, 2025
Just adds an `::NTuple` type assertion to the result.

Before the return type of `reverse(::NTuple)` inferred as `Tuple`, now
it's more precise, inferring as `NTuple`.

This is a partial reland of JuliaLang#55124 and partial revert of JuliaLang#55375.

Updates JuliaLang#54495
vtjnash pushed a commit that referenced this pull request Sep 30, 2025
Before the return type of `reverse(::NTuple)` inferred as `Tuple`, now
it's more precise, inferring as `NTuple`.

This is a partial reland of #55124 and partial revert of #55375.

Fixes #54495
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

collections Data structures holding multiple items, e.g. sets performance Must go faster revert This reverts a previously merged PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Large regression in union array benchmarks due to 'better type inference for several functions taking NTuple args (#55124)'

5 participants