Urgent.News

What's breaking now, across thousands of outlets.

Tech

Why my Mac memory app doesn't try to empty your RAM

Most Mac cleaners show you a big number and offer to make it smaller. That number is usually cached memory, which macOS is putting to good use, and shrinking it makes your Mac slower, not faster. I wanted a tool that tells me what's actually going on, so I built Boost , a free and open source menu bar app for memory and disk space. What "free memory" can mean on macOS On Windows, tools like Mem…

Most Mac memory management tools display a high number and promise to reduce it. This figure typically represents cached memory, which macOS utilizes effectively. Reducing this figure would actually slow down the Mac, not speed it up. To address this, I created Boost, a free and open-source menu bar app for memory and disk space.

Boost provides a clear depiction of what "free memory" means on macOS. In contrast to Windows, which employs the EmptyWorkingSet command to release a process's memory pages to the pagefile, macOS lacks a public equivalent. Apple's kernel source indicates this. Even if it were possible, compressing memory before swapping is more efficient and allows for faster reading of compressed pages from RAM compared to reading them back from an SSD.

Therefore, Boost relies on what macOS offers. Boost uses Apple's memory_pressure tool, which signals the kernel to release idle pages and compress them. Boost captures readings before and after this process, reporting only what was genuinely utilized. It refrains from closing applications, deleting files, or requesting a password, and halts early if swapping begins.

For a typical run, this amounts to a few hundred megabytes to around a gigabyte of freed memory. If your Mac isn't memory-constrained, there is minimal idle memory to recover, and Boost informs you that your Mac is functioning optimally rather than creating additional work. The Settings option offers an aggressive mode that pushes the limits harder.

It is disabled by default, as excessive pressure may lead the kernel to terminate processes on its own. The more beneficial feature is Pause. Boost freezes an app and its helper processes with the SIGSTOP signal, using no CPU while preserving its state, and resumes it with SIGCONT. You can designate apps to pause automatically after 5 to 60 minutes in the background, and Boost promptly restores each one when you switch to it.

Two safeguards prevent issues. If Boost crashes or is terminated, a watchdog restarts all frozen processes, ensuring nothing stalls. Additionally, a hard-coded list of system processes (Dock, WindowServer, Finder, loginwindow, and a few more) cannot be paused, as freezing these would halt the desktop. The Disk tab lists only caches that the tool can rebuild, such as Homebrew, npm, pip, uv, Cargo, Gradle, Xcode DerivedData, simulator caches, app caches, and logs.

It does not interfere with Downloads, node_modules found by name, or iOS backups. Removal options are strictly controlled, with multiple checks: an allowlist of items permitted for scanning, and a second check of the resolved path just before deletion. A symlink within a cache pointing to your documents is a common mistake in these tools, and Boost includes a test to uncover such vulnerabilities.

Projects like old node_modules, Rust target, SwiftPM .build, and virtualenvs are moved to the Trash with Undo functionality. The remaining History feature records memory usage every minute, charted over 2, 24, or 7 hours, displaying peak, average, and frequency of swaps. Alerts notify when swap exceeds 1, 2, or 4 GB, or when memory remains tight for a full minute, specifying the offending application.

Sampling occurs natively through sysctl and libproc, rather than using ps, which costs 111ms per refresh and maintains about 20% idle CPU. There are no analytics, telemetry, update checks, or network access. To install, use brew install --cask kernel-hunter/boost/boost or build it from source with Command Line Tools; Xcode is not required. macOS 14 or later, Apple silicon, and Intel are supported, under the GPL-3.0 license.

Boost is signed with a local certificate, not notarized, and the cask removes the quarantine flag. There's also a 30-second video overview with audio. I would appreciate feedback on what a memory tool should display when there's nothing to fix.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

How I keep Cloudflare under $5 (and what quietly runs up your bill)

I run a few sites on Cloudflare's $5 Workers plan. The base plan covers a lot more than people expect. Most of the surprise bills I've read about come from a few products doing far more work than…

  • Cloudflare's $5 Workers plan includes 10 million requests and 30 million CPU milliseconds per month
  • Enable billing notifications to avoid surprise charges from resource-intensive applications
  • Serve static files directly to take advantage of free and unlimited usage

StrideCast

This is a submission for the Hacktoberfest Open-Source AI Challenge Week 1: Touch Grass What I Built StrideCast is a mobile-first PWA that writes and narrates a podcast for your run, timed to your…

  • StrideCast is a mobile-first Progressive Web App (PWA)
  • Generates personalized podcast based on runner's preferences
  • Works offline with voice synthesis by Kokoro

More from Saturday 10 October →