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]
Message-ID: <48764530.7000909@goop.org>
Date:	Thu, 10 Jul 2008 10:21:52 -0700
From:	Jeremy Fitzhardinge <jeremy@...p.org>
To:	Christoph Lameter <cl@...ux-foundation.org>
CC:	"H. Peter Anvin" <hpa@...or.com>, Mike Travis <travis@....com>,
	"Eric W. Biederman" <ebiederm@...ssion.com>,
	Arjan van de Ven <arjan@...radead.org>,
	Ingo Molnar <mingo@...e.hu>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Jack Steiner <steiner@....com>, linux-kernel@...r.kernel.org,
	Rusty Russell <rusty@...tcorp.com.au>
Subject: Re: [RFC 00/15] x86_64: Optimize percpu accesses

Christoph Lameter wrote:
> H. Peter Anvin wrote:
>   
>> Christoph Lameter wrote:
>>     
>>> H. Peter Anvin wrote:
>>>
>>>       
>>>> No, since the *addresses* can be arbitrary.  The current issue is about
>>>> *offsets.*
>>>>         
>>> Well those are intimately connected.
>>>       
>> Not really, since gs_base is an arbitrary 64-bit pointer.
>>     
>
> The current scheme ties the offsets to kernel code addresses.
>   

This is getting very frustrating.  We've been going around and around on 
this point, what, 5 or 6 times at least.

The base address of the percpu area and the offsets from that base are 
completely independent values.

The offset is limited to 2G.  The 2G limit applies regardless of how you 
compute your effective address.  It doesn't matter if its absolute.  It 
doesn't matter if it's rip-relative.  It doesn't matter if it's 
zero-based.  Small absolute addresses generate exactly the same form as 
large absolute addresses.  There is no 8-bit or 16-bit address mode.

The base is arbitrary.  It can be any canonical address at all.  It has 
no effect on how you compute your offset.

The addressing modes:

    * ABS
    * off(%rip)

Are exactly equivalent in what offsets they can generate, so long as *at 
link time* the percpu *symbols* are within 2G of the code addressing 
them.  *After* the addressing mode has generated an effective address 
(by whatever means it likes), the %gs: override applies the segment 
base, which can therefore offset the effective address to anywhere at all.

    J
--
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