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: <Pine.LNX.4.61.0702091320310.31955@yvahk01.tjqt.qr>
Date:	Fri, 9 Feb 2007 13:27:01 +0100 (MET)
From:	Jan Engelhardt <jengelh@...ux01.gwdg.de>
To:	Andi Kleen <ak@...e.de>
cc:	Andrew Morton <akpm@...ux-foundation.org>,
	Arjan van de Ven <arjan@...radead.org>,
	Frederik Deweerdt <deweerdt@...e.fr>,
	linux-kernel@...r.kernel.org, tglx@...utronix.de
Subject: Re: -mm merge plans for 2.6.21


On Feb 9 2007 14:04, Andi Kleen wrote:
>Andrew Morton <akpm@...ux-foundation.org> writes:
>> 
>> As long as nobody takes the address of them (which wouldn't compile today
>> anyway) then the compiler should be able to not allocate store for these. 
>
>This would only work for unit-at-a-time compilers (if it works at all,
>i'm not sure), but not older 3.x compilers
>
>> That they're const might help too.
>
>Don't think it does.

GCC 4.1 optimizes both Andrew's and Frederik Deweerdt's ideas 
perfectly out. Even if the const was not there in Frederik's example, 
gcc seems throw it out with -O2 (judging by `nm` output) since it is
1. static 2. unused. Gcc even gives out a warning that the item is 
unused when not marked with const.


Jan
-- 
ft: http://freshmeat.net/p/chaostables/
-
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