Print this page
11972 resync smatch


  13         return sizeof(__int128);
  14 }
  15 
  16 typedef unsigned long long u64;
  17 typedef unsigned long      u32;
  18 
  19 u64 foo(u64 a, u64 b, u64 c, u32 s)
  20 {
  21        unsigned __int128 tmp;
  22 
  23        tmp = (((uint128_t)a) * b) + c;
  24        return (u64) (tmp >> s);
  25 }
  26 
  27 /*
  28  * check-name: int128
  29  * check-command: test-linearize $file
  30  * check-output-ignore
  31  *
  32  * check-output-contains: ret\\..*\\$16
  33  * check-output-contains: mulu\\.128
  34  * check-output-contains: add\\.128
  35  *
  36  * check-error-start
  37 int128.c:5:18: error: two or more data types in declaration specifiers
  38 int128.c:5:18: error: Trying to use reserved word 'int' as identifier
  39 int128.c:5:25: error: Expected ; at end of declaration
  40 int128.c:5:25: error: got badxi
  41 int128.c:6:13: error: two or more data types in declaration specifiers
  42 int128.c:6:13: error: Trying to use reserved word '__int128' as identifier
  43 int128.c:6:25: error: Expected ; at end of declaration
  44 int128.c:6:25: error: got badix
  45 int128.c:7:18: error: impossible combination of type specifiers: unsigned unsigned
  46 int128.c:7:18: error: Trying to use reserved word 'unsigned' as identifier
  47 int128.c:7:27: error: Expected ; at end of declaration
  48 int128.c:7:27: error: got __int128
  49 int128.c:8:16: error: two or more data types in declaration specifiers
  50 int128.c:8:16: error: Trying to use reserved word '__int128' as identifier
  51 int128.c:8:25: error: Expected ; at end of declaration
  52 int128.c:8:25: error: got baddx
  53 int128.c:9:18: error: two or more data types in declaration specifiers


  13         return sizeof(__int128);
  14 }
  15 
  16 typedef unsigned long long u64;
  17 typedef unsigned long      u32;
  18 
  19 u64 foo(u64 a, u64 b, u64 c, u32 s)
  20 {
  21        unsigned __int128 tmp;
  22 
  23        tmp = (((uint128_t)a) * b) + c;
  24        return (u64) (tmp >> s);
  25 }
  26 
  27 /*
  28  * check-name: int128
  29  * check-command: test-linearize $file
  30  * check-output-ignore
  31  *
  32  * check-output-contains: ret\\..*\\$16
  33  * check-output-contains: mul\\.128
  34  * check-output-contains: add\\.128
  35  *
  36  * check-error-start
  37 int128.c:5:18: error: two or more data types in declaration specifiers
  38 int128.c:5:18: error: Trying to use reserved word 'int' as identifier
  39 int128.c:5:25: error: Expected ; at end of declaration
  40 int128.c:5:25: error: got badxi
  41 int128.c:6:13: error: two or more data types in declaration specifiers
  42 int128.c:6:13: error: Trying to use reserved word '__int128' as identifier
  43 int128.c:6:25: error: Expected ; at end of declaration
  44 int128.c:6:25: error: got badix
  45 int128.c:7:18: error: impossible combination of type specifiers: unsigned unsigned
  46 int128.c:7:18: error: Trying to use reserved word 'unsigned' as identifier
  47 int128.c:7:27: error: Expected ; at end of declaration
  48 int128.c:7:27: error: got __int128
  49 int128.c:8:16: error: two or more data types in declaration specifiers
  50 int128.c:8:16: error: Trying to use reserved word '__int128' as identifier
  51 int128.c:8:25: error: Expected ; at end of declaration
  52 int128.c:8:25: error: got baddx
  53 int128.c:9:18: error: two or more data types in declaration specifiers