1
0
mirror of https://github.com/cc65/cc65.git synced 2024-06-26 05:29:30 +00:00
Commit Graph

6 Commits

Author SHA1 Message Date
Colin Leroy-Mira
348a9048b7 Convert _time_t_to_tm to asm
46 bytes size gain, -8% cycles on the unit tests
2024-01-18 09:09:31 +01:00
Colin Leroy-Mira
df193c0947 Rework time functions a bit
- mktime: Work unsigned as time_t's type implies (shifting Y2K38 bug to 2106)
- mktime: Add unit tests
- gmtime/localtime: factorize
- gmtime/localtime: Add unit tests
- mktime/gmtime/localtime: Size optimisation (-130 bytes wrt master)
- mktime: Speed optimisation (from 23M cycles on the unit test to 2M)
2024-01-08 18:24:13 +01:00
Oliver Schmidt
a9ce4dc76c "Inverted" time_t value handling.
So far time_t values were interpreted as local time values. However, usually time_t values are to be interpreted as "seconds since 1 Jan 1970 in UTC". Therefore all logic handling time_t values has to be changed.

- So far gmtime() called localtime() with an adjusted time_t, now localtime() calls gmtime() with an adjusted time_t.
- mktime() has to do "the opposite" of localtime(), to keep it that way mktime() does now the inverse adjustment made by localtime().
- All currently present time() implementations internally call mktime() so they don't require individual adjustments.
2018-08-02 17:12:12 +02:00
Greg King
0390c34e88 Changed multi-line C comments into another style.
The left side doesn't look unbalanced.
2014-06-30 16:51:07 -04:00
cuz
94e041264e Optimizations
git-svn-id: svn://svn.cc65.org/cc65/trunk@2642 b7a2c559-68d2-44c3-8de9-860c34a00d81
2003-11-11 22:33:42 +00:00
cuz
43d8ecd567 Added lots of functions from time.h
git-svn-id: svn://svn.cc65.org/cc65/trunk@1507 b7a2c559-68d2-44c3-8de9-860c34a00d81
2002-11-12 22:06:02 +00:00