blob: a628f6d99222958cfd8c410f0e85639e3a49dd4b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
/* { dg-do compile } */
/* { dg-options "-O -fdump-tree-phiopt" } */
#include <stdint.h>
uint8_t three_minmax3 (uint8_t xc, uint8_t xm, uint8_t xy) {
uint8_t xk;
if (xc > xm) {
xk = (uint8_t) (xy < xc ? xc : xy);
} else {
xk = (uint8_t) (xm < xy ? xm : xy);
}
return xk;
}
/* { dg-final { scan-tree-dump-times "MIN_EXPR" 1 "phiopt1" } } */
/* { dg-final { scan-tree-dump-times "MAX_EXPR" 1 "phiopt1" } } */
|