facebook / facebook/folly

performance issue for AsyncLogWriter with "std::array<std::vector<std::string>, 2> queues"

Open
#1,398 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
30.5k
Forks
5.9k
PR merge metrics
No merged PRs in 30d

Description

In AsyncLogWriter class, struct data has "queues" data member, defined as std::array, 2>, to buffer the output log messages, it's just a FIFO queue.

vector type may cause memory reallocation while data puts into the queue continuously, I think it will be better to change it to list type, to solve this performance issue.

thanks.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.