annotate gcc/testsuite/gcc.dg/vect/pr33597.c @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 /* { dg-do compile } */
kono
parents:
diff changeset
2
kono
parents:
diff changeset
3 typedef unsigned char uint8_t;
kono
parents:
diff changeset
4 typedef unsigned short uint16_t;
kono
parents:
diff changeset
5
kono
parents:
diff changeset
6 void
kono
parents:
diff changeset
7 rgb15to24_C (const uint8_t * src, uint8_t * dst, long src_size)
kono
parents:
diff changeset
8 {
kono
parents:
diff changeset
9 const uint16_t *end;
kono
parents:
diff changeset
10 const uint16_t *s = (uint16_t *)src;
kono
parents:
diff changeset
11 uint8_t *d = (uint8_t *)dst;
kono
parents:
diff changeset
12
kono
parents:
diff changeset
13 end = s + src_size/2;
kono
parents:
diff changeset
14 while (s < end)
kono
parents:
diff changeset
15 {
kono
parents:
diff changeset
16 uint16_t bgr = *s++;
kono
parents:
diff changeset
17
kono
parents:
diff changeset
18 *d++ = (bgr&0x1F)<<3;
kono
parents:
diff changeset
19 *d++ = (bgr&0x3E0)>>2;
kono
parents:
diff changeset
20 *d++ = (bgr&0x7C00)>>7;
kono
parents:
diff changeset
21 }
kono
parents:
diff changeset
22 }
kono
parents:
diff changeset
23