From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: From: Ivan Adzhubey To: ALT Linux Sisyphus discussion list Subject: Re: [sisyphus] Shared memory - HELP PLEASE! Date: Thu, 25 Mar 2004 03:24:31 -0500 User-Agent: KMail/1.5.4 References: <20040223182241.028ed881.iadzhubey@rics.bwh.harvard.edu> <200403250217.54298.iadzhubey@rics.bwh.harvard.edu> <20040325104429.19718769.bga-no-spam@kovgok.ru> In-Reply-To: <20040325104429.19718769.bga-no-spam@kovgok.ru> MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-r" Content-Transfer-Encoding: 8bit Content-Disposition: inline Message-Id: <200403250324.31415.iadzhubey@rics.bwh.harvard.edu> X-Authentication-Info: Submitted using SMTP AUTH at out007.verizon.net from [68.163.158.108] at Thu, 25 Mar 2004 02:24:51 -0600 X-BeenThere: sisyphus@altlinux.ru X-Mailman-Version: 2.1.4 Precedence: list Reply-To: ALT Linux Sisyphus discussion list List-Id: ALT Linux Sisyphus discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Mar 2004 08:24:54 -0000 Archived-At: List-Archive: On Thursday 25 March 2004 02:44 am, Grigory Batalov wrote: > On Thu, 25 Mar 2004 02:17:54 -0500 > > man shmget: > > ...A new shared memory segment, with > size equal to the value of size rounded up to a multiple of PAGE_SIZE, > is created... То есть должно быть: size = [1..1024] shmblock = 1024 (или 1 * PAGE_SIZE) size = [1025..2047] shmblock = 2048 (или 2 * PAGE_SIZE) size = [2048..3071] shmblock = 3072 (или 3 * PAGE_SIZE) и тд. Вместо этого получаем: size = [1..1024] shmblock = 0 size = [1025..2047] shmblock = 4096 size = [2048..4095] shmblock = 8192 size = [4096..5119] shmblock = 16384 и тд. Какое же это rounded up to a multiple of PAGE_SIZE, даже если например PAGE_SIZE == 4096? -- Иван