May 15, 2016 Re: dxorshift: random number generators from the extended Xorshift family | ||||
---|---|---|---|---|
| ||||
Posted in reply to Joseph Rushton Wakeling | On 05/15/2016 05:33 PM, Joseph Rushton Wakeling wrote:
> Ah, interesting. I think you may have discovered a bug in
> `isForwardRange`, because that test _should_ have detected that, if
> BaseRNG is a forward range, the RNG accessed via `alias this` is also
> `save`able.
For a forward range, save must return the very same type. A forwarded `save` returns a different type.
|
May 15, 2016 Re: dxorshift: random number generators from the extended Xorshift family | ||||
---|---|---|---|---|
| ||||
Posted in reply to Joseph Rushton Wakeling | On Sunday, 15 May 2016 at 11:15:38 UTC, Joseph Rushton Wakeling wrote: > On Sunday, 15 May 2016 at 10:43:55 UTC, Joseph Rushton Wakeling wrote: >> Probably the best way to handle this is to handle the take-the-address side of things by a @trusted wrapper that uses `return ref` to guarantee the pointer remains valid for the lifetime of the wrapper itself. > > Note, I've been mulling over this myself for a while, so I'll probably put something together in a future dxorshift release (and probably try to get it in Phobos ASAP, as it will be very helpful in avoiding the worst cases of the existing RNG functionality). Wrapper implemented here, together with documentation and tests: https://github.com/WebDrake/dxorshift/pull/1 N.B. I'm sticking with the explicit wrapper, because I want to be really, really certain that what comes out is an input range whose underling RNG can _never_ be copied by value. |
May 18, 2016 Re: dxorshift: random number generators from the extended Xorshift family | ||||
---|---|---|---|---|
| ||||
Posted in reply to Joseph Rushton Wakeling | On Sunday, 15 May 2016 at 23:34:46 UTC, Joseph Rushton Wakeling wrote: > > Wrapper implemented here, together with documentation and tests: > https://github.com/WebDrake/dxorshift/pull/1 > > N.B. I'm sticking with the explicit wrapper, because I want to be really, really certain that what comes out is an input range whose underling RNG can _never_ be copied by value. Thought you might find this interesting: http://news.utexas.edu/2016/05/16/computer-science-advance-could-improve-cybersecurity and reddit discussion: https://www.reddit.com/r/technology/comments/4jvihm/computer_scientists_have_developed_a_new_method/ |
May 18, 2016 Re: dxorshift: random number generators from the extended Xorshift family | ||||
---|---|---|---|---|
| ||||
Posted in reply to jmh530 | On Wednesday, 18 May 2016 at 16:12:35 UTC, jmh530 wrote:
> Thought you might find this interesting:
> http://news.utexas.edu/2016/05/16/computer-science-advance-could-improve-cybersecurity
>
> and reddit discussion:
> https://www.reddit.com/r/technology/comments/4jvihm/computer_scientists_have_developed_a_new_method/
That's more or less what random.org does.
|
May 18, 2016 Re: dxorshift: random number generators from the extended Xorshift family | ||||
---|---|---|---|---|
| ||||
Posted in reply to jmh530 | On Wednesday, 18 May 2016 at 16:12:35 UTC, jmh530 wrote:
> On Sunday, 15 May 2016 at 23:34:46 UTC, Joseph Rushton Wakeling wrote:
>>
>> Wrapper implemented here, together with documentation and tests:
>> https://github.com/WebDrake/dxorshift/pull/1
>>
>> N.B. I'm sticking with the explicit wrapper, because I want to be really, really certain that what comes out is an input range whose underling RNG can _never_ be copied by value.
>
> Thought you might find this interesting:
> http://news.utexas.edu/2016/05/16/computer-science-advance-could-improve-cybersecurity
>
> and reddit discussion:
> https://www.reddit.com/r/technology/comments/4jvihm/computer_scientists_have_developed_a_new_method/
Yea, I was looking at that earlier today -- looks interesting! It would be good to try to implement it for D.
|
Copyright © 1999-2021 by the D Language Foundation