This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/49820] Explicit check for integer negative after abs optimized away
- From: "ebotcazou at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 23 Jul 2011 20:59:10 +0000
- Subject: [Bug c/49820] Explicit check for integer negative after abs optimized away
- Auto-submitted: auto-generated
- References: <bug-49820-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49820
Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ebotcazou at gcc dot
| |gnu.org
--- Comment #5 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2011-07-23 20:58:52 UTC ---
> CPUs which use 2s compliment representations are usually well equipped to deal
> with overflow and carry. I would claim a result which overflows is actually
> predictable and repeatable. Fortunately, CPU manufacturers have not taken the
> 'ignore the problem' approach taken by ISO/IEC.
See http://www.airs.com/blog/archives/120 for more elaborated views.