lkml.org 
[lkml]   [2009]   [Mar]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch 02/11] x86 architecture implementation of Hardware Breakpoint interfaces

* Alan Stern <stern@rowland.harvard.edu> wrote:

> On Fri, 13 Mar 2009, Ingo Molnar wrote:
>
> > The core issue being discussed is the debug register
> > allocation and scheduling model though, and you have not
> > directly commented on that.
> >
> > My argument in a nutshell is that a bottom-up for user +
> > top-down for kernel use static allocator with no dynamic
> > scheduling will get us most of the benefits with a tenth of
> > the complexity.
>
> Take this even farther: We shouldn't restrict userspace to
> bottom-up register allocation. With very little additional
> effort we can virtualize the debug registers; then userspace
> can allocate them in whatever order it wants and still end up
> using the physical registers in bottom-up order (or top-down,
> which is the order used by the current patches).
>
> After all, there's nothing to prevent programs other than gdb
> from using ptrace, and there's no guarantee that gdb will
> continue to allocate registers in increasing order.

If in ~10 years of its existence no such usage arose so i dont
think it will magically appear now.

The thing is, kernel-side use of debug registers is a borderline
item whose impact we should minimalize as much as possible.
Linus in the past expressed that it is fine to not have _any_
management of user versus kernel debug registers. So we want to
approach this from the minimalistic side. I offered such a very
minimal design that is trivial in terms of correctness and
impact.

We can still get this simple allocation model into .30 if we
dont waste time arguing about unnecessarily. If someone runs
into limitations the model can be extended.

Ingo


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