Saratov Linux User Group
 help / color / mirror / Atom feed
From: Paul P Komkoff Jr <i@stingr.net>
To: sarlug@lug.ru
Subject: Re: [Sarlug] Swap
Date: Thu, 1 May 2003 13:46:19 +0400
Message-ID: <20030501094619.GA5041@stingr.net> (raw)
In-Reply-To: <200305011009.30208.amodeus@pisem.net>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160

Replying to Amodeus:
> Программа FemLab и она кажется/ использует API  ОСи для работы с 
> памятью и файлом подкачки...

Работают с памятью и с файлом подкачки минуя ОС только "хакеры" и полные
отморозки.

> Эта программа использует библиотеки матлаба для рассчётов методом 
> конечных элементов. Каждый элемент в памяти занимает дохрена 
> места и соответственно ей надо достаточно много места в памяти 
> для работы.
> А кстати, я задал вполне кокретный вопрос:
> Сможет ли ЛИНУКС работать с таким свопом(12 гигов)?

Линукс, не линукс
Ты в курсе, почему винда обычная не даёт столько памяти под своп отвести?

Потому что в общем случае для работы с такими объёмами памяти нужно
использовать нетривиальные методы

поясняю
Адресное пространство процесса на i386 равно 4 гига. Из этого какая-то часть
отводится под ведро (ну, при желании можно сделать 0.5/3.5, хотя обычно
делают что-то типа 2/2 - винда кстати так делает).
Процесс НЕ МОЖЕТ одним махом сказать malloc мне 12 гигов, пожалуйста.
Работать с таким объёмом памяти можно или через anonymous mappings, или
через shmfs.

Далее. 12 гигов, это 3145728 страниц. На каждую страницу выделяется page
table entry, или pte. Как минимум. То есть, мы имеем минимум 3145728 * (4 +
4 + 4) = 37748736 метров на каждый процесс, который мапит себе эти страницы.

Достаточно?
Понятно, почему винда со спичками играться не даёт? :)

P.S. А вообще читайте маны, они рулёз.
     http://www.csn.ul.ie/~mel/projects/vm/guide/html/understand/
     Understanding The Linux Virtual Memory Manager

- -- 
Paul P 'Stingray' Komkoff Jr /// (icq)23200764 /// (http)stingr.net
 This message represents the official view of the voices in my head
-----BEGIN PGP SIGNATURE-----

iD8DBQE+sOzoyMW8naS07KQRA04YAJwJ3yLgZKmAJgz/WIKt8YXeLfEP9gCgjpdG
w5PmzewZlXl1d6oLA6zalCg=
=qzRX
-----END PGP SIGNATURE-----


  reply	other threads:[~2003-05-01  9:46 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-30  8:24 Amodeus
2003-04-30  8:57 ` Евгений В. Хорохорин
2003-04-30 10:00   ` Amodeus
2003-04-30 13:11     ` Евгений В. Хорохорин
2003-04-30 16:53     ` Paul P Komkoff Jr
2003-04-30 18:27       ` Alex
2003-05-01  5:26         ` Amodeus
2003-05-01  7:01           ` [Sarlug] Swap [JT] Roman Bogorodskiy
2003-05-01  7:18           ` [Sarlug] Swap Alex
2003-05-01  7:25           ` Alex
2003-05-01  7:59             ` Roman Bogorodskiy
2003-05-01 17:35             ` Amodeus
2003-05-03  3:55           ` Аляткин Дмитрий
2003-05-04  4:05             ` Amodeus
2003-05-01  8:50         ` Paul P Komkoff Jr
2003-05-01  6:09       ` Amodeus
2003-05-01  9:46         ` Paul P Komkoff Jr [this message]
2003-05-01 17:48           ` Amodeus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030501094619.GA5041@stingr.net \
    --to=i@stingr.net \
    --cc=sarlug@lug.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Saratov Linux User Group

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/sarlug/0 sarlug/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 sarlug sarlug/ http://lore.altlinux.org/sarlug \
		sarlug@lists.lug.ru sarlug@lug.ru
	public-inbox-index sarlug

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.sarlug


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git