Microsoft’s exFAT system improves on Linux thanks to Sony

With Satya Nadella, the way of thinking about certain things has changed a lot. This affects the protagonist of this news, the exFAT file system. In 2012, Microsoft released its 64-bit Extended File Allocation Table (exFAT) file system as the successor to 32-bit FAT32. Seven years later, in 2019, the Redmond giant made a big reveal by announcing support for the exFAT format on Linux.

The exFAT file system will improve its performance on Linux

Fast forward three years to now and it looks like exFAT is about to get a big performance boost in the upcoming Linux 6.2, thanks to Sony’s latest efforts. Yuezhang Mo, an engineer at the Japanese tech giant, found that reducing directory entry rerouting helps exFAT perform better. And this is especially noticeable in the case of low-end processors. Mo explains it in his patch:

After scanning all directory entries, returns the empty directory entry, whether or not there are enough empty directory entries.

After this commit, it shows empty directory entries as follows:

1. Shows deleted directory entries if there are enough;

2. Indicate the deleted and unused directory entries that are at the end of the cluster chain, whether they are sufficient or not (added by this commit);

3. If there are no empty directory entries, provide the empty directory entries in the new cluster (Add by this commit).

This avoids repeatedly skipping directory entries, reduces CPU usage, and improves file and directory creation performance (especially on low-performance CPUs).

To reach this conclusion, tests were carried out with 5000 files. The interesting choice is that the improvement increases with the number of files. The biggest increase was almost 58%. Testing was performed on a SABER i.MX6 Lite development board using a Class 4 SD card:

Before After improve
1~1000 25.360s 22.168s 14.40%
1001~2000 38.242s 28.72s [sic] 33.15%
2001~3000 49.134s 35.037s 40.23%
3001~4000 62.042s 41.624s 49.05%
4001~5000 73.629s 46.772s 57.42%

Interestingly, this isn’t the first time Sony has released patches for exFAT that have improved performance. In April, Yuezhang Mo found that with DirSync enabled, there was an improvement of up to 85.4% in some cases.

Leave a Comment