fopen() when used with LittleFS is ~15 times slower than with FATFileSystem when using it on the QSPI flash on the DISCO-L475VG-IOT01A board. My test script:
Timer t;
t.start();
FILE *write_file = fopen("/fs/weights/y_pred_some_file.idx", "w+");
t.stop();
printf("fopen took %d ms.\n", t.read_ms());
This takes between 129 and 151 ms. on my board with LittleFS, but only 10-11 ms. with FATFileSystem.
@geky
[X] Question
[ ] Enhancement
[X] Bug
Internal Jira reference: https://jira.arm.com/browse/MBOCUSTRIA-1497
This is more likely due to directory structure layout than QSPI specifically. I'm guessing it's related to https://github.com/ARMmbed/littlefs/issues/75. Unfortunately all I can say right now is that I am planning on looking at it but it will take time.
@geky Thanks for pointing me to that issue.
Shall this be closed ? As it's being tracked in littlefs repo issue 75
If anyone follows this one, please follow ARMmbed/littlefs#75.
I'll close this as there is an issue related in the upstream repository.