summaryrefslogtreecommitdiffstats
path: root/util/datetime/systime.cpp
Commit message (Collapse)AuthorAgeFilesLines
* [util] getting rid of LUT in DayOfYearToMonthtobo2025-02-271-28/+5
| | | | commit_hash:9ec33d0cbe2da6aeea6e8d02fdaed5f45b6e3534
* [util] speedup GmTimeR outside LUT intervaltobo2025-02-181-70/+109
| | | | commit_hash:d57be220df393c193619ef5ed129ec4436540629
* [util] GmTimeR: use LUT for the tm_yday -> tm_mday conversionswarmer2025-02-111-68/+29
| | | | | Replacing binary search with a look-up table. The performance of which does not depend on the branch predictor, and conversion works equally fast for any dates. commit_hash:fefe9665d0d4b51c2ae09ec2b2816aed30caa57b
* [util] GmTimeR: speedup a bittobo2025-02-101-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | perf before ``` ------------------------------------------------------------------------------- Benchmark Time CPU Iterations ------------------------------------------------------------------------------- BM_GmTimeR 3.61 ns 3.61 ns 194952699 BM_GmTimeRRandom/last_hour 5.04 ns 5.04 ns 136121940 BM_GmTimeRRandom/last_day 5.03 ns 5.03 ns 139883239 BM_GmTimeRRandom/last_month 8.03 ns 8.03 ns 87839823 BM_GmTimeRRandom/last_year 14.9 ns 14.9 ns 46401773 BM_GmTimeRRandom/last_decade 16.9 ns 16.9 ns 41439312 BM_GmTimeRRandom/last_half_centry 16.9 ns 16.9 ns 41225553 ``` perf after ``` ------------------------------------------------------------------------------- Benchmark Time CPU Iterations ------------------------------------------------------------------------------- BM_GmTimeR 3.27 ns 3.27 ns 215390890 BM_GmTimeRRandom/last_hour 4.52 ns 4.52 ns 154869504 BM_GmTimeRRandom/last_day 4.53 ns 4.53 ns 155409964 BM_GmTimeRRandom/last_month 7.24 ns 7.24 ns 96972146 BM_GmTimeRRandom/last_year 13.5 ns 13.5 ns 51957829 BM_GmTimeRRandom/last_decade 15.5 ns 15.5 ns 45192135 BM_GmTimeRRandom/last_half_centry 15.4 ns 15.4 ns 45526906 ``` commit_hash:ac9db56d93a25c3a3018cfbb6bc5800da3d001ee
* GmTimeR x2 speeduptobo2025-02-081-13/+24
| | | | | | | | | | | | | | | | | | | | | | | | | performance comparison againt standard gmtime\_r ``` ------------------------------------------------------------------------------- Benchmark Time CPU Iterations ------------------------------------------------------------------------------- BM_GmTimeR 3.66 ns 3.66 ns 189855900 BM_gmtime_r 18.7 ns 18.7 ns 37340999 BM_GmTimeRRandom/last_hour 5.12 ns 5.12 ns 136126173 BM_gmtime_r_Random/last_hour 19.2 ns 19.2 ns 36556971 BM_GmTimeRRandom/last_day 5.10 ns 5.10 ns 138257644 BM_gmtime_r_Random/last_day 19.2 ns 19.2 ns 37025160 BM_GmTimeRRandom/last_month 7.10 ns 7.10 ns 98235494 BM_gmtime_r_Random/last_month 20.4 ns 20.4 ns 34637975 BM_GmTimeRRandom/last_year 15.0 ns 15.0 ns 46664304 BM_gmtime_r_Random/last_year 26.8 ns 26.8 ns 26135911 BM_GmTimeRRandom/last_decade 17.2 ns 17.2 ns 40105536 BM_gmtime_r_Random/last_decade 27.0 ns 27.0 ns 25817056 BM_GmTimeRRandom/last_half_centry 17.1 ns 17.0 ns 41066079 BM_gmtime_r_Random/last_half_century 26.8 ns 26.7 ns 26215076 ``` commit_hash:33747760ad46412f50fe3cb06f4c438794a44492
* FixNamespaceComments in /utildmasloff2024-09-051-1/+1
| | | | | FixNamespaceComments in /util bb9152570d7c258798644ead5a59f604de05ef3b
* fix typotobo2024-06-181-3/+3
| | | | f172ae24ead4a8c8edae837d34f264a744a4d89c
* Add mtime/atime/ctime with nanoseconds to TFileStat.sath2024-05-131-8/+32
| | | | 3523ab3f5aade2bdf4c0efd5dd2defbe19f124ff
* Remove using of extra semicolons in utilbulatman2023-05-041-1/+1
|
* speedup GmTimeR functiontobo2022-08-251-33/+163
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | в профиле перфа Маркетного репорта постоянно вижу GmTimeR там в цикле вычитается по количеству дней в году и прибавляется по 1 году с 1970 по 2022 на каждый вызов В Маркете проблема стреляла и раньше в последней итерации функция становится на ~~30% быстрее системной gmtime_r %% ----------- GmTimeR --------------- samples: 20691 iterations: 264304536 iterations hr: 264M run time: 5.002055225 per iteration: 39.85866484 cycles ----------- gmtime_r --------------- samples: 17452 iterations: 188034528 iterations hr: 188M run time: 5.001259884 per iteration: 56.96146577 cycles %% текущая верся почти в 2 раза медленнее системной: %% ----------- GmTimeR --------------- samples: 12760 iterations: 100514931 iterations hr: 101M run time: 5.00096133 per iteration: 105.4334174 cycles ----------- gmtime_r --------------- samples: 17667 iterations: 192697896 iterations hr: 193M run time: 5.001356603 per iteration: 55.69031415 cycles %%
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.levong2022-02-101-1/+1
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.levong2022-02-101-1/+1
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.lapshov2022-02-101-36/+36
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.lapshov2022-02-101-36/+36
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.dobrokot2022-02-101-1/+1
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.dobrokot2022-02-101-1/+1
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.ivanselin2022-02-101-4/+4
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.ivanselin2022-02-101-4/+4
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.melkov2022-02-101-9/+9
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.melkov2022-02-101-9/+9
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.nga2022-02-101-4/+4
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.nga2022-02-101-4/+4
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.aosipenko2022-02-101-2/+2
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.aosipenko2022-02-101-2/+2
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.smalov2022-02-101-12/+12
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.smalov2022-02-101-12/+12
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.axc2022-02-101-1/+1
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.axc2022-02-101-1/+1
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.tobo2022-02-101-2/+2
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.tobo2022-02-101-2/+2
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.leo2022-02-101-25/+25
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.leo2022-02-101-25/+25
|
* Restoring authorship annotation for Vlad Yaroslavlev <[email protected]>. ↵Vlad Yaroslavlev2022-02-101-1/+1
| | | | Commit 2 of 2.
* Restoring authorship annotation for Vlad Yaroslavlev <[email protected]>. ↵Vlad Yaroslavlev2022-02-101-1/+1
| | | | Commit 1 of 2.
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.somov2022-02-101-1/+1
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.somov2022-02-101-1/+1
|
* Restoring authorship annotation for <[email protected]>. Commit 2 of 2.mvel2022-02-101-6/+6
|
* Restoring authorship annotation for <[email protected]>. Commit 1 of 2.mvel2022-02-101-6/+6
|
* Restoring authorship annotation for Anton Samokhvalov <[email protected]>. ↵Anton Samokhvalov2022-02-101-35/+35
| | | | Commit 2 of 2.
* Restoring authorship annotation for Anton Samokhvalov <[email protected]>. ↵Anton Samokhvalov2022-02-101-35/+35
| | | | Commit 1 of 2.
* intermediate changesDevtools Arcadia2022-02-071-0/+140
ref:cde9a383711a11544ce7e107a78147fb96cc4029