mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
Automatically integrates git build information into executables.
Usage:
func.exe -V
adnl-pong -V
validator-engine -V
and so on.
Result will be shown in the following format:
Func build information: [ Commit: d8b751d7a5
, Date: 2021-02-27 14:34:41 +0200]
This commit is contained in:
parent
41a3418b7b
commit
bab4c1637e
40 changed files with 492 additions and 78 deletions
|
@ -26,17 +26,17 @@
|
|||
namespace ton {
|
||||
class LoadSpeed {
|
||||
public:
|
||||
void add(td::size_t size, td::Timestamp now);
|
||||
void add(std::size_t size, td::Timestamp now);
|
||||
double speed(td::Timestamp now = td::Timestamp::now()) const;
|
||||
friend td::StringBuilder &operator<<(td::StringBuilder &sb, const LoadSpeed &speed);
|
||||
|
||||
private:
|
||||
struct Event {
|
||||
td::size_t size;
|
||||
std::size_t size;
|
||||
td::Timestamp at;
|
||||
};
|
||||
mutable td::VectorQueue<Event> events_;
|
||||
mutable td::size_t total_size_{0};
|
||||
mutable std::size_t total_size_{0};
|
||||
|
||||
double duration() const;
|
||||
void update(td::Timestamp now) const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue