view gcc/testsuite/c-c++-common/ubsan/pr58443-2.c @ 158:494b0b89df80 default tip

...
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 25 May 2020 18:13:55 +0900
parents 04ced10e8804
children
line wrap: on
line source

/* PR sanitizer/58443 */
/* { dg-do compile } */
/* { dg-options "-fsanitize=unreachable,integer-divide-by-zero -w" } */

int
foo (int u, int o)
{
  return u >> o;
}

/* { dg-final { scan-assembler-not "__ubsan_handle_shift_out_of_bounds" } } */