1 ; RUN: llc -march=msp430 -combiner-alias-analysis < %s | FileCheck %s
2 target datalayout = "e-p:16:8:8-i8:8:8-i16:8:8-i32:8:8"
3 target triple = "msp430-generic-generic"
4 @foo = common global i16 0, align 2
5 @bar = common global i16 0, align 2
7 define void @mov() nounwind {
9 ; CHECK: mov.w &bar, &foo
11 store i16 %1, i16* @foo
15 define void @add() nounwind {
17 ; CHECK: add.w &bar, &foo
21 store i16 %3, i16* @foo
25 define void @and() nounwind {
27 ; CHECK: and.w &bar, &foo
31 store i16 %3, i16* @foo
35 define void @bis() nounwind {
37 ; CHECK: bis.w &bar, &foo
41 store i16 %3, i16* @foo
45 define void @xor() nounwind {
47 ; CHECK: xor.w &bar, &foo
51 store i16 %3, i16* @foo
55 define i16 @mov2() nounwind {
57 %retval = alloca i16 ; <i16*> [#uses=3]
58 %x = alloca i32, align 2 ; <i32*> [#uses=1]
59 %y = alloca i32, align 2 ; <i32*> [#uses=1]
60 store i16 0, i16* %retval
61 %tmp = load i32* %y ; <i32> [#uses=1]
62 store i32 %tmp, i32* %x
63 store i16 0, i16* %retval
64 %0 = load i16* %retval ; <i16> [#uses=1]
67 ; CHECK: mov.w 0(r1), 4(r1)
68 ; CHECK: mov.w 2(r1), 6(r1)