A few months ago I mentioned mcplay as an alternative to the time-honored but unfortunately departed cplay. mcplay is intended to be a close mimic to the dead program, written in C as opposed to Python. At the time I made no real distinction between the two, since my concern was mostly with function, but as yasen mentioned, I should have.

I had a few extra moments today to tinker with both of those in Arch, and I believe yasen was right: On extremely low-end hardware, the application built with C is probably preferable. Consider:

That’s cplay, and according to htop, Python is taking up about 1.1 percent of the 512Mb I have in this machine, which means roughly 5Mb. (I wanted to use this script to get a closeup of how much each one is using specifically, but with both cplay and the script relying on Python, the results were occluded.)

Now compare that with its clone.

mcplay is hovering around 0.4 percent of the same available memory, which puts it at about 2Mb. In both cases, the space taken up by the ogg123 application, which does the real work for both frontends, is a meager 0.4-0.6Mb depending on the file and the workload.

The difference between 2Mb and 5Mb on modern machines is barely noticeable; most applications these days take up spaces 20 or 30 times those amounts, and no one bats an eye. On machines as old as this one though, or on machines that suffer from a severe memory handicap, those three megabytes can be critical.

And remember that in this instance, we’re only talking about an application that runs against the console, maintains a list of file names and feeds them to an outside application for playback. Imagine a Python application that is quite sizable, running on a graphical desktop, requiring an assortment of additional derivatives to function, and you can extrapolate beyond those meager three megabytes.

So I will nod in acceptance that yasen was right, and I should have taken into account the fact that program weight can be directly attributable to their programming language. If you are also plunking along on your Pentium machine and you have the choice between programs, for the sake of memory use it might behoove you to look for alternatives that are written in other languages. 🙂