comparison test/CodeGen/X86/pr24602.ll @ 95:afa8332a0e37 LLVM3.8

LLVM 3.8
author Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
date Tue, 13 Oct 2015 17:48:58 +0900
parents
children 3a76565eade5
comparison
equal deleted inserted replaced
84:f3e34b893a5f 95:afa8332a0e37
1 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown | FileCheck %s
2
3 ; PR24602: Make sure we don't barf on non-foldable code (with opaque constants).
4
5 ; CHECK-LABEL: pr24602:
6 ; CHECK-NEXT: # BB#0
7 ; CHECK-NEXT: movabsq $-10000000000, [[CST:%[a-z0-9]+]]
8 ; CHECK-NEXT: imulq [[CST]], %rsi
9 ; CHECK-NEXT: leaq (%rdi,%rsi,8), %rax
10 ; CHECK-NEXT: movq [[CST]], (%rdi,%rsi,8)
11 ; CHECK-NEXT: retq
12 define i64* @pr24602(i64* %p, i64 %n) nounwind {
13 %mul = mul nsw i64 %n, -10000000000
14 %add.ptr = getelementptr inbounds i64, i64* %p, i64 %mul
15 store i64 -10000000000, i64* %add.ptr
16 ret i64* %add.ptr
17 }