2011-12-21 08:31:10 +08:00
|
|
|
; RUN: llc -march=mipsel < %s | FileCheck %s
|
|
|
|
|
|
|
|
%struct.unaligned = type <{ i32 }>
|
|
|
|
|
|
|
|
define void @zero_u(%struct.unaligned* nocapture %p) nounwind {
|
|
|
|
entry:
|
2012-08-10 06:08:24 +08:00
|
|
|
; CHECK: swl $zero
|
2012-06-02 08:05:45 +08:00
|
|
|
; CHECK: swr $zero
|
2011-12-21 08:31:10 +08:00
|
|
|
%x = getelementptr inbounds %struct.unaligned* %p, i32 0, i32 0
|
|
|
|
store i32 0, i32* %x, align 1
|
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
define void @zero_a(i32* nocapture %p) nounwind {
|
|
|
|
entry:
|
|
|
|
; CHECK: sw $zero
|
|
|
|
store i32 0, i32* %p, align 4
|
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|