MIPS performance

I’m testing syncthing on a zsun wifi card reader which is based on the AR9331 with 64MiB RAM and a 400mhz mips CPU https://wiki.openwrt.org/toh/zsun/wifi-card-reader

It’s obviously slow but I just wanted to check if there are any possible performance tweaks I could use to improve it.

[5TF2H] 20:23:45 INFO: Single thread SHA256 performance is 2.7 MB/s using crypto/sha256 (2.6 MB/s using minio/sha256-simd).
[5TF2H] 20:23:50 INFO: Hashing performance with weak hash is 2.36 MB/s
[5TF2H] 20:23:54 INFO: Hashing performance without weak hash is 2.56 MB/s

Copying data to the node goes at 64KiB/sec

It’s using FPU emulation

That’s not really supposed to work. :slight_smile: But for small amounts of data I guess you might be fine. I’d set the following (advanced options):

  • progressUpdateIntervalS = -1 (reduces memory pressure when scanning if there are a lot of changes)
  • For each folder, to reduce concurrency and save memory:
    • copiers = 1
    • hashers = 1
    • pullers = 2
    • scanProgressIntervalS = -1 disable scan progress updates, minor but still
    • weakHashThresholdPct = 101 avoid double reads and CPU by disabling weak hashes

Increase the scan interval on folders as much as you can while keeping it as responsive as you need.

Also, if it does work, you might win this thread:

2 Likes

Oh, and consider exporting the environment variable GOGC=50 or even lower (the default is 100). Lower values means lower memory overhead due to GC, but correspondingly more CPU usage. Experiment. Add some swap if you haven’t already.

Also STNORESTART=1 will save you one process and the little memory it consumes, at the price of not having Syncthing itself manage restarts. Start Syncthing from systemd, svrun, or something similar instead.

Minimize the number of folders and number of connected devices.

Thanks, after those tweaks it still seems to transfer at around 64KiB but sometimes peaks up to 70KiB. It uses probably 5MB less memory and makes the device a little more responsive during transfers.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.