blob: c8eb985856ad7134e2b8eb1a3ab7fdaaf4cc7eaa [file] [log] [blame]
/* { dg-do compile } */
/* { dg-require-effective-target float16 } */
/* { dg-options "-Ofast -fdump-tree-optimized" } */
/* { dg-add-options float16 } */
/* { dg-final { scan-tree-dump-times " = ABS_EXPR <x_\[0-9]*\\\(D\\\)>;" 1 "optimized" } } */
_Float16 absfloat16(_Float16 x) {
if (x < 0.0f) {
return -x;
} else {
return x;
}
}