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: <522F410702000078000F1EE0@nat28.tlf.novell.com>
Date:	Tue, 10 Sep 2013 14:55:51 +0100
From:	"Jan Beulich" <JBeulich@...e.com>
To:	"Ingo Molnar" <mingo@...nel.org>
Cc:	"Frederic Weisbecker" <fweisbec@...il.com>,
	"Peter Zijlstra" <peterz@...radead.org>,
	"Thomas Gleixner" <tglx@...utronix.de>,
	"Linus Torvalds" <torvalds@...ux-foundation.org>,
	"Andi Kleen" <ak@...ux.intel.com>,
	"Arjan van de Ven" <arjan@...ux.intel.com>,
	"Mike Galbraith" <bitbucket@...ine.de>,
	<linux-arch@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
	"Peter Anvin" <hpa@...or.com>
Subject: Re: [PATCH 7/7] sched, x86: Optimize the preempt_schedule()
 call

>>> On 10.09.13 at 15:42, Ingo Molnar <mingo@...nel.org> wrote:

> * Peter Zijlstra <peterz@...radead.org> wrote:
> 
>> +	.macro SAVE_ALL
>> +	pushl_cfi %eax
>> +	CFI_REL_OFFSET eax, 0
>> +	pushl_cfi %ebp
>> +	CFI_REL_OFFSET ebp, 0
>> +	pushl_cfi %edi
>> +	CFI_REL_OFFSET edi, 0
>> +	pushl_cfi %esi
>> +	CFI_REL_OFFSET esi, 0
>> +	pushl_cfi %edx
>> +	CFI_REL_OFFSET edx, 0
>> +	pushl_cfi %ecx
>> +	CFI_REL_OFFSET ecx, 0
>> +	pushl_cfi %ebx
>> +	CFI_REL_OFFSET ebx, 0
>> +	.endm
>> +
>> +	.macro RESTORE_ALL
>> +	popl_cfi %ebx
>> +	CFI_RESTORE ebx
>> +	popl_cfi %ecx
>> +	CFI_RESTORE ecx
>> +	popl_cfi %edx
>> +	CFI_RESTORE edx
>> +	popl_cfi %esi
>> +	CFI_RESTORE esi
>> +	popl_cfi %edi
>> +	CFI_RESTORE edi
>> +	popl_cfi %ebp
>> +	CFI_RESTORE ebp
>> +	popl_cfi %eax
>> +	CFI_RESTORE eax
>> +	.endm
> 
> Side note: shouldn't the pushl_cfi and popl_cfi macros be adjusted, 
> instead of open coding it?

If you mean the open coding of CFI_REL_OFFSET and CFI_RESTORE,
then no - there may be pushes/pops that don't save the caller's
register values (i.e. where solely the frame pointer adjustment
matters).

If you meant something else, please clarify what.

Jan

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