Per thread rusage

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Frank

    #1

    Per thread rusage

    Hi,

    I got a test script with thread. Pretty much the basic stuff. Each
    threat runs the same subroutine. At the beginning and end in the
    subroutine I call getrusage to get the usage. But I can get only the
    information for the whole processes and not particular to 1 thread. Is
    it possible to get the rusage per thread? (the threads are pthreads, so
    there should not be any specific OS issues)

    Thanks in advanced,

    Frank de Bot
  • Victor Bazarov

    #2
    Re: Per thread rusage

    Frank wrote:[color=blue]
    > I got a test script with thread. Pretty much the basic stuff. Each
    > threat runs the same subroutine. At the beginning and end in the
    > subroutine I call getrusage to get the usage. But I can get only the
    > information for the whole processes and not particular to 1 thread. Is
    > it possible to get the rusage per thread? (the threads are pthreads, so
    > there should not be any specific OS issues)[/color]

    pthreads or any other threads, they _are_ OS-specific (since there are
    OSes without threading support). Please ask in the newsgroup that
    deals with your OS, or in comp.programmin g.threads. C++ has no specific
    thread support, and it has no function 'getrusage', so your question is
    off-topic here. Sorry.

    Victor

    Comment

    • Mike Wahler

      #3
      Re: Per thread rusage

      "Frank" <ppi_doesnt@lik e.spam_searchy. net> wrote in message
      news:4134d54d$0 $43451$e4fe514c @news.xs4all.nl ...[color=blue]
      > Hi,
      >
      > Each threat runs the same subroutine.[/color]

      Can I quote you on that?

      -Mike


      Comment

      Working...