X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:to:in-reply-to:from:subject:message-id:date :mime-version:content-type:content-transfer-encoding; q=dns; s= default; b=AZKi/QuuG87A8/m/Tde9zCA9l9AVL43vYG33ySIlKl3y1QneC9Vlm rRoUWkGjrXRumM+/EvKhdNc3KTrb+iEFNDqBV3LclZA4MguVgjS0HtVKmCbBL+6G IGKPzOBPMAaojFjb9HdT53Zz9yCcMbuz9Hiu+gEBu2A8eoMvl/Xmys= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:to:in-reply-to:from:subject:message-id:date :mime-version:content-type:content-transfer-encoding; s=default; bh=r+VZIHHDdi4CfvdxarPdbY4CMTg=; b=niEundScZafd/dtRBDMk8DuuOk0M g35PV3gdTyt3xebHNan9H8JBsT6g4MTtei9/Wh+5VRxbrmmfe5aHgm5QdJ8M4nJc s5NGBYg9doDKsvG2ltK97CZsAHBPKBkWlMT5cB0V5l9c4M8W4VHl0zl3ifG70YlS Dj8vq3zkxWq7Rbg= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mout.gmx.com To: cygwin AT cygwin DOT com In-Reply-To: <560270DD.3090104@gmail.com> From: litter AT null DOT net Subject: Re: Bash / cygwin process spawning (?) performance very slow Message-ID: <5602C28F.7030902@null.net> Date: Wed, 23 Sep 2015 17:17:35 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-UI-Out-Filterresults: notjunk:1;V01:K0:ZqDdqzsoFAk=:kHQYL4JTyAS5IjpxR4wFv3 sZpTHXtw0PMqpj8AnedaALQlSLUstnj4SDGON1btXaypMsNGmWnWOR6EdUo9suGcu0B9Vx1NE xLUZ6ABjZZAoWRWSaqEcve3xa3yeFykmPf7fP7rdoBGgUI1yFvOikwGPT+VoHHrRktH6Dydqg 7VxBxJQ/MYx+yvV9ixjKSaCuc2CO4D4HzYemHKItNko+jXCFAiSyLQOSdZ/FMvzEi3g8vmxSw gG/HlfXOHUzrjVyi+b2LzMQ83pTxD1yoiqjanRD3AHJps0HeY8CWgoZdU7cFzFNjfLhWLOAMZ 1PlccKCvc8EUayEoqRCJ7MjZ3ejyt76kuxZjqaddWlMUZ2QGi9X0IfDoBP1xG6wi9QXbz3pIU yxbywJRwuIg6wBIpBOIp+ktVpNTUtYoLwWCwESgDdy5T6Bw2ZhUg0YHry3+plX5D+8/L+fmeF Fl5kY1r8XVD4Zacjl/uEuUQlJyCG+xgbvr4XNptKrUhzqvMuLkYh395nES8QlvthGp7OLkgKu LiBeDKAjMAiVFefzMse/S777ECUnWpzNhpMcL4Hu0d4XkzzJxkLdsuN3JYoY1tT6wyUPpSS3e Cqm4tm9vn6M/bA9//Ijvx5DjSw0C/e0lsG/o5c2mZcogF8dZw8loQYi7GVfzddsU73pVW9zOZ u7FuMZa2s/JVh8ag94OxlexiFMsB2egkBEdiVN+re8oR7sAGgdL+57C2UT1GjW1ZIVvvXpqFZ ELU4KGaGlNCrNaUy+TfJKZCq97sZF2w1rxN+vQ== >> for a file of 167 lines. Process Explorer showed a CPU load of 20% on bash.exe, which was almost completely Kernel time. >> Is such high Kernel load normal? > > may be. forks are time consuming and your command is spending all the > time in fork So why is it spending all its time in fork? That is the question. > In addition, I suspect your Antivirus is further slowing down the things. I don't run an Antivirus program > I have much better results with my cygwin > also with a much longer file > > $ wc -l cygcheck.out > 5220 cygcheck.out > > $ time cat cygcheck.out | while read i;do grep text $i;done > .. > real 0m0.288s > user 0m0.015s > sys 0m0.262s Thanks for your measurement, it confirms the issue is with my installation. Still the question remains, why is it so slow, spending all its time in kernel mode? Paul -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple