From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#12541: Prefer plain 'static' to 'static inline'. Date: Sun, 30 Sep 2012 20:33:04 +0200 Message-ID: <83y5jrcqe7.fsf@gnu.org> References: <5067FC19.3000704@cs.ucla.edu> <83d313et6t.fsf@gnu.org> <50688861.2090306@cs.ucla.edu> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1349030027 16014 80.91.229.3 (30 Sep 2012 18:33:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 30 Sep 2012 18:33:47 +0000 (UTC) Cc: 12541@debbugs.gnu.org To: Paul Eggert Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Sep 30 20:33:53 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TIOKr-0003HC-Pu for geb-bug-gnu-emacs@m.gmane.org; Sun, 30 Sep 2012 20:33:49 +0200 Original-Received: from localhost ([::1]:46560 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TIOKm-0000wd-9F for geb-bug-gnu-emacs@m.gmane.org; Sun, 30 Sep 2012 14:33:44 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:36460) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TIOKj-0000wF-EP for bug-gnu-emacs@gnu.org; Sun, 30 Sep 2012 14:33:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TIOKi-0003AU-D5 for bug-gnu-emacs@gnu.org; Sun, 30 Sep 2012 14:33:41 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:53608) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TIOKi-0003AQ-9n for bug-gnu-emacs@gnu.org; Sun, 30 Sep 2012 14:33:40 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1TIOL3-0004UR-VJ for bug-gnu-emacs@gnu.org; Sun, 30 Sep 2012 14:34:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 30 Sep 2012 18:34:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 12541 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 12541-submit@debbugs.gnu.org id=B12541.134903000917218 (code B ref 12541); Sun, 30 Sep 2012 18:34:01 +0000 Original-Received: (at 12541) by debbugs.gnu.org; 30 Sep 2012 18:33:29 +0000 Original-Received: from localhost ([127.0.0.1]:34921 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TIOKX-0004Tf-0X for submit@debbugs.gnu.org; Sun, 30 Sep 2012 14:33:29 -0400 Original-Received: from mtaout22.012.net.il ([80.179.55.172]:64967) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TIOKU-0004TX-F9 for 12541@debbugs.gnu.org; Sun, 30 Sep 2012 14:33:27 -0400 Original-Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MB600600DXA2D00@a-mtaout22.012.net.il> for 12541@debbugs.gnu.org; Sun, 30 Sep 2012 20:33:00 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MB6005VGE70YY30@a-mtaout22.012.net.il>; Sun, 30 Sep 2012 20:33:00 +0200 (IST) In-reply-to: <50688861.2090306@cs.ucla.edu> X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:65032 Archived-At: > Date: Sun, 30 Sep 2012 10:58:57 -0700 > From: Paul Eggert > CC: 12541@debbugs.gnu.org > > On my platform (GCC 4.7.2 -O3, x86-64, Fedora 17, trunk bzr 110287) > GCC does not always inline 'bidi_char_at_pos': in a couple of cases > the function is only partly inlined. Is this so with either 'static inline' or with 'static'? More generally, is there any difference, in terms of generated code, that you see between using and not using 'inline' for these functions? If you don't see any difference, I guess modern platforms are fast enough to make non-inlined versions fast enough, or else people would have complained long ago. > With the proposed change, the set of functions that are not always > inlined expands to bidi_cache_iterator_state, bidi_char_at_pos, and > bidi_fetch_char, and (if we also include functions that are partially > inlined) bidi_cache_search and bidi_get_type. Were they also not inlined before the change? > I don't offhand see how this would slow down Emacs significantly, > as these functions are fairly large. They are in the innermost loops of the display engine. They are called whenever the display engine needs to examine the next character for display. > Is there some benchmark I could try out, to see the performance > effects that are of concern here? My old benchmark was to run the reordering engine, as a stand-alone program, on a large text file. But that was long ago (10 years), so perhaps my conclusions from those runs are no longer valid.