#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */
typedef struct TYPE_3__ TYPE_1__;

/* Type definitions */
struct TYPE_3__ {
  short member_0;
  short member_1;
  short member_2;
  short member_3;
  short member_4;
  short member_5;
  short member_6;
  short member_7;
  short member_8;
  short member_9;
  short member_10;
  short member_11;
  short member_12;
  short member_13;
  short member_14;
  short member_15;
};
typedef TYPE_1__ __v16hi;

/* Variables and functions */
__v16hi foo_6(short c) {
  __v16hi v1 = {c, c, c, c, c, c, c, c, c, c, c, c, c, c, c, c};
  return v1;
}


x86 assembly (clang, -O0):
<foo_6>:
push   %rbp
mov    %rsp,%rbp
mov    %si,%cx
mov    %rdi,%rax
mov    %cx,-0x2(%rbp)
mov    -0x2(%rbp),%cx
mov    %cx,(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x2(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x4(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x6(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x8(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0xa(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0xc(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0xe(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x10(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x12(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x14(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x16(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x18(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x1a(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x1c(%rdi)
mov    -0x2(%rbp),%cx
mov    %cx,0x1e(%rdi)
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo_6>:
mov    %rdi,%rax
movd   %esi,%xmm0
pshuflw $0x0,%xmm0,%xmm0
pshufd $0x0,%xmm0,%xmm0
movdqu %xmm0,(%rdi)
movdqu %xmm0,0x10(%rdi)
ret

LLVM IR (-O0):
%struct.TYPE_3__ = type { i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16 }
define void @foo_6(%struct.TYPE_3__* noalias sret(%struct.TYPE_3__) align 2 %0, i16 signext %1) {
%3 = alloca i16
store i16 %1, i16* %3
%4 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 0
%5 = load i16, i16* %3
store i16 %5, i16* %4
%6 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 1
%7 = load i16, i16* %3
store i16 %7, i16* %6
%8 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 2
%9 = load i16, i16* %3
store i16 %9, i16* %8
%10 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 3
%11 = load i16, i16* %3
store i16 %11, i16* %10
%12 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 4
%13 = load i16, i16* %3
store i16 %13, i16* %12
%14 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 5
%15 = load i16, i16* %3
store i16 %15, i16* %14
%16 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 6
%17 = load i16, i16* %3
store i16 %17, i16* %16
%18 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 7
%19 = load i16, i16* %3
store i16 %19, i16* %18
%20 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 8
%21 = load i16, i16* %3
store i16 %21, i16* %20
%22 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 9
%23 = load i16, i16* %3
store i16 %23, i16* %22
%24 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 10
%25 = load i16, i16* %3
store i16 %25, i16* %24
%26 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 11
%27 = load i16, i16* %3
store i16 %27, i16* %26
%28 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 12
%29 = load i16, i16* %3
store i16 %29, i16* %28
%30 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 13
%31 = load i16, i16* %3
store i16 %31, i16* %30
%32 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 14
%33 = load i16, i16* %3
store i16 %33, i16* %32
%34 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i32 0, i32 15
%35 = load i16, i16* %3
store i16 %35, i16* %34
ret void
}

LLVM IR (-O2):
%struct.TYPE_3__ = type { i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16 }
define void @foo_6(%struct.TYPE_3__* noalias nocapture writeonly sret(%struct.TYPE_3__) align 2 %0, i16 signext %1) {
%3 = insertelement <8 x i16> poison, i16 %1, i64 0
%4 = shufflevector <8 x i16> %3, <8 x i16> poison, <8 x i32> zeroinitializer
%5 = bitcast %struct.TYPE_3__* %0 to <8 x i16>*
store <8 x i16> %4, <8 x i16>* %5
%6 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %0, i64 0, i32 8
%7 = bitcast i16* %6 to <8 x i16>*
store <8 x i16> %4, <8 x i16>* %7
ret void
}