lkml.org 
[lkml]   [2009]   [Mar]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch 04/11] Introduce virtual debug register in thread_struct and wrapper-routines around process related functions

* prasad@linux.vnet.ibm.com <prasad@linux.vnet.ibm.com> wrote:

> This patch introduces virtual debug registers to used by the
> per-thread structure ad wrapper routines to manage debug
> registers by process-related functions.

this is somewhat confusing. It would be much clearer to name it
'user debug registers'.

and why is this:

> @@ -427,13 +427,9 @@ struct thread_struct {
> unsigned long ip;
> unsigned long fs;
> unsigned long gs;
> - /* Hardware debugging registers: */
> - unsigned long debugreg0;
> - unsigned long debugreg1;
> - unsigned long debugreg2;
> - unsigned long debugreg3;
> - unsigned long debugreg6;
> - unsigned long debugreg7;
> + /* Hardware breakpoint info */
> + unsigned long vdr6;
> + struct thread_hw_breakpoint *hw_breakpoint_info;

detached from thread_struct? There's a lot of complications
(alloc/free, locking, etc.) from this for no good reason - the
hardware-breakpoints info structure is alway per thread and is
quite small, so there's no reason not to embedd it directly
inside thread_struct.

That way we get its allocation and freeing logic for free in
essence.

Ingo


\
 
 \ /
  Last update: 2009-03-10 15:39    [W:0.077 / U:0.704 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site