Skip to content

Commit 504af19

Browse files
committed
Fix signed/unsigned warning
1 parent a9e0536 commit 504af19

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

clang/test/CodeGen/builtins-x86.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ typedef float V2f __attribute__((vector_size(8)));
2222
// 128-bit
2323
typedef char V16c __attribute__((vector_size(16)));
2424
typedef signed short V8s __attribute__((vector_size(16)));
25+
typedef unsigned short V8u __attribute__((vector_size(16)));
2526
typedef signed int V4i __attribute__((vector_size(16)));
2627
#ifndef OPENCL
2728
typedef signed long long V2LLi __attribute__((vector_size(16)));
@@ -99,6 +100,7 @@ void f0(void) {
99100
// 128-bit
100101
V16c tmp_V16c;
101102
V8s tmp_V8s;
103+
V8u tmp_V8u;
102104
V4i tmp_V4i;
103105
V2LLi tmp_V2LLi;
104106
V4f tmp_V4f;
@@ -192,7 +194,7 @@ void f0(void) {
192194
tmp_V16c = __builtin_ia32_packsswb128(tmp_V8s, tmp_V8s);
193195
tmp_V8s = __builtin_ia32_packssdw128(tmp_V4i, tmp_V4i);
194196
tmp_V16c = __builtin_ia32_packuswb128(tmp_V8s, tmp_V8s);
195-
tmp_V8s = __builtin_ia32_pmulhuw128(tmp_V8s, tmp_V8s);
197+
tmp_V8u = __builtin_ia32_pmulhuw128(tmp_V8u, tmp_V8u);
196198
tmp_V4f = __builtin_ia32_addsubps(tmp_V4f, tmp_V4f);
197199
tmp_V2d = __builtin_ia32_addsubpd(tmp_V2d, tmp_V2d);
198200
tmp_V4f = __builtin_ia32_haddps(tmp_V4f, tmp_V4f);

0 commit comments

Comments
 (0)