From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3710 invoked by alias); 30 Jun 2010 23:42:13 -0000 Received: (qmail 3648 invoked by uid 48); 30 Jun 2010 23:42:03 -0000 Date: Wed, 30 Jun 2010 23:42:00 -0000 Message-ID: <20100630234203.3647.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug tree-optimization/44736] Overeager -O1 optimization results in incorrect code generation In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "pinskia at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-06/txt/msg02997.txt.bz2 ------- Comment #1 from pinskia at gcc dot gnu dot org 2010-06-30 23:42 ------- Stupid glibc extensions. __malloc_hook and __free_hook are not part of standard C90/C99. -fno-builtin-malloc will disable this optimization. Basically malloc cannot touch global memory as far as the compiler knows so it optimizes out the extra stores. -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|critical |normal Component|c |tree-optimization http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44736