Re: Is python2 dead?

2023-09-12 Thread Hal Murray via devel
Gary said: > Please, no. Go is a garbage collected language. Just what NTPsec does not > need, random, unpredictable delays. I was thinking of the Python code in ntpclients/ and pylib/ Is there anything in there that is time sensitive? There are lots of ways to inject timing bumps before we

Re: Is python2 dead?

2023-09-12 Thread James Browning via devel
> On 09/12/2023 12:00 AM PDT Hal Murray via devel wrote: > > > Gary said: > > Please, no. Go is a garbage collected language. Just what NTPsec does not > > need, random, unpredictable delays. It would appear there is a way to turn off GC under runtime/, Given this, it might be reasonable to

Re: Is python2 dead?

2023-09-12 Thread Richard Laager via devel
On 2023-09-12 00:03, Hal Murray via devel wrote: Maybe it's time to switch to Go? The opportunity for that may have passed. There's a new ntpd-rs project writing an NTP daemon in Rust: https://github.com/pendulum-project/ntpd-rs It's certainly not a full ntpd replacement yet (e.g. no local r

Re: Is python2 dead?

2023-09-12 Thread Gary E. Miller via devel
Yo James! On Tue, 12 Sep 2023 06:46:38 -0700 (PDT) James Browning via devel wrote: > > On 09/12/2023 12:00 AM PDT Hal Murray via devel > > wrote: > > > > > > Gary said: > > > Please, no. Go is a garbage collected language. Just what > > > NTPsec does not need, random, unpredictable delay

Re: Is python2 dead?

2023-09-12 Thread Gary E. Miller via devel
Yo Hal! On Tue, 12 Sep 2023 00:00:47 -0700 Hal Murray via devel wrote: > Gary said: > > Please, no. Go is a garbage collected language. Just what NTPsec > > does not need, random, unpredictable delays. > > I was thinking of the Python code in ntpclients/ and pylib/ > Is there anything in t

Go GC

2023-09-12 Thread Hal Murray via devel
Gary said: >James Browning via devel wrote: >> It would appear there is a way to turn off GC under runtime/, > How? Link? https://pkg.go.dev/runtime/debug#SetGCPercent It's not clear to me how to take advantage of that. You still have to turn it on occasionally or your world will fill up w

Re: Go GC

2023-09-12 Thread Gary E. Miller via devel
Yo Hal! On Tue, 12 Sep 2023 16:55:12 -0700 Hal Murray via devel wrote: > Gary said: > >James Browning via devel wrote: > >> It would appear there is a way to turn off GC under runtime/, > > How? Link? > > https://pkg.go.dev/runtime/debug#SetGCPercent > > It's not clear to me how to ta

Re: Go GC

2023-09-12 Thread Hal Murray via devel
Gary said: > Avoiding creating garbage is hard. In general, yes. But the inner loop of the server side is not very complicated. The APIs that I'm looking at are read-into-my-buffer rather than return a new buffer that needs to be GCed. I think it's worth some effort to investigate this area

Re: Go GC

2023-09-12 Thread Gary E. Miller via devel
Yo Hal! On Tue, 12 Sep 2023 18:49:35 -0700 Hal Murray via devel wrote: > I think it's worth some effort to investigate this area. I'm > prepared to give up if we find a fatal problem. Again, I'm assuming > that we split ntpd into client and server parts so all we have to > work on is the serve