タグ

メモリ管理に関するkyabのブックマーク (2)

  • Anatomy of a Program in Memory

    Memory management is the heart of operating systems; it is crucial for both programming and system administration. In the next few posts I'll cover memory with an eye towards practical aspects, but without shying away from internals. While the concepts are generic, examples are mostly from Linux and Windows on 32-bit x86. This first post describes how programs are laid out in memory. Each process

    Anatomy of a Program in Memory
    kyab
    kyab 2015/04/15
    "In Linux, if you request a large block of memory via malloc(), the C library will create such an anonymous mapping instead of using heap memory. " わかりやすい
  • malloc(3)のメモリ管理構造 VA Linux Systems Japan

    malloc()といえばC言語ではお馴染みのライブラリで、最も良く使用されるライブラリの一つです。しかしその分だけ何らかの不具合を経験した人も多いのではないでしょうか。書ではmalloc()、free()で確保、解放されるメモリリソースが内部的にどのように管理されているかを説明していきます。mallocライブラリの仕様を理解する事で、ライブラリ使用時に何らかの不具合が発生した際の手助けになればと思います。 ここではLinuxディストリビューションで標準的に使用されているglibcのmallocライブラリを扱います。今回の調査では次の環境を使用しています。 ディストリビューション :Debian sarge パッケージバージョン :glibc-2.3.2.ds1-22 OS : i386 Linux 書では、上記の通りi386アーキテクチャの場合について記述しています。

  • 1