xdu/README.md
2026-03-23 12:38:40 -05:00

1.1 KiB

xdu

Just a tool that implements 'du -s' behavior using OpenMP. This conforms to IEEE Std POSIX 1003.1-2024 rather than any specific OS, or distribution behaviors. This shouldn't impact much as most implementations I know of generally conform to POSIX.

Building

Just a standard meson meson project.

meson setup build
meson compile -C build

Very anecdotal performance findings

I just ran this, and diskus in my home directory and measured with time. I did it numerous times. Here are just the last results I got.

diskus 2.67s user 85.20s system 683% cpu 12.857 total
xdu 23.47s user 46.78s system 878% cpu 7.998 total

So around about a 40% improvement give or take on each run. I'm not really looking to run an entire benchmark on du implementations here I just wanted to see how OpenMP would perform, and it performs pretty well.

There are further improvement possibilities with batching tasks and such, but I'll leave that in case I get some crazy idea into making this a full du implementation.