blob: 43276a46017cff4e561046fe6317b775a9baf680 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
extern int fun(void);
typedef unsigned int u32;
typedef int s32;
typedef void *vdp;
typedef int *sip;
typedef double dbl;
typedef unsigned short __attribute__((bitwise)) le16;
static _Bool fs32_i(s32 a) { return a; }
static _Bool fs32_e(s32 a) { return (_Bool)a; }
static _Bool fu32_i(u32 a) { return a; }
static _Bool fu32_e(u32 a) { return (_Bool)a; }
static _Bool fvdp_i(vdp a) { return a; }
static _Bool fvdp_e(vdp a) { return (_Bool)a; }
static _Bool fsip_i(sip a) { return a; }
static _Bool fsip_e(sip a) { return (_Bool)a; }
static _Bool ffun_i(void) { return fun; }
static _Bool ffun_e(void) { return (_Bool)fun; }
static _Bool fres_i(le16 a) { return a; }
static _Bool fres_e(le16 a) { return (_Bool)a; }
static _Bool fdbl_i(dbl a) { return a; }
static _Bool fdbl_e(dbl a) { return (_Bool)a; }
/*
* check-name: bool-cast
* check-command: test-linearize -m64 -fdump-ir=linearize $file
*
* check-output-ignore
* check-output-excludes: cast\\.
* check-output-excludes: fcvt[us]\\.
* check-output-excludes: ptrtu\\.
* check-output-pattern(12): setne\\.
* check-output-pattern(2): fcmpune\\.
*/
|