Re: Clarify drand48() return values

2019-12-21 Thread Alexander Nasonov
Theo de Raadt wrote: > Alexander Nasonov wrote: > > > Ingo Schwarze wrote: > > > Looking at our code in lib/libc/stdlib/drand48.c, i conclude that > > > drand48(3) does return 0.0 with a probability of 2^-48. > > > > I looked at the code too and I hav

Re: Clarify drand48() return values

2019-12-21 Thread Alexander Nasonov
Ingo Schwarze wrote: > Looking at our code in lib/libc/stdlib/drand48.c, i conclude that > drand48(3) does return 0.0 with a probability of 2^-48. I looked at the code too and I have some comments. > More generally, the function returns a uniform distribution of > numbers from the set {2^-48 * n

Re: Clarify drand48() return values

2019-12-20 Thread Alexander Nasonov
j...@bitminer.ca wrote: > > Clarify that drand48 returns values not including 1.0. It's not clear from the documentation whether drand48 can generate a denormal number. If it can't, you can exclude 0.0 because it's a denormal ;-) -- Alex

Re: syscall call-from verification

2019-11-28 Thread Alexander Nasonov
Theo de Raadt wrote: > The following change only permits system calls from address-ranges > in the process which system calls are expected from. Just curious if some approximation of pledge can be reimplemented in userspace with more granular libc.so's text segments? -- Alex

Re: [EXTERNAL] Re: Removing PF

2019-04-01 Thread Alexander Nasonov
Eichert, Diana wrote: > I wrote a vax BPF jit as a simple exercize some time ago, so all > you really need now is to implement vax-to-${ARCH} jit on an MD > basis. This should be very easy to do as long as BPF does not get > extended to use floating-point values. I'm afraid you have to rewrite it