RX 9070 XT memory leak: amdkmdag.sys hoards RAM every time ANY program starts (test script inside)

I bought an RX 9070 XT to make my PC faster. It did, for about a week. Then it got sluggish, and Task Manager insisted with a straight face that nothing was using the memory.

The culprit turned out to be the display driver, amdkmdag.sys. Every time any program starts on Windows, it keeps a tiny souvenir and never gives it back: about 2 KB of kernel memory (non-paged and paged pool) per process start. Task Manager can’t see it, and only a reboot clears it.

A gaming PC starting a few thousand programs a day won’t notice. Mine runs developer tools and AI coding agents that start programs constantly, and after 9 days the driver had hoarded this:

Kernel pool tag Leaked allocations Size
File (non-paged) 4.1 million 1.57 GB
FMfn (paged) 9.7 million 3.4 GB
Ntfc, IoNm, D2d (paged) about 4 million each 1.3 GB

About 6.3 GB of RAM, gone. In the middle of a global RAM shortage, that’s roughly US$85 (about AU$125) at today’s prices, about US$9 a day. While the rest of us ration RAM, my driver is stockpiling it like toilet paper in March 2020.

Sound familiar?

  • RAM usage creeps up over days and the processes in Task Manager don’t add up
  • High non-paged pool or paged pool usage in Task Manager or RAMMap
  • poolmon shows the File and FMfn tags growing and never shrinking
  • The PC gets laggy after a long uptime, and a reboot fixes it

Check yours (a few minutes, no admin needed)

The script below starts whoami 4,000 times and counts the kernel file objects left behind. It doesn’t install or change anything. Mine reports 1.01 leaked per program start; a healthy PC should show close to 0.

Please reply with your result, especially if you have another Radeon (RDNA3 or RDNA2 would show whether this is new):

GPU:
Driver version:
File per process start:
The receipts: xperf trace and what I ruled out
  • Kernel pool trace (xperf, -PoolTag File+FMfn, allocation stacks) while starting 2,000 programs: 4,009 processes started, and 4,009 File objects were left outstanding, every one with amdkmdag.sys on the allocation stack.
  • On driver 32.0.32015.2008 the frames are always amdkmdag+0x6707AF > +0x66F805 > +0x4C5C6D, called from Windows’ process-creation path. That call site ran 4,010 times.
  • The leaked objects have no open handles, so a reference is never released.
  • Same leak on three drivers: 32.0.22042.14002 (May 2026), Adrenalin 26.8.1 (32.0.31041.1004) and 26.9.2 (32.0.32015.2008).
  • No change after: disabling the integrated Radeon graphics, stopping every AMD service and closing Adrenalin, or unloading Sandboxie (the only non-Microsoft file system filter).
  • System: Ryzen 9 9950X3D, MSI B650M GAMING WIFI (BIOS 1.D4), 32 GB RAM, Sapphire RX 9070 XT, Windows 11 Pro 25H2 (build 26200.9457).

Filed with the AMD Bug Report Tool too, and I’m happy to share the full trace files privately with AMD.

Test script (Test-ProcessStartPoolLeak.ps1)

Save as Test-ProcessStartPoolLeak.ps1, then run powershell -ExecutionPolicy Bypass -File .\Test-ProcessStartPoolLeak.ps1

<#
.SYNOPSIS
  Measures how many kernel FILE objects are leaked per process start.

.DESCRIPTION
  Starts a short-lived process (whoami.exe) many times and compares the number of
  outstanding kernel pool allocations for the 'File' tag (non-paged) and the 'FMfn'
  tag (paged, Filter Manager file-name cache) before and after, against an idle
  window of the same length.

  A healthy system returns to about 0 leaked File objects per process start.
  The affected system returns about 1.0 per process start, and the objects are
  never freed until reboot.

  No administrator rights are needed. Nothing is installed or changed.
  Counters come from NtQuerySystemInformation(SystemPoolTagInformation), the same
  source poolmon uses.

.PARAMETER Count
  Number of processes to start per round (default 2000).

.PARAMETER Rounds
  Number of start/idle rounds (default 2).

.EXAMPLE
  powershell -ExecutionPolicy Bypass -File .\Test-ProcessStartPoolLeak.ps1
#>
param([int]$Count = 2000, [int]$Rounds = 2)

Add-Type -TypeDefinition @"
using System; using System.Runtime.InteropServices;
public static class PoolTagCounters {
  [DllImport("ntdll.dll")] static extern int NtQuerySystemInformation(int cls, IntPtr buf, int len, out int ret);
  const int SystemPoolTagInformation = 22;
  // Returns outstanding allocations: [0] = 'File' non-paged, [1] = 'FMfn' paged.
  public static long[] Read() {
    int len = 4 << 20; IntPtr buf = Marshal.AllocHGlobal(len); int ret;
    try {
      int st = NtQuerySystemInformation(SystemPoolTagInformation, buf, len, out ret);
      if (st != 0) throw new Exception("NtQuerySystemInformation failed: 0x" + st.ToString("X8"));
      int n = Marshal.ReadInt32(buf); long[] res = new long[2];
      for (int i = 0; i < n; i++) {
        IntPtr e = (IntPtr)((long)buf + 8 + (long)i * 40);   // SYSTEM_POOLTAG, x64 layout
        uint tag = (uint)Marshal.ReadInt32(e);
        if (tag == 0x656C6946) res[0] = (long)Marshal.ReadInt32(e, 24) - Marshal.ReadInt32(e, 28); // 'File'
        if (tag == 0x6E664D46) res[1] = (long)Marshal.ReadInt32(e, 4) - Marshal.ReadInt32(e, 8);   // 'FMfn'
      }
      return res;
    } finally { Marshal.FreeHGlobal(buf); }
  }
}
"@

$exe = Join-Path $env:windir 'System32\whoami.exe'

function Start-Children([int]$n) {
  for ($i = 0; $i -lt $n; $i++) {
    $psi = New-Object Diagnostics.ProcessStartInfo $exe
    $psi.UseShellExecute = $false
    $psi.RedirectStandardOutput = $true
    $psi.CreateNoWindow = $false        # share this console, so no extra conhost.exe per start
    $p = [Diagnostics.Process]::Start($psi)
    $null = $p.StandardOutput.ReadToEnd()
    $p.WaitForExit()
    $p.StandardOutput.Dispose()
    $p.Dispose()
  }
}

function Measure-Window([string]$label, [scriptblock]$work) {
  [GC]::Collect(); [GC]::WaitForPendingFinalizers(); Start-Sleep 2
  $before = [PoolTagCounters]::Read(); $sw = [Diagnostics.Stopwatch]::StartNew()
  & $work
  [GC]::Collect(); [GC]::WaitForPendingFinalizers(); Start-Sleep 5
  $after = [PoolTagCounters]::Read()
  [pscustomobject]@{ Window = $label; Seconds = [int]$sw.Elapsed.TotalSeconds
                     FileLeaked = $after[0] - $before[0]; FMfnLeaked = $after[1] - $before[1] }
}

Write-Host "Starting $Count x $Rounds short-lived processes ($exe)..." -ForegroundColor Cyan
$results = for ($r = 1; $r -le $Rounds; $r++) {
  $start = Measure-Window "start $Count processes (round $r)" { Start-Children $Count }
  $start
  $idle = [Math]::Max(5, $start.Seconds - 7)
  Measure-Window "idle ${idle}s (round $r)" { Start-Sleep $idle }
}
$results | Format-Table -AutoSize

$starts = $results | Where-Object Window -like 'start*'
$idles  = $results | Where-Object Window -like 'idle*'
$total  = $Count * $Rounds
$file   = ($starts | Measure-Object FileLeaked -Sum).Sum / $total
$fmfn   = ($starts | Measure-Object FMfnLeaked -Sum).Sum / $total
$drift  = ($idles | Measure-Object FileLeaked -Sum).Sum
"Outstanding after starts, per process start:  File = {0:N2}   FMfn = {1:N2}" -f $file, $fmfn
"Background drift across all idle windows: File {0:+#;-#;0} (other activity on the PC; should be small next to the start rounds)" -f $drift
"Expected on a healthy system: File close to 0 per process start."

1 Like

Seriously impressive write-up, thanks for documenting this with actual poolmon numbers instead of just vibes. Since you already filed with the AMD Bug Report Tool, one thing worth checking is whether it reproduces on the previous driver version — a clean install with DDU and a rollback would show if this is a regression. I’d also be curious whether hardware-accelerated GPU scheduling matters here; toggling HAGS on or off could rule that path in or out. Planning to run your script myself this weekend to compare.

1 Like

I have been dealing with this problem since FEBRUARY. I rebuilt my PC in Jan last year with a Ryzen 9950X, then a few months later bought a Radeon 9070XT. It ran like a beast for months until around Feb this year when Windows update suddenly, literally while I walked away for lunch, decided to willy nilly update the driver for the 9070 and reboot. Within a couple days I started noticing the leak. Reminiscent of the days of Windows Vista.

Researched endlessly. Never could figure it out. Like you, I am a developer. Mostly vs code and embedded firmware compiling. TONS of git actions. Finally today I noticed I was using 55GB of my 64, and was thoroughly pissed. Claude ended up discovering the problem and open file handles were using up over 18GB of memory after 33 days of uptime.

Right now I’m rolled back to the Nov 2025 driver, and this problem exists. But if you disable the 9070XT, the problem disappears.

Gave these details to Grok, and it found this thread. It’s absolutely infuriating that I’ve been dealing with this for months.

2 Likes

Thanks both, this is really useful.

@techrobert I’ve tried three drivers so far: 32.0.22042 (May 2026), 26.8.1 and 26.9.2. All three leak at the same rate. I haven’t done a DDU clean install. I’ve just tested HAGS: turned it off, rebooted and re-ran the script. No change, still 1.01 leaked per program start, so that one’s ruled out. It also still happens after Windows updated itself to 11 26H2 (build 26300). Your script result would be great, whatever it shows.

@bitNine Sorry you’ve been fighting this since February, but your post really helps. Three things in it matter:

  • The Nov 2025 driver leaks on your PC today, so it isn’t only the newest drivers. It doesn’t prove the leak existed back in 2025, though. Yours started in February after an update, so something else that changed then (Windows, or a part of the driver package a rollback doesn’t replace) could be involved.
  • Disabling the 9070 XT stops it. That fits my trace, where every leaked object was created by the card’s driver. It doesn’t rule out the driver reacting badly to something else on the PC.
  • 18 GB after 33 days of git and firmware builds is the same pattern as mine: lots of short-lived processes.

Could you run the script and post your number with your driver version? And if you can spare five minutes, file it with the AMD Bug Report Tool too (it installs with Adrenalin; search the Start menu for “AMD Bug Report Tool”) and mention this thread. One report is easy to ignore; several matching ones are much harder to.

Until there’s a fix, the only things I’ve found that help are rebooting before it bites, and a large fixed page file so the PC doesn’t run out of memory in the meantime.

It’s disappointing to see I’m not the only one. I really don’t want to regret picking Radeon over NVIDIA, so fingers crossed AMD picks this up.

After finding this last night, I decided to start just rolling back drivers. I looked at driver history and noticed that on 1/29 windows update installed the Dec 2025 driver. So I went from the Nov 2025 driver back to Oct 2025, no fix. To September 2025 drivers, no fix, back to the June driver, with no fix. I had been on the Oct 2025 driver prior to the windows update at the end of Jan. So… yeah, something else came along with it that started causing this, but it’s definitely caused by the 9070 driver.

I had rolled back to the Nov 2025 driver because, again, about a month ago windows update again pushed a driver update, and one of my monitors started looking washed out with HDR on every time it’d wake. I’d have to power cycle to get it working again. Rolling back did not help. However, at least installing the latest driver from a couple days ago has fixed the problem.

Your script results:

Window                         Seconds FileLeaked FMfnLeaked
------                         ------- ---------- ----------
start 2000 processes (round 1)      18       2015       7990
idle 11s (round 1)                  16        -19         65
start 2000 processes (round 2)      18       2003       7910
idle 11s (round 2)                  16          0        -39


Outstanding after starts, per process start:  File = 1.00   FMfn = 3.98
Background drift across all idle windows: File -19 (other activity on the PC; should be small next to the start rounds)

I also filed a bug report, and will probably start hammering on them a bit harder to get it fixed. This is incredibly frustrating. There are times when I will just be trying to perform a git operation, and I end up waiting 5-10 seconds just to make a new branch within vscode. It’s absurd.

edit: Checking on what else was updated 1/29, it was KB5074109 (Jan Windows cumulative update build 26100.7623), KB5077181, a windows security platform update, and updates to .NET 8/9.

Similar symptoms on a Thunderobot HX 370 / Radeon 890M here, Windows 26300.9711, driver 32.0.32015.7029. WPR shows amdkmdag.sys+0x4C2E7D on File allocations still outstanding about 40 seconds after short-lived processes exit.

Codex Desktop’s frequent Git launches seem to make it worse. Quitting nearly stops the growth but doesn’t reclaim the pool. I’ve emailed AMD too. Has anyone found a workaround short of rebooting?

1 Like

I ran your script and got the following output:

Window Seconds FileLeaked FMfnLeaked
------ ------- ---------- ----------
start 2000 processes (round 1) 21 2050 8167
idle 14s (round 1) 19 -11 -53
start 2000 processes (round 2) 21 1995 8024
idle 14s (round 2) 19 162 688

Outstanding after starts, per process start: File = 1.01 FMfn = 4.05
Background drift across all idle windows: File +151 (other activity on the PC; should be small next to the start rounds)
Expected on a healthy system: File close to 0 per process start.

I do not know what to tell AMD to describe this bug, but I submitted what made sense to me and referenced this thread. I also figure posting in this thread might help since it has been referenced in multiple bug submissions, now.

I am on Windows 11 25H2 and boot my PC each time I use it for gaming, local AI, or browsing so have never run into a performance problem on 32GB of system RAM.

1 Like

Same leak on an APU: Radeon 8060S (Ryzen AI MAX+ 395, Strix Halo, RDNA 3.5). It’s still there on both 26.10.x drivers.

GPU: Radeon 8060S (integrated), Ryzen AI MAX+ 395
Driver version: 32.0.32015.12012 (26.10.2 Optional). I also tested 32.0.32015.7029 (26.10.1) and 32.0.23017.1001.
File per process start: 0.35 to 12.3 depending on the run. D2d and IoFE are the steadier signal here.

I measured with my own poolmon-style sampler rather than your script: 1000 cmd /c exit starts, with the idle rate subtracted. Results per start:

Driver D2d IoFE File
32.0.23017.1001 2.45 4.81 2.54
32.0.32015.7029 (26.10.1) 5.34 7.22 0.35
32.0.32015.12012 (26.10.2) 3.59 8.65 12.32

A WPR Pool trace with stacks puts amdkmdag.sys on 98% of the surviving D2d allocations and 51% of the surviving File allocations. Most of them came from processes that had already exited. The dominant stack is ntoskrnl > amdkmdag.sys > ntoskrnl.

Same use case as yours: dev tools and AI coding agents starting about 10 programs a second. That’s 1-3 GB/h of kernel pool, and a reboot every few hours. So this is RDNA4 (you), RDNA 3.5 (890M on Ryzen AI 300 and 8060S here), and it’s on both discrete and integrated GPUs. A Ryzen AI 300 owner on the Framework forum found that disabling the Radeon drops the leak to 0:

I filed it with AMD as well.

1 Like

Man, that is a brutal memory leak, especially with heavy developer workloads and AI coding agents spawning thousands of short-lived processes daily. That kind of driver bug (amdkmdag.sys) completely bypasses Task Manager because the kernel pool allocations belong directly to the driver’s non-paged and paged memory pools rather than standard user-space working sets.

It makes total sense why it wrecks performance after a week of uptime—losing gigabytes of kernel RAM to unreleased file objects (File, FMfn, etc.) will instantly trigger excessive paging and latency once the pool runs dry.

For context, I haven’t personally run into this exact RDNA 4 (amdkmdag.sys) leak on a daily machine, but driver-level memory leaks in the Windows kernel pool (often tied to context creation, handle leaks, or DirectX/Vulkan interop with background CLI tools) have popped up in past AMD architectures under heavy process churning.

Have you tried checking if disabling features like Hardware-Accelerated GPU Scheduling (HGS), AMD Software Overlay, or reducing background monitoring tools (like MSI Afterburner or telemetry services) changes the leak rate? Also, reporting this directly through AMD Bug Report Tool with your xperf / WPA traces is definitely the right move.