Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150816173031.GA23518@openwall.com>
Date: Sun, 16 Aug 2015 20:30:31 +0300
From: Solar Designer <solar@...nwall.com>
To: john-dev@...ts.openwall.com
Subject: Re: FMT_OMP_BAD

On Sun, Aug 16, 2015 at 08:05:42PM +0300, Solar Designer wrote:
> We may agree on two cut-off points: e.g. < 4.0 (out of ideal 10.0) for
> disabling OpenMP in default builds, and < 7.0 for setting FMT_OMP_BAD.
> For formats where we have two benchmarks (usually for Only one vs. Many
> salts), use the faster one of these two (which should be Many salts).

This means that for this purpose we should use:

fgrep -v 'Only one salt' omp1to10.txt | less

or the like.  Whenever there's a "Only one salt" line in that file,
there's also a corresponding "Many salts" line, and we only need the
latter one.

> Would you also take care of adding FAST_FORMATS_OMP checks for formats
> that score below 4.0 on their fastest result in the attached .txt file?
> And test that this results in the intended behavior on two builds (with
> and without --enable-openmp-for-fast-formats).

I just noticed that one format in the below 4.0 range isn't actually
that fast.  So FAST_FORMATS_OMP wouldn't be appropriate for it.
Instead, we need to figure out and correct whatever other scalability
issue it has.  It's this one:

[solar@...er run]$ OMP_NUM_THREADS=1 ./john -test -form=Sybase-PROP
Warning: OpenMP is disabled; a non-OpenMP build may be faster
Benchmarking: Sybase-PROP [salted FEAL-8 32/64]... DONE
Many salts:     382976 c/s real, 382976 c/s virtual
Only one salt:  380928 c/s real, 380928 c/s virtual

[solar@...er run]$ OMP_NUM_THREADS=2 ./john -test -form=Sybase-PROP
Will run 2 OpenMP threads
Benchmarking: Sybase-PROP [salted FEAL-8 32/64]... (2xOMP) DONE
Many salts:     539374 c/s real, 272384 c/s virtual
Only one salt:  544768 c/s real, 271028 c/s virtual

[solar@...er run]$ OMP_NUM_THREADS=4 ./john -test -form=Sybase-PROP
Will run 4 OpenMP threads
Benchmarking: Sybase-PROP [salted FEAL-8 32/64]... (4xOMP) DONE
Many salts:     745472 c/s real, 185440 c/s virtual
Only one salt:  737280 c/s real, 183860 c/s virtual

[solar@...er run]$ OMP_NUM_THREADS=8 ./john -test -form=Sybase-PROP
Will run 8 OpenMP threads
Benchmarking: Sybase-PROP [salted FEAL-8 32/64]... (8xOMP) DONE
Many salts:     827310 c/s real, 104187 c/s virtual
Only one salt:  827310 c/s real, 103158 c/s virtual

[solar@...er run]$ OMP_NUM_THREADS=16 ./john -test -form=Sybase-PROP
Will run 16 OpenMP threads
Benchmarking: Sybase-PROP [salted FEAL-8 32/64]... (16xOMP) DONE
Many salts:     899513 c/s real, 56392 c/s virtual
Only one salt:  890780 c/s real, 55640 c/s virtual

It looks like it invokes FEAL 10 times - 2 in meta_keysch_repro(), and
8 in meta_encrypt_repro() - so is sort of "iterated", like descrypt.
Maybe it simply needs its OMP_SCALE tuned for OpenMP scalability.  Also,
maybe its optimal number of keys per crypt is higher than 1 even in
non-OpenMP builds.

Alexander

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.