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, 12 Sep 2007 10:19:47 -0400
From:	Mathieu Desnoyers <mathieu.desnoyers@...ymtl.ca>
To:	Andi Kleen <andi@...stfloor.org>
Cc:	akpm@...ux-foundation.org, linux-kernel@...r.kernel.org,
	"H. Peter Anvin" <hpa@...or.com>
Subject: Re: [PATCH] Scheduler Profiling - Use Immediate Values

* Andi Kleen (andi@...stfloor.org) wrote:
> Mathieu Desnoyers <mathieu.desnoyers@...ymtl.ca> writes:
> >  
> > -	profile_hit(SCHED_PROFILING, __builtin_return_address(0));
> > +	immediate_if (&sched_profiling)
> 
> I must say I really dislike immediate_if(). You complained earlier
> that something breaks coloring, but adding such macros will definitely
> break a lot of editors (especially if you use it without {} like here)
> 
> It would be much nicer and readable to just use if 
> (unlikely(immediate_read(&x)) or if you prefer to hide the unlikely
> if (immediate_bool_test(&x)) with an implicit unlikely().
> 
> -Andi

Please refer to :

http://lkml.org/lkml/2007/7/3/301

The idea is not to hide the unlikely, but to leave the opportunity to
make this primitive evolve in something that won't depend on a load
immediate and only require patching of a jump, given the appropriate gcc
support (yet to come).

Mathieu


-- 
Mathieu Desnoyers
Computer Engineering Ph.D. Student, Ecole Polytechnique de Montreal
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F  BA06 3F25 A8FE 3BAE 9A68
-
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