From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?utf-8?Q?=C3=93scar_Fuentes?= Newsgroups: gmane.emacs.help Subject: Re: A guide on setting up C/C++ development environment for Emacs Date: Wed, 27 Aug 2014 20:31:24 +0200 Message-ID: <877g1taio3.fsf@wanadoo.es> References: <513ad0e2-f7f4-484c-b17b-7c94a8c2fc7a@googlegroups.com> <657f2c39-422b-4289-a02e-3d03dc386166@googlegroups.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1409164334 3294 80.91.229.3 (27 Aug 2014 18:32:14 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 27 Aug 2014 18:32:14 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Aug 27 20:32:08 2014 Return-path: Envelope-to: geh-help-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 1XMi0u-0004Cf-2z for geh-help-gnu-emacs@m.gmane.org; Wed, 27 Aug 2014 20:32:08 +0200 Original-Received: from localhost ([::1]:32848 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XMi0t-0000U3-Mf for geh-help-gnu-emacs@m.gmane.org; Wed, 27 Aug 2014 14:32:07 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44989) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XMi0b-0000TJ-Qk for help-gnu-emacs@gnu.org; Wed, 27 Aug 2014 14:31:56 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XMi0V-0004BF-9G for help-gnu-emacs@gnu.org; Wed, 27 Aug 2014 14:31:49 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:33236) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XMi0V-0004B7-2l for help-gnu-emacs@gnu.org; Wed, 27 Aug 2014 14:31:43 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XMi0S-0003p3-LH for help-gnu-emacs@gnu.org; Wed, 27 Aug 2014 20:31:40 +0200 Original-Received: from 18.red-83-41-63.dynamicip.rima-tde.net ([83.41.63.18]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 27 Aug 2014 20:31:40 +0200 Original-Received: from ofv by 18.red-83-41-63.dynamicip.rima-tde.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 27 Aug 2014 20:31:40 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 34 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 18.red-83-41-63.dynamicip.rima-tde.net User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) Cancel-Lock: sha1:BFnZ/6+LSgIQ9cZngW/m2XQ3Yig= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:99429 Archived-At: solidius4747@gmail.com writes: > Because real parsing takes time and such a task, while possible using > Emacs Lisp, but is too much for current Emacs implementation. CEDET > does some nice optimizations to speed it up as fast as it can: idle > parsing, caching and incremental parsing to reduce computational time. > Consider someone using Clang to generate tag database: > https://github.com/drothlis/clang-ctags#performance: > > "Running clang-ctags over a much larger input, such as the entire llvm > C/C++ sources (7k files, 1.8 million lines of code) took 98 minutes > and a peak memory usage of 140MB." > > It's just 1.8 million lines of code. And that's Clang. That's a problem of clang-ctags being slow, not Clang being *so* slow, because Clang can compile its own sources on a fraction of time of those 98 minutes (15 minutes here on a 6 year old 4core machine, for an optimized build.) > GNU Global only > needs a few minutes to generate tag database for Linux kernel, which > is more than 14 million lines of code and more than 40k files. Do you > say Clang is worse than GNU Global? I'll say that parsing those 1.8 MLoc of C++ code is much more demanding than parsing 14 MLoc of C code. And the level of analysis GNU Global does is incomparable with a real compiler and it is a long stretch to put it on the same tool category as Clang (or even Semantic's own parser.) GNU Global has its uses, but C++ auto completion needs Clang, which is accurate but slow. I can't see how CEDET could be acceptably fast and accurate at the same time.