Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 4 Jul 2013 21:12:48 +0200
From: magnum <john.magnum@...hmail.com>
To: john-dev@...ts.openwall.com
Subject: Re: bug: GPU use in CPU-only formats

On 4 Jul, 2013, at 20:53 , Solar Designer <solar@...nwall.com> wrote:
> On Tue, Jul 02, 2013 at 10:01:15PM -0300, Claudio Andr? wrote:
>>>> Can't we do all initial "opening" of anything GPU-related in the
>>>> format's init(), if the format is GPU-enabled, and not any sooner?
>>>> 
>>>> Perhaps there's some implementation difficulty that I am missing.
>> 
>> It is possible, but if the user ask for -dev=7, i have to check if there
>> is such device, counting all available devices in each platform (this is
>> why we need to do more than only parse the command line). On unstable,
>> -device is always related to only one platform (no need to care about
>> other platforms). On bleeding, -device is a sequential number.
> 
> Why did we introduce this unneeded(?) complexity?  Was anything wrong
> with unstable's numbering of devices?  Why don't we revert to it now?
> 
> I think we should revert, unless you somehow convince me otherwise.

Unstable supports a single device, using platform/device syntax. Bleeding understands that legacy syntax for backwards compatibility but only for selecting a single device. For selecting multiple devices, the new "sequential numbering" is much better/easier (or so we thought). You can run mscash2-opencl with --device=0,1 and it will run on both GPUs. I'm not sure what syntax we would use to achieve this with the old syntax.

>> Seems to me this kind of check is always done at initialization. Is it
>> possible to give an error message and exit using the JtR way if this
>> check is moved to init()? 
> 
> As currently defined, init() "can't fail", so we have to terminate the
> process right from there if it does fail.  This means e.g. printing a
> message and calling misc.c's error().  That's not pretty, yet it's
> better than accessing GPU in a CPU-only invocation of john.

I think it's OK to do this and it's my current goal.

magnum

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.