Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-04 Thread Mathieu Desnoyers
* Andi Kleen ([EMAIL PROTECTED]) wrote: > On Fri, Jun 01, 2007 at 04:33:06PM -0400, Mathieu Desnoyers wrote: > > * Andi Kleen ([EMAIL PROTECTED]) wrote: > > > > Yes, but as you have probably understood, I want to have everything > > > > embedded at the cond_call() site rather than polluting the res

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Andi Kleen
On Fri, Jun 01, 2007 at 04:33:06PM -0400, Mathieu Desnoyers wrote: > * Andi Kleen ([EMAIL PROTECTED]) wrote: > > > Yes, but as you have probably understood, I want to have everything > > > embedded at the cond_call() site rather than polluting the rest of the > > > code with declarations. > > > >

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Mathieu Desnoyers
* Andi Kleen ([EMAIL PROTECTED]) wrote: > > Yes, but as you have probably understood, I want to have everything > > embedded at the cond_call() site rather than polluting the rest of the > > code with declarations. > > A cond call is essentially a fancy variable. And the Linux kernel > is written

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Andi Kleen
> Yes, but as you have probably understood, I want to have everything > embedded at the cond_call() site rather than polluting the rest of the > code with declarations. A cond call is essentially a fancy variable. And the Linux kernel is written in C and in C you declare variables before you use t

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Matt Mackall
On Fri, Jun 01, 2007 at 02:06:54PM -0400, Mathieu Desnoyers wrote: > * Andi Kleen ([EMAIL PROTECTED]) wrote: > > > It's not clear to me why either of those things are necessary. An > > > example please? > > > > It's certainly possible that a global flag would need to be tested > > more than once.

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Mathieu Desnoyers
* Andi Kleen ([EMAIL PROTECTED]) wrote: > > It's not clear to me why either of those things are necessary. An > > example please? > > It's certainly possible that a global flag would need to be tested > more than once. > > I guess it would work if a symbol is associated with a single > definition

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Mathieu Desnoyers
* Matt Mackall ([EMAIL PROTECTED]) wrote: > On Fri, Jun 01, 2007 at 12:46:23PM -0400, Mathieu Desnoyers wrote: > > * Matt Mackall ([EMAIL PROTECTED]) wrote: > > > On Thu, May 31, 2007 at 03:42:50PM +0200, Andi Kleen wrote: > > > > Mathieu Desnoyers <[EMAIL PROTECTED]> writes: > > > > > > > > > Rei

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Andi Kleen
> It's not clear to me why either of those things are necessary. An > example please? It's certainly possible that a global flag would need to be tested more than once. I guess it would work if a symbol is associated with a single definition. e.g. if there is a DEFINE_COND_CALL() somewhere and th

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Matt Mackall
On Fri, Jun 01, 2007 at 12:46:23PM -0400, Mathieu Desnoyers wrote: > * Matt Mackall ([EMAIL PROTECTED]) wrote: > > On Thu, May 31, 2007 at 03:42:50PM +0200, Andi Kleen wrote: > > > Mathieu Desnoyers <[EMAIL PROTECTED]> writes: > > > > > > > Reimplementation of the cond calls which uses a hash tabl

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Mathieu Desnoyers
* Matt Mackall ([EMAIL PROTECTED]) wrote: > On Thu, May 31, 2007 at 03:42:50PM +0200, Andi Kleen wrote: > > Mathieu Desnoyers <[EMAIL PROTECTED]> writes: > > > > > Reimplementation of the cond calls which uses a hash table to hold the > > > active > > > cond_calls. It permits to first arm a cond_

Re: [patch 2/9] Conditional Calls - Hash Table

2007-06-01 Thread Matt Mackall
On Thu, May 31, 2007 at 03:42:50PM +0200, Andi Kleen wrote: > Mathieu Desnoyers <[EMAIL PROTECTED]> writes: > > > Reimplementation of the cond calls which uses a hash table to hold the > > active > > cond_calls. It permits to first arm a cond_call and then load supplementary > > modules that cont

Re: [patch 2/9] Conditional Calls - Hash Table

2007-05-31 Thread Andi Kleen
Mathieu Desnoyers <[EMAIL PROTECTED]> writes: > Reimplementation of the cond calls which uses a hash table to hold the active > cond_calls. It permits to first arm a cond_call and then load supplementary > modules that contain this cond_call. Hash table is probably overkill. This is a very very s

Re: [patch 2/9] Conditional Calls - Hash Table

2007-05-30 Thread Andrew Morton
On Wed, 30 May 2007 10:00:27 -0400 Mathieu Desnoyers <[EMAIL PROTECTED]> wrote: > Reimplementation of the cond calls which uses a hash table to hold the active > cond_calls. It permits to first arm a cond_call and then load supplementary > modules that contain this cond_call. This patch so comple

[patch 2/9] Conditional Calls - Hash Table

2007-05-30 Thread Mathieu Desnoyers
Reimplementation of the cond calls which uses a hash table to hold the active cond_calls. It permits to first arm a cond_call and then load supplementary modules that contain this cond_call. Without this, the order of loading a module containing a cond_call and arming a cond_call matters and there

[patch 2/9] Conditional Calls - Hash Table

2007-05-29 Thread Mathieu Desnoyers
Reimplementation of the cond calls which uses a hash table to hold the active cond_calls. It permits to first arm a cond_call and then load supplementary modules that contain this cond_call. Without this, the order of loading a module containing a cond_call and arming a cond_call matters and there