2009-07-17 Richard Guenther <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.target / mips / truncate-2.c
blob423dc26f4dafa3232a8f1ad5b59aea005b540a51
1 /* { dg-options "-O -mgp64" } */
3 #define TEST(ID, TYPE, SHIFT) \
4 int NOMIPS16 \
5 f##ID (long long y) \
6 { \
7 return (TYPE) ((TYPE) (y >> SHIFT) + 1); \
10 TEST (1, int, 32)
11 TEST (2, short, 32)
12 TEST (3, char, 32)
13 TEST (4, int, 33)
14 TEST (5, short, 33)
15 TEST (6, char, 33)
16 TEST (7, int, 61)
17 TEST (8, short, 61)
18 TEST (9, char, 61)
20 /* { dg-final { scan-assembler-not "\tsll\t\[^\n\]*,0" } } */