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

Coalescer failed to join two intervals created by copies from the same temp #1059

Closed
llvmbot opened this issue Jan 9, 2006 · 6 comments
Closed
Assignees
Labels
bugzilla Issues migrated from bugzilla code-quality llvm:regalloc

Comments

@llvmbot
Copy link
Collaborator

llvmbot commented Jan 9, 2006

Bugzilla Link 687
Resolution FIXED
Resolved on Feb 22, 2010 12:54
Version 1.0
OS All
Attachments bug.ll
Reporter LLVM Bugzilla Contributor

Extended Description

********** JOINING INTERVALS ***********
entry:
0 %reg1024 = MOV32rm %NOREG, 1, %NOREG, ga:X
4 %reg1025 = MOV32rm <fi#-1>, 1, %NOREG, 0
8 %reg1026 = MOV8rm %reg1024, 1, %NOREG, 0
12 %reg1027 = MOV32rm <fi#-1>, 1, %NOREG, 4
16 %reg1028 = MOV32ri 0
20 %CL = MOV8rr %reg1026
Inspecting %reg1026,0 = [10,46:0) and %reg9,inf =
[22,30:0)[34,42:1): Interference!
24 %reg1029 = MOV32rr %reg1025
Inspecting %reg1025,0 = [6,42:0) and %reg1029,0 =
[26,30:1)[30,58:0): Interference!
28 SHL32rCL %reg1029<def&use>
32 %CL = MOV8rr %reg1026
Inspecting %reg1026,0 = [10,46:0) and %reg9,inf =
[22,30:0)[34,42:1): Interference!
36 %reg1030 = MOV32rr %reg1027
Inspecting %reg1027,0 = [14,38:0) and %reg1030,0 =
[38,42:1)[42,50:0): Joined. Result = %reg1030,0 = [14,42:1)[42,50:0)
40 SHLD32rrCL %reg1030<def&use>, %reg1025

It failed to coalesce reg1026 to CL (reg9):
Inspecting %reg1026,0 = [10,46:0) and %reg9,inf = [22,30:0)[34,42:1): Interference!

The two live ranges are created by copies from the same temp %reg1026.

@llvmbot
Copy link
Collaborator Author

llvmbot commented Jan 9, 2006

assigned to @lattner

@llvmbot
Copy link
Collaborator Author

llvmbot commented Jan 9, 2006

To replicate the bug:
llvm-as < bug.ll | llc -march=x86 -enable-x86-dag-isel -print-machineinstrs -o -

@lattner
Copy link
Collaborator

lattner commented Jan 9, 2006

Thanks Evan!

@lattner
Copy link
Collaborator

lattner commented Apr 12, 2006

not going to happen for 1.7

@llvmbot
Copy link
Collaborator Author

llvmbot commented May 9, 2006

I'll take a crack at this.

@lattner
Copy link
Collaborator

lattner commented Aug 30, 2006

Fixed. Testcase here: CodeGen/X86/shift-coalesce.ll

-Chris

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 3, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla code-quality llvm:regalloc
Projects
None yet
Development

No branches or pull requests

2 participants