From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dan Nicolaescu Newsgroups: gmane.emacs.devel Subject: Re: valgrind warnings [Re: Emacs bzr memory footprint] Date: Fri, 28 Oct 2011 10:38:03 -0400 Message-ID: References: <87fwivwp37.fsf@turtle.gmx.de> <87sjmvpmd2.fsf@lifelogs.com> <87aa93wmc4.fsf@turtle.gmx.de> <87sjmnrdjw.fsf@spindle.srvr.nix> <87ty73mc0m.fsf@spindle.srvr.nix> <4EA19111.7060401@yandex.ru> <87vcrhfmww.fsf@uwakimon.sk.tsukuba.ac.jp> <87pqhpf1qo.fsf@uwakimon.sk.tsukuba.ac.jp> <87k47qaxvz.fsf@lifelogs.com> <83bot1bovw.fsf@gnu.org> <87y5w531eo.fsf@uwakimon.sk.tsukuba.ac.jp> <83zkgla1mg.fsf@gnu.org> <87vcr92z6x.fsf@uwakimon.sk.tsukuba.ac.jp> <83ty6t9zd0.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1319812697 27578 80.91.229.12 (28 Oct 2011 14:38:17 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 28 Oct 2011 14:38:17 +0000 (UTC) Cc: "Stephen J. Turnbull" , emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Oct 28 16:38:10 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RJnZS-0002iu-4U for ged-emacs-devel@m.gmane.org; Fri, 28 Oct 2011 16:38:10 +0200 Original-Received: from localhost ([::1]:40230 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RJnZR-0001r3-K2 for ged-emacs-devel@m.gmane.org; Fri, 28 Oct 2011 10:38:09 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:53279) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RJnZO-0001qn-AY for emacs-devel@gnu.org; Fri, 28 Oct 2011 10:38:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RJnZN-0006MJ-4F for emacs-devel@gnu.org; Fri, 28 Oct 2011 10:38:06 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]:48745) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RJnZN-0006MD-2h for emacs-devel@gnu.org; Fri, 28 Oct 2011 10:38:05 -0400 Original-Received: from dann by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1RJnZL-0001sf-Su; Fri, 28 Oct 2011 10:38:03 -0400 In-Reply-To: (Dan Nicolaescu's message of "Fri, 28 Oct 2011 07:52:12 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.10 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:145712 Archived-At: Dan Nicolaescu writes: > valgrind ./temacs > > Valgrind produces these warnings, maybe some of them are interesting: > > ==30382== Conditional jump or move depends on uninitialised value(s) > ==30382== at 0x4731E6: note_mouse_highlight (xdisp.c:26841) > ==30382== by 0x4F8682: note_mouse_movement (xterm.c:3830) > ==30382== by 0x4FCB2E: handle_one_xevent (xterm.c:6652) > ==30382== by 0x4FD792: XTread_socket (xterm.c:7133) > ==30382== by 0x5437F7: read_avail_input (keyboard.c:6821) > ==30382== by 0x54409F: handle_async_input (keyboard.c:7149) > ==30382== by 0x5440BE: process_pending_signals (keyboard.c:7165) > ==30382== by 0x62D713: wait_reading_process_output (process.c:4340) > ==30382== by 0x419ED2: sit_for (dispnew.c:5971) > ==30382== by 0x53AF87: read_char (keyboard.c:2687) > ==30382== by 0x548876: read_key_sequence (keyboard.c:9290) > ==30382== by 0x538709: command_loop_1 (keyboard.c:1447) This is because window_from_coordinates in note_mouse_highlight is passed "&part", where "part" is an uninitialized local variable. When !NILP(window) "part" is not touched, so it stays uninitialized. Can someone who understands this code fix this please? > ==30382== Conditional jump or move depends on uninitialised value(s) > ==30382== at 0x46D785: x_write_glyphs (xdisp.c:24661) > ==30382== by 0x413E4A: update_text_area (dispnew.c:3765) > ==30382== by 0x414794: update_window_line (dispnew.c:4006) > ==30382== by 0x413A1A: update_window (dispnew.c:3625) > ==30382== by 0x413256: update_single_window (dispnew.c:3370) > ==30382== by 0x511A93: Fx_show_tip (xfns.c:5189) > ==30382== by 0x5D6E47: Ffuncall (eval.c:2995) > ==30382== by 0x622C5B: exec_byte_code (bytecode.c:785) > ==30382== by 0x6221C6: Fbyte_code (bytecode.c:423) > ==30382== by 0x5D56AB: eval_sub (eval.c:2328) > ==30382== by 0x5D381A: internal_lisp_condition_case (eval.c:1453) > ==30382== by 0x62392A: exec_byte_code (bytecode.c:981) I think I fixed this one.