This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/52124] New: config/cr16/cr16.c: possibly redundant code
- From: "dcb314 at hotmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 04 Feb 2012 16:05:19 +0000
- Subject: [Bug target/52124] New: config/cr16/cr16.c: possibly redundant code
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52124
Bug #: 52124
Summary: config/cr16/cr16.c: possibly redundant code
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: target
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: dcb314@hotmail.com
I just ran the static analysis checker cppcheck over the latest trunk code
and it said
[gcc/config/cr16/cr16.c:2024] -> [gcc/config/cr16/cr16.c:2024]: (style) Same
expression on both sides of '||'.
The source code is
return (cfun->calls_alloca || crtl->calls_eh_return
|| cfun->has_nonlocal_label || crtl->calls_eh_return);
which looks to me like one too many mentions of crtl->calls_eh_return,
but may mean some other variable has been missed out.