https://gcc.gnu.org/g:34c51485808188eec3ebdacf969dd335e908aab3
commit r15-7031-g34c51485808188eec3ebdacf969dd335e908aab3 Author: Dimitar Dimitrov <dimi...@dinux.eu> Date: Sat Jan 18 20:19:43 2025 +0200 testsuite: Fixes for test case pr117546.c This test fails on AVR. Debugging the test on x86 host, I noticed that u in function s sometimes has value 16128. The "t <= 3 * u" expression in the same function results in signed integer overflow for targets with sizeof(int)=2. Fix by requiring int32 effective target. Also add return statement for the main function. gcc/testsuite/ChangeLog: * gcc.dg/torture/pr117546.c: Require effective target int32. (main): Add return statement. Signed-off-by: Dimitar Dimitrov <dimi...@dinux.eu> Diff: --- gcc/testsuite/gcc.dg/torture/pr117546.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gcc/testsuite/gcc.dg/torture/pr117546.c b/gcc/testsuite/gcc.dg/torture/pr117546.c index 21e2aef18b9a..b60f877a9063 100644 --- a/gcc/testsuite/gcc.dg/torture/pr117546.c +++ b/gcc/testsuite/gcc.dg/torture/pr117546.c @@ -1,4 +1,4 @@ -/* { dg-do run } */ +/* { dg-do run { target int32 } } */ typedef struct { int a; @@ -81,4 +81,6 @@ int main() { l.glyf.coords[4] = (e){2, 206}; l.glyf.coords[6] = (e){0, 308, 5}; w(&l); + + return 0; }