{
  "slug": "makalu",
  "term": "Makalu",
  "aliases": [
    "Makalu allocator"
  ],
  "definition": "Makalu is a persistent-memory allocator that combines protected heap metadata with recovery-time garbage collection.",
  "note": "Scope: Makalu manages allocation, not application transactions. Its runtime must recover the user's data, or the programmer must supply that recovery when using it alone. [readme]\n\nMechanism: Core metadata is protected; reconstructible auxiliary metadata can be persisted lazily. Recovery-time tracing reduces online persistence work. Collection starts from registered persistent roots after application recovery, with no running mutator. [paper]\n\nDeallocation: A transactional free may need to be deferred because recovery logs can still refer to the object. Reuse must wait until those references cannot become live again. [paper]\n\nAPI versions: Table 1 in the paper names MAK_collect, MAK_set_free_cb and MAK_safe_free. The pinned public header instead declares MAK_collect_off, MAK_set_defer_free_fn and MAK_free_imm. These are source-version distinctions, not interchangeable names to paste into code. [paper] [header]\n\nExample: A synthetic executable three-object graph shows why collection before root recovery can reclaim a subsequently restored object. It also separates reachable storage from a correct payload; neither result is a Makalu implementation test. [model]",
  "status": "research",
  "advantages": [
    {
      "text": "Rebuilding auxiliary state moves some persistence cost from ordinary allocation to recovery.",
      "citationIds": [
        "paper"
      ]
    }
  ],
  "limitations": [
    {
      "text": "Heap consistency does not establish application-data consistency.",
      "citationIds": [
        "readme"
      ]
    },
    {
      "text": "The paper uses conservative tracing, so pointer-like values can retain otherwise dead objects.",
      "citationIds": [
        "paper"
      ]
    },
    {
      "text": "Evaluation used DRAM-backed tmpfs and process crashes, not physical power-loss testing.",
      "citationIds": [
        "paper"
      ]
    }
  ],
  "related": [
    "persistent-memory",
    "crash-consistency",
    "nv-heaps",
    "mnemosyne",
    "write-ahead-log"
  ],
  "supersedes": [],
  "supersededBy": [],
  "firstSeen": null,
  "lastSeen": null,
  "updated": "2026-12-05",
  "citations": [
    {
      "id": "paper",
      "title": "Bhandari, Chakrabarti and Boehm. Makalu. OOPSLA 2016, pp. 677-694; DOI 10.1145/2983990.2984019. Sections 3-4, 9-10 and 13.",
      "url": "https://bpb-us-e1.wpmucdn.com/blogs.rice.edu/dist/5/7236/files/2016/09/oopsla2016-copyright-1s0zst5.pdf",
      "accessed": "2026-12-05"
    },
    {
      "id": "readme",
      "title": "HewlettPackard/Atlas, makalu_alloc README at d4fd983322a4e247724aa636f380aa023b927e0b: allocator and application responsibilities.",
      "url": "https://github.com/HewlettPackard/Atlas/blob/d4fd983322a4e247724aa636f380aa023b927e0b/makalu_alloc/README.md",
      "accessed": "2026-12-05"
    },
    {
      "id": "header",
      "title": "HewlettPackard/Atlas, makalu.h at d4fd983322a4e247724aa636f380aa023b927e0b: published API declarations.",
      "url": "https://github.com/HewlettPackard/Atlas/blob/d4fd983322a4e247724aa636f380aa023b927e0b/makalu_alloc/include/makalu.h",
      "accessed": "2026-12-05"
    },
    {
      "id": "model",
      "title": "Hesela. Recover roots before collecting: executable synthetic counterexample, tests and provenance.",
      "url": "https://hesela.dev/research/makalu/README.md",
      "accessed": "2026-12-05"
    }
  ],
  "provenance": [
    "Full OOPSLA paper reviewed, including the recovery protocol, implementation interface and evaluation method; DOI verified against ACM metadata.",
    "Public header and recovery example inspected at pinned HPE Atlas commit d4fd983322a4e247724aa636f380aa023b927e0b. Source API differs from the paper's terminology.",
    "The companion is an original exact-reachability graph model, not a reproduction of Makalu, conservative pointer scanning, allocator metadata recovery or benchmark performance."
  ]
}
