Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve shape inference in the cat pipeline #37080

Merged
merged 1 commit into from
Sep 1, 2020
Merged

Conversation

timholy
Copy link
Member

@timholy timholy commented Aug 17, 2020

cat is frequently called with poor inference, since one only has to concatenate a couple of different container types before inference punts on the result type. While this does not make the return type in mixed container types fully inferrable, it does improve the analysis of the shape.

Because it doesn't fully fix the inference problems, it's not obvious this is a testable improvement except at the aggregate level of backedges. Given that the issues are not fully fixed, the T::Type to ::Type{T} changes don't really seem to be necessary, and I could back those out if desired.

@timholy timholy added arrays [a, r, r, a, y, s] compiler:latency Compiler latency labels Aug 17, 2020
`cat` is frequently called with poor inference, since one only has
to concatenate a couple of different container types before inference
punts on the result type. While this does not make the return type
in mixed container types fully inferrable, it does improve the analysis
of the shape.
@timholy timholy merged commit 2f5d3e8 into master Sep 1, 2020
@timholy timholy deleted the teh/cat_inference branch September 1, 2020 11:57
dlfivefifty added a commit to dlfivefifty/julia that referenced this pull request Nov 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
arrays [a, r, r, a, y, s] compiler:latency Compiler latency
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants