Commit Graph

4 Commits

Author SHA1 Message Date
Wilko Nienhaus
011c6b76ee move uint64s to beginning of struct to ensure they are 64-bit aligned
See https://golang.org/pkg/sync/atomic/#pkg-note-BUG for reference:
"The first word in (...) an allocated struct (...) can be relied up to
be 64-bit aligned"

This fixes an "unaligned 64-bit atomic operation" panic on 32-bit ARM,
(in my case a Raspberry Pi 4, running 32-bit Raspbian). The panic
happens (at least) during the first login after a service (re)start.
2021-04-02 10:35:29 +03:00
David Christofas
a22b7d6844 resolve linter issues 2021-02-24 16:24:36 +01:00
Florian Schade
af870e005e add more tests and benchmark for cache
refactor cache to use atomic uint
2021-01-19 23:23:41 +01:00
Florian Schade
f13530425a move cache to sync package
rollback indexer map
use sync.pool for cache entries
add tests for cache
remove main locks from nrwmutex and use sync.map and sync.pool instead
bump dockerfile go version
2021-01-19 23:23:41 +01:00