__attribute__((no, noclone)) void test1(short x[128]) {
  int i;
  for (i = 127; i >= 0; i--) {
    x[i] = 1234;
  }
}


x86 assembly (clang, -O0):
<test1>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x7f,-0xc(%rbp)
cmpl   $0x0,-0xc(%rbp)
jl     1135 <test1+0x35>
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
movw   $0x4d2,(%rax,%rcx,2)
mov    -0xc(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0xc(%rbp)
jmp    110f <test1+0xf>
pop    %rbp
ret

x86 assembly (clang, -O2):
<test1>:
movaps 0xef9(%rip),%xmm0
movups %xmm0,0xf0(%rdi)
movups %xmm0,0xe0(%rdi)
movups %xmm0,0xd0(%rdi)
movups %xmm0,0xc0(%rdi)
movups %xmm0,0xb0(%rdi)
movups %xmm0,0xa0(%rdi)
movups %xmm0,0x90(%rdi)
movups %xmm0,0x80(%rdi)
movups %xmm0,0x70(%rdi)
movups %xmm0,0x60(%rdi)
movups %xmm0,0x50(%rdi)
movups %xmm0,0x40(%rdi)
movups %xmm0,0x30(%rdi)
movups %xmm0,0x20(%rdi)
movups %xmm0,0x10(%rdi)
movups %xmm0,(%rdi)
ret

LLVM IR (-O0):
define void @test1(i16* %0) {
%2 = alloca i16*
%3 = alloca i32
store i16* %0, i16** %2
store i32 127, i32* %3
br label %4
4: ; preds = %12, %1
%5 = load i32, i32* %3
%6 = icmp sge i32 %5, 0
br i1 %6, label %7, label %15
7: ; preds = %4
%8 = load i16*, i16** %2
%9 = load i32, i32* %3
%10 = sext i32 %9 to i64
%11 = getelementptr inbounds i16, i16* %8, i64 %10
store i16 1234, i16* %11
br label %12
12: ; preds = %7
%13 = load i32, i32* %3
%14 = add nsw i32 %13, -1
store i32 %14, i32* %3
br label %4
15: ; preds = %4
ret void
}

LLVM IR (-O2):
define void @test1(i16* nocapture writeonly %0) {
%2 = getelementptr inbounds i16, i16* %0, i64 120
%3 = bitcast i16* %2 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %3
%4 = getelementptr inbounds i16, i16* %0, i64 112
%5 = bitcast i16* %4 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %5
%6 = getelementptr inbounds i16, i16* %0, i64 104
%7 = bitcast i16* %6 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %7
%8 = getelementptr inbounds i16, i16* %0, i64 96
%9 = bitcast i16* %8 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %9
%10 = getelementptr inbounds i16, i16* %0, i64 88
%11 = bitcast i16* %10 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %11
%12 = getelementptr inbounds i16, i16* %0, i64 80
%13 = bitcast i16* %12 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %13
%14 = getelementptr inbounds i16, i16* %0, i64 72
%15 = bitcast i16* %14 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %15
%16 = getelementptr inbounds i16, i16* %0, i64 64
%17 = bitcast i16* %16 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %17
%18 = getelementptr inbounds i16, i16* %0, i64 56
%19 = bitcast i16* %18 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %19
%20 = getelementptr inbounds i16, i16* %0, i64 48
%21 = bitcast i16* %20 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %21
%22 = getelementptr inbounds i16, i16* %0, i64 40
%23 = bitcast i16* %22 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %23
%24 = getelementptr inbounds i16, i16* %0, i64 32
%25 = bitcast i16* %24 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %25
%26 = getelementptr inbounds i16, i16* %0, i64 24
%27 = bitcast i16* %26 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %27
%28 = getelementptr inbounds i16, i16* %0, i64 16
%29 = bitcast i16* %28 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %29
%30 = getelementptr inbounds i16, i16* %0, i64 8
%31 = bitcast i16* %30 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %31
%32 = bitcast i16* %0 to <8 x i16>*
store <8 x i16> <i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234, i16 1234>, <8 x i16>* %32
ret void
}