Skip to content

fix promotion of MIR terminators#38833

Merged
bors merged 1 commit into
rust-lang:masterfrom
arielb1:constant-mir-overflow
Jan 6, 2017
Merged

fix promotion of MIR terminators#38833
bors merged 1 commit into
rust-lang:masterfrom
arielb1:constant-mir-overflow

Conversation

@arielb1

@arielb1 arielb1 commented Jan 4, 2017

Copy link
Copy Markdown
Contributor

promotion of MIR terminators used to try to promote the destination it
is trying to promote, leading to stack overflow.

Also clean up the code in promote_temp a bit to make it more understandable.

Fixes #37991.

cc @nikomatsakis
r? @eddyb

promotion of MIR terminators used to try to promote the destination it
is trying to promote, leading to stack overflow.

Fixes rust-lang#37991.
@arielb1 arielb1 added the beta-nominated Nominated for backporting to the compiler in the beta channel. label Jan 4, 2017
@eddyb

eddyb commented Jan 4, 2017

Copy link
Copy Markdown
Contributor

Hah, I'm glad I checked first, I finally had some time to spend on this (I'll go do #38074 instead).

@eddyb

eddyb commented Jan 4, 2017

Copy link
Copy Markdown
Contributor

@bors r+ Nice rewrite!

@bors

bors commented Jan 4, 2017

Copy link
Copy Markdown
Collaborator

📌 Commit 99aa48d has been approved by eddyb

@eddyb eddyb added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Jan 4, 2017
@nikomatsakis

Copy link
Copy Markdown
Contributor

After discussing in @rust-lang/compiler meeting, decided to approve for backport. Fixes a regression, minimal risk.

@nikomatsakis nikomatsakis added the beta-accepted Accepted for backporting to the compiler in the beta channel. label Jan 5, 2017
@alexcrichton

Copy link
Copy Markdown
Member

@bors: p=1

This is a backport

@bors

bors commented Jan 6, 2017

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 99aa48d with merge aa0c250...

@bors

bors commented Jan 6, 2017

Copy link
Copy Markdown
Collaborator

💔 Test failed - status-appveyor

@alexcrichton

alexcrichton commented Jan 6, 2017 via email

Copy link
Copy Markdown
Member

@bors

bors commented Jan 6, 2017

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 99aa48d with merge 0728b71...

bors added a commit that referenced this pull request Jan 6, 2017
fix promotion of MIR terminators

promotion of MIR terminators used to try to promote the destination it
is trying to promote, leading to stack overflow.

Also clean up the code in `promote_temp` a bit to make it more understandable.

Fixes #37991.

cc @nikomatsakis
r? @eddyb
@bors

bors commented Jan 6, 2017

Copy link
Copy Markdown
Collaborator

☀️ Test successful - status-appveyor, status-travis
Approved by: eddyb
Pushing 0728b71 to master...

@bors bors merged commit 99aa48d into rust-lang:master Jan 6, 2017
@nikomatsakis

Copy link
Copy Markdown
Contributor

@bors r-

@nikomatsakis

Copy link
Copy Markdown
Contributor

oh, never mind :)

@nikomatsakis nikomatsakis mentioned this pull request Jan 6, 2017
17 tasks
@alexcrichton alexcrichton removed the beta-nominated Nominated for backporting to the compiler in the beta channel. label Jan 6, 2017
bors added a commit that referenced this pull request Jan 11, 2017
fix function arguments in constant promotion

we can't create the target block until *after* we promote the arguments - otherwise the arguments will be promoted into the target block. oops.

Fixes #38985.

This is a regression introduced in the beta-nominated #38833, so beta-nominating this one too (sorry @brson).

r? @eddyb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

beta-accepted Accepted for backporting to the compiler in the beta channel. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants