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

pass: add PruneSelfMoves cleanup pass #80

Merged
merged 5 commits into from
Apr 14, 2019
Merged

pass: add PruneSelfMoves cleanup pass #80

merged 5 commits into from
Apr 14, 2019

Conversation

mmcloughlin
Copy link
Owner

Issue #76 showed that in some cases natural use of abstraction in avo programs can lead to redundant move instructions, specifically self-moves such as MOVQ AX, AX. This does not produce incorrect code but it is incorrect and inelegant.

This diff introduces a PruneSelfMoves pass that removes such unnecessary instructions.

@codecov-io
Copy link

codecov-io commented Apr 14, 2019

Codecov Report

Merging #80 into master will increase coverage by 0.02%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #80      +/-   ##
==========================================
+ Coverage   76.01%   76.03%   +0.02%     
==========================================
  Files          51       52       +1     
  Lines       31136    31159      +23     
==========================================
+ Hits        23669    23693      +24     
+ Misses       7367     7366       -1     
  Partials      100      100
Flag Coverage Δ
#integration 6.16% <100%> (+0.07%) ⬆️
#unittests 74.26% <100%> (+0.01%) ⬆️
Impacted Files Coverage Δ
pass/pass.go 60% <ø> (ø) ⬆️
pass/cleanup.go 100% <100%> (ø)
operand/checks.go 98.98% <0%> (+1.01%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5d3176b...8e842e4. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants