function_hooks/unwind: introduce return_implies_exact()
[smatch.git] / validation / linear / call-complex-pointer.c
blob2be35c5bef15d5616f884b98e8638f6b17602d14
1 int foo(int p, int (*f0)(int), int (*f1)(int), int arg)
3 return (p ? f0 : f1)(arg);
6 /*
7 * check-name: call-complex-pointer
8 * check-command: test-linearize -m64 -Wno-decl $file
9 * check-assert: sizeof(void *) == 8
11 * check-output-start
12 foo:
13 .L0:
14 <entry-point>
15 cbr %arg1, .L2, .L3
17 .L2:
18 phisrc.64 %phi1 <- %arg2
19 br .L4
21 .L3:
22 ptrcast.64 %r6 <- (64) %arg3
23 phisrc.64 %phi2 <- %r6
24 br .L4
26 .L4:
27 phi.64 %r7 <- %phi1, %phi2
28 call.32 %r8 <- %r7, %arg4
29 ret.32 %r8
32 * check-output-end