1 |
On Wed, 2023-01-18 at 20:48 -0500, Joshua Kinard wrote: |
2 |
> So this article[1] from 2017 popped up again on the tech radar via hackernews[2] and a few other sites[3]. It |
3 |
> annotates how if the envvar TZ is undefined on a Linux system, it causes glibc to generate a number of |
4 |
> additional syscalls, mainly stat-related calls (in my tests, newfstatat()). If defined to an actual value, |
5 |
> such as ":/etc/localtime" (or even an empty string), glibc will instead generate far fewer, if any at all, of |
6 |
> these stat-related syscalls. |
7 |
> |
8 |
> [...] |
9 |
> So is adding a default definition of TZ to our base system /etc/profile something we want to look at? I |
10 |
> haven't tried any other methods of benchmarking to see if not making those additional syscalls is just placebo |
11 |
> or if there are actual impacts. Given how long this oddity has been around, I can't tell if it's a genuine |
12 |
> bug in glibc, an unoptimized corner case, or just a big nothingburger. |
13 |
> |
14 |
|
15 |
Am I correct that there's no real difference between setting it to |
16 |
":/etc/localtime" and the actual timezone? |
17 |
|
18 |
I suppose it would make sense to default it. |
19 |
|
20 |
-- |
21 |
Best regards, |
22 |
Michał Górny |