This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Bug in tidy_fallthru_edges ?
- From: "Ulrich Weigand" <Ulrich dot Weigand at de dot ibm dot com>
- To: gcc at gcc dot gnu dot org
- Date: Mon, 14 Jan 2002 16:46:53 +0100
- Subject: Bug in tidy_fallthru_edges ?
Hello,
the following routine from glibc gets miscompiled on S/390:
int __swapcontext (ucontext_t *oucp, ucontext_t *ucp)
{
__getcontext (oucp);
oucp->uc_mcontext.gregs[14] = &&fake_return;
__setcontext (ucp);
fake_return:
return 0;
}
What happens is that 'tidy_fallthru_edges' simply removes the
'fake_return' label, because it apparently considers the 'return 0'
statement only reachable via fall-through from the main body,
without taking into account that there is a named label,
which is actually used somewhere ...
Any ideas how to fix this?
Mit freundlichen Gruessen / Best Regards
Ulrich Weigand
--
Dr. Ulrich Weigand
Linux for S/390 Design & Development
IBM Deutschland Entwicklung GmbH, Schoenaicher Str. 220, 71032 Boeblingen
Phone: +49-7031/16-3727 --- Email: Ulrich.Weigand@de.ibm.com