lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 8 Feb 2012 10:04:45 +0100
From:	Martin Schwidefsky <schwidefsky@...ibm.com>
To:	"H. Peter Anvin" <hpa@...or.com>
Cc:	linux-arch@...r.kernel.org, linux-kernel@...r.kernel.org,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Heiko Carstens <heiko.carstens@...ibm.com>,
	<linux390@...ibm.com>
Subject: Re: [PATCH 16/21] s390: Use generic posix_types.h

On Tue,  7 Feb 2012 21:09:00 -0800
"H. Peter Anvin" <hpa@...or.com> wrote:

> From: "H. Peter Anvin" <hpa@...or.com>
> 
> Change the s390 architecture to use <asm-generic/posix_types.h>.
> 
> Signed-off-by: H. Peter Anvin <hpa@...or.com>
> Cc: Martin Schwidefsky <schwidefsky@...ibm.com>
> Cc: Heiko Carstens <heiko.carstens@...ibm.com>
> Cc: <linux390@...ibm.com>
> ---
>  arch/s390/include/asm/posix_types.h |   70 +++++------------------------------
>  1 files changed, 10 insertions(+), 60 deletions(-)

I carefully checked the conversion and came to the conclusion that the new type
definitions are equivalent to the old ones. The code compiles fine with the
patches applied and the kernel boots.
What I don't like is the conversion of __FD_ZERO. The new definition creates
this code sequence:

   0:   a7 19 00 00             lghi    %r1,0
   4:   e3 10 20 00 00 24       stg     %r1,0(%r2)
   a:   e3 10 20 08 00 24       stg     %r1,8(%r2)
  10:   e3 10 20 10 00 24       stg     %r1,16(%r2)
  16:   e3 10 20 18 00 24       stg     %r1,24(%r2)
  1c:   e3 10 20 20 00 24       stg     %r1,32(%r2)
  22:   e3 10 20 28 00 24       stg     %r1,40(%r2)
  28:   e3 10 20 30 00 24       stg     %r1,48(%r2)
  2e:   e3 10 20 38 00 24       stg     %r1,56(%r2)
  34:   e3 10 20 40 00 24       stg     %r1,64(%r2)
  3a:   e3 10 20 48 00 24       stg     %r1,72(%r2)
  40:   e3 10 20 50 00 24       stg     %r1,80(%r2)
  46:   e3 10 20 58 00 24       stg     %r1,88(%r2)
  4c:   e3 10 20 60 00 24       stg     %r1,96(%r2)
  52:   e3 10 20 68 00 24       stg     %r1,104(%r2)
  58:   e3 10 20 70 00 24       stg     %r1,112(%r2)
  5e:   e3 10 20 78 00 24       stg     %r1,120(%r2)

the old code used to be just a single instruction:

   0:   d7 7f 20 00 20 00       xc      0(128,%r2),0(%r2)

That is quite a difference in code length. The execution speed should be almost
the same though.

-- 
blue skies,
   Martin.

"Reality continues to ruin my life." - Calvin.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ