Please use GitHub pull requests for new patches. Avoid migrating existing patches. Phabricator shutdown timeline
Changeset View
Changeset View
Standalone View
Standalone View
test/CodeGen/X86/lea-opt-cse1.ll
Show All 26 Lines | |||||
; X86-NEXT: movl (%eax), %ecx | ; X86-NEXT: movl (%eax), %ecx | ||||
; X86-NEXT: movl 16(%eax), %edx | ; X86-NEXT: movl 16(%eax), %edx | ||||
; X86-NEXT: leal 1(%ecx,%edx), %esi | ; X86-NEXT: leal 1(%ecx,%edx), %esi | ||||
; X86-NEXT: addl %edx, %ecx | ; X86-NEXT: addl %edx, %ecx | ||||
; X86-NEXT: movl %esi, 12(%eax) | ; X86-NEXT: movl %esi, 12(%eax) | ||||
; X86-NEXT: leal 1(%edx,%ecx), %ecx | ; X86-NEXT: leal 1(%edx,%ecx), %ecx | ||||
; X86-NEXT: movl %ecx, 16(%eax) | ; X86-NEXT: movl %ecx, 16(%eax) | ||||
; X86-NEXT: popl %esi | ; X86-NEXT: popl %esi | ||||
; X86-NEXT: .Lcfi2: | |||||
; X86-NEXT: .cfi_def_cfa_offset 4 | |||||
; X86-NEXT: retl | ; X86-NEXT: retl | ||||
entry: | entry: | ||||
%h0 = getelementptr inbounds %struct.SA, %struct.SA* %ctx, i64 0, i32 0 | %h0 = getelementptr inbounds %struct.SA, %struct.SA* %ctx, i64 0, i32 0 | ||||
%0 = load i32, i32* %h0, align 8 | %0 = load i32, i32* %h0, align 8 | ||||
%h3 = getelementptr inbounds %struct.SA, %struct.SA* %ctx, i64 0, i32 3 | %h3 = getelementptr inbounds %struct.SA, %struct.SA* %ctx, i64 0, i32 3 | ||||
%h4 = getelementptr inbounds %struct.SA, %struct.SA* %ctx, i64 0, i32 4 | %h4 = getelementptr inbounds %struct.SA, %struct.SA* %ctx, i64 0, i32 4 | ||||
%1 = load i32, i32* %h4, align 8 | %1 = load i32, i32* %h4, align 8 | ||||
%add = add i32 %0, 1 | %add = add i32 %0, 1 | ||||
%add4 = add i32 %add, %1 | %add4 = add i32 %add, %1 | ||||
store i32 %add4, i32* %h3, align 4 | store i32 %add4, i32* %h3, align 4 | ||||
%add29 = add i32 %add4 , %1 | %add29 = add i32 %add4 , %1 | ||||
store i32 %add29, i32* %h4, align 8 | store i32 %add29, i32* %h4, align 8 | ||||
ret void | ret void | ||||
} | } |