Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S966270AbZLHVcy (ORCPT ); Tue, 8 Dec 2009 16:32:54 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S965733AbZLHVcs (ORCPT ); Tue, 8 Dec 2009 16:32:48 -0500 Received: from iolanthe.rowland.org ([192.131.102.54]:48461 "HELO iolanthe.rowland.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S965709AbZLHVcq (ORCPT ); Tue, 8 Dec 2009 16:32:46 -0500 Date: Tue, 8 Dec 2009 16:32:47 -0500 (EST) From: Alan Stern X-X-Sender: stern@iolanthe.rowland.org To: Linus Torvalds cc: "Rafael J. Wysocki" , Zhang Rui , LKML , ACPI Devel Maling List , pm list Subject: Re: Async resume patch (was: Re: [GIT PULL] PM updates for 2.6.33) In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1033 Lines: 27 On Tue, 8 Dec 2009, Linus Torvalds wrote: > > No, that's not needed. Unlike reads, writes can't move in front of > > data or control dependencies. Or so I've been lead to believe... > > Sure they can. Control dependencies are trivial - it's called "branch > prediction", and everybody does it, and data dependencies don't exist on > many CPU architectures (even to the point of reading through a pointer > that you loaded). Wait a second. Are you saying that with code like this: if (x == 1) y = 5; the CPU may write to y before it has finished reading the value of x? And this write is visible to other CPUs, so that if x was initially 0 and a second CPU sets x to 1, the second CPU may see y == 5 before it executes the write to x (whatever that may mean)? Alan Stern -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/