Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!feeds.news.ox.ac.uk!news.ox.ac.uk!news.stack.nl!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.008 X-Spam-Evidence: '*H*': 0.98; '*S*': 0.00; 'say,': 0.05; 'interpreter.': 0.07; 'alain': 0.09; 'counting': 0.09; 'percentage': 0.09; 'api': 0.11; 'cc:addr:python-list': 0.11; 'python': 0.11; 'language.': 0.14; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'numpy': 0.16; 'wrote:': 0.18; 'bit': 0.19; 'written': 0.21; 'saying': 0.22; 'cc:addr:python.org': 0.22; 'fraction': 0.24; 'lets': 0.24; 'typical': 0.24; 'cc:2**0': 0.24; 'header:In-Reply-To:1': 0.27; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; 'code': 0.31; 'another': 0.32; 'running': 0.33; 'fri,': 0.33; 'not.': 0.33; 'no,': 0.35; 'received:google.com': 0.35; 'major': 0.40; 'most': 0.60; "you're": 0.61; 'such': 0.63; 'wall': 0.65; 'bulk': 0.74; 'subject:This': 0.74; 'actually,': 0.84; 'calls,': 0.84; 'to:none': 0.92 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=j6cMifzCrMrE7aMEdeKuDLWMbTfAkxxPBCcNWDHu06A=; b=IiuNLfvszsgh3KIo/50SaiZwZQ60+NbSkiawWhsBQ1LDlwRuUP7bz3eK4MOiftWhLS oShPpvNQ1DiTARGcoZ2NZ/g+uss1bEBWlePpa2KT+yNSDgJBb93ZHRHIw3WPdyyA65QX oYV945UMwBSU1Ut1o8FCOtczSwxa/j32uY9LpmN+FUiPkYJ9SXBZ5et9TTVJ2l4QXj3K kSNFZsXtlUV8eXJ5mGtcS5uXUMJctP8Fw4clcpyS09z97iMkOCeCsYUBKt6Cy+T6/CCE EbywWPUM/qPIsPkjDuzpjiAZg/VfdJ3XaoBVCfCFzRaw/emzhdlcytksRdSf5ybtYh72 cF9A== MIME-Version: 1.0 X-Received: by 10.53.12.229 with SMTP id et5mr45262vdd.32.1401999503588; Thu, 05 Jun 2014 13:18:23 -0700 (PDT) In-Reply-To: <87tx7zi0i1.fsf@dpt-info.u-strasbg.fr> References: <8738fjkc2w.fsf@dpt-info.u-strasbg.fr> <87tx7zi0i1.fsf@dpt-info.u-strasbg.fr> Date: Fri, 6 Jun 2014 06:18:23 +1000 Subject: Re: OT: This Swift thing From: Chris Angelico Cc: "python-list@python.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 20 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1401999505 news.xs4all.nl 2948 [2001:888:2000:d::a6]:51080 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:72755 On Fri, Jun 6, 2014 at 6:07 AM, Alain Ketterlin wrote: >> Perhaps, perhaps not. My experience is that only a small percentage of >> the CPU time is spent in the Python interpreter. > > Basically, you're saying that a major fraction of python programs is > written in another language. An interesting argument... No, a major fraction of Python program execution time is deep inside code written in another language. In extreme cases, you might have a tiny bit of Python glue and the bulk of your code is actually, say, FORTRAN - such as a hefty numpy number crunch - which lets you take advantage of multiple cores, since there's no Python code running most of the time. And that's counting only CPU time. If you count wall time, your typical Python program spends most of its time deep inside kernel API calls, waiting for the user or I/O or something. ChrisA