delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/06/30/22:37:07

X-Spam-Check-By: sourceware.org
Message-ID: <44A5DFC3.E9FF7B58@dessent.net>
Date: Fri, 30 Jun 2006 19:36:51 -0700
From: Brian Dessent <brian AT dessent DOT net>
X-Mailer: Mozilla 4.79 [en] (Windows NT 5.0; U)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: rsync over ssh hang issue understood
References: <44A348D1 DOT 6070908 AT netbauds DOT net> <ba40711f0606291839p2e1d7b10l7befd8cf2cc2d1a7 AT mail DOT gmail DOT com> <44A507F8 DOT 4030409 AT netbauds DOT net> <44A53F4B DOT 4070503 AT netbauds DOT net> <e83hnt$lve$1 AT sea DOT gmane DOT org> <44A57EC6 DOT 2060805 AT netbauds DOT net> <e845jo$4s6$1 AT sea DOT gmane DOT org>
X-IsSubscribed: yes
Reply-To: cygwin AT cygwin DOT com
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

mwoehlke wrote:

> Um... probably? Did you try looking at them? There is an
> InterlockedExchangeAdd (I think that's the right name... anyway, you
> feed it a pointer and a constant, and you get back the previous value).
> At any rate, anything Linux can do in assembly, Windows can also do,
> also in assembly, with it's own __asm keyword. The syntax is a little
> different, but it's there, and for something as speed-sensitive as I
> would guess pipes are, this sort of optimization is probably a Good Thing.

Maybe you guys ought to read the existing source code before discussing
this.  There are already dozens of calls to InterlockedIncrement,
InterlockedDecrement, InterlockedExchange, and
InterlockedCompareExchange in the codebase, and if you look at winbase.h
you'll see that these have been #defined to be inline assembly versions
of the functions.

Brian

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019