Skip to content

hkatsura/AmorphousMemoryMark

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AmorphousMemoryMark

A macOS memory benchmark tool that measures read/write performance in GB/s.

Download on the Mac App Store

Features

  • Sequential benchmarks: 1 MiB block reads/writes, single-thread (T=1) and multi-thread (T up to 64)
  • Random benchmarks: 4 KiB block reads/writes, single-thread (T=1) and multi-thread (T up to 64)
  • Flexible test parameters: configurable iteration count, test data (random/zero), measurement size (128 MiB – 64 GiB), and interval (0 s – 10 s)
  • Tooltip: shows results in GB/s
  • Copy-pasteable results: export measurements as formatted plain text

Example Output

  Sequential Read 128KiB (T= 8) :   18.95 GB/s (memmove)
 Sequential Write 128KiB (T= 8) :   23.79 GB/s (bzero)
        Random Read 4KiB (T= 8) :   20.04 GB/s (memmove)
       Random Write 4KiB (T= 8) :   11.09 GB/s (bzero)
     Sequential Read 1MiB (T=1) :   10.06 GB/s (memmove)
    Sequential Write 1MiB (T=1) :   16.37 GB/s (bzero)
         Random Read 4KiB (T=1) :   10.33 GB/s (memmove)
        Random Write 4KiB (T=1) :    7.85 GB/s (bzero)

  Sequential Read 128KiB (T= 8) :   19.09 GB/s (rep movsb)
 Sequential Write 128KiB (T= 8) :   23.88 GB/s (rep stosb)
        Random Read 4KiB (T= 8) :   19.99 GB/s (rep movsb)
       Random Write 4KiB (T= 8) :   23.08 GB/s (rep stosb)
     Sequential Read 1MiB (T=1) :   10.34 GB/s (rep movsb)
    Sequential Write 1MiB (T=1) :   16.58 GB/s (rep stosb)
         Random Read 4KiB (T=1) :   10.06 GB/s (rep movsb)
        Random Write 4KiB (T=1) :   11.25 GB/s (rep stosb)

  Sequential Read 128KiB (T= 8) :   19.99 GB/s (temporal)
 Sequential Write 128KiB (T= 8) :   10.97 GB/s (temporal)
        Random Read 4KiB (T= 8) :   19.81 GB/s (temporal)
       Random Write 4KiB (T= 8) :   11.22 GB/s (temporal)
     Sequential Read 1MiB (T=1) :   14.28 GB/s (temporal)
    Sequential Write 1MiB (T=1) :    8.71 GB/s (temporal)
         Random Read 4KiB (T=1) :   10.43 GB/s (temporal)
        Random Write 4KiB (T=1) :    7.90 GB/s (temporal)

  Sequential Read 128KiB (T= 8) :   19.96 GB/s (non-temporal)
 Sequential Write 128KiB (T= 8) :   22.12 GB/s (non-temporal)
        Random Read 4KiB (T= 8) :   20.21 GB/s (non-temporal)
       Random Write 4KiB (T= 8) :   22.30 GB/s (non-temporal)
     Sequential Read 1MiB (T=1) :   14.07 GB/s (non-temporal)
    Sequential Write 1MiB (T=1) :   19.27 GB/s (non-temporal)
         Random Read 4KiB (T=1) :   10.30 GB/s (non-temporal)
        Random Write 4KiB (T=1) :   14.90 GB/s (non-temporal)

Requirements

  • macOS 10.9.5 or later
  • Xcode (to build from source)

Building

Open AmorphousMemoryMark/AmorphousMemoryMark.xcodeproj in Xcode and build the scheme. The app is sandboxed.

Architecture

The codebase is Objective-C and C, structured around a few key components:

File Role
AppDelegate Main UI controller — handles toolbar actions, test size selection, test orchestration
memmark Core memory benchmark engine
meminfo memory info utilities
DiskMark MemMark manages threaded read/write with configurable block size, threads, and duration
DiskUtil MemUtil human readable size string utility
DMTextView Custom text view with logarithmic bar graph rendering (matching CrystalDiskMark's visual style)
DMButton / DMButtonCell Custom button with dark mode support
DMMediaIcon Resolves storage device icons from IOKit kernel extension bundles
LinkTextField Clickable URL text field

How benchmarking works

AmorphousMemoryMark spawns threads to perform memory read/write measurements against a wired memory block.

Usage

  1. Click All (or an individual test button).
  2. When finished, press ⌘S to save a screenshot, or copy the plain-text results.

License

MIT License. See LICENSE for details.

UI design used with permission from the author of CrystalDiskMark.

Links