unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [PATCH] gnu: Add perf-tools.
@ 2022-08-03 18:34 Olivier Dion
  2022-08-03 20:29 ` Efraim Flashner
  0 siblings, 1 reply; 3+ messages in thread
From: Olivier Dion @ 2022-08-03 18:34 UTC (permalink / raw)
  To: guix-devel; +Cc: Olivier Dion

* gnu/packages/instrumentation.scm (perf-tools): New variable.
---
 gnu/packages/instrumentation.scm | 46 ++++++++++++++++++++++++++++++++
 1 file changed, 46 insertions(+)

diff --git a/gnu/packages/instrumentation.scm b/gnu/packages/instrumentation.scm
index 4e23e9bed4..66329c55a1 100644
--- a/gnu/packages/instrumentation.scm
+++ b/gnu/packages/instrumentation.scm
@@ -18,6 +18,7 @@
 
 (define-module (gnu packages instrumentation)
   #:use-module (gnu packages base)
+  #:use-module (gnu packages bash)
   #:use-module (gnu packages bison)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages datastructures)
@@ -25,6 +26,7 @@ (define-module (gnu packages instrumentation)
   #:use-module (gnu packages elf)
   #:use-module (gnu packages engineering)
   #:use-module (gnu packages flex)
+  #:use-module (gnu packages gawk)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages haskell-xyz)
   #:use-module (gnu packages libunwind)
@@ -290,6 +292,50 @@ (define-public lttng-tools
 @code{lttng-relayd} for network streaming.")
     (license (list  license:gpl2 license:lgpl2.1))))
 
+(define-public perf-tools
+  (package
+    (name "perf-tools")
+    (version "1.0")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/brendangregg/perf-tools")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32 "1ab735idi0h62yvhzd7822jj3555vygixv4xjrfrdvi8d2hhz6qn"))))
+    (build-system copy-build-system)
+    (arguments
+     `(#:install-plan
+       ',(append
+          (map (cut list <> "bin/")
+               '("disk/bitesize"
+                 "fs/cachestat"
+                 "execsnoop"
+                 "kernel/funccount"
+                 "kernel/funcgraph"
+                 "kernel/funcslower"
+                 "kernel/functrace"
+                 "iolatency"
+                 "iosnoop"
+                 "killsnoop"
+                 "kernel/kprobe"
+                 "opensnoop"
+                 "misc/perf-stat-hist"
+                 "tools/reset-ftrace"
+                 "syscount"
+                 "net/tcpretrans"
+                 "system/tpoint"
+                 "user/uprobe"))
+          '(("man/man8/" "share/man/man8")))))
+    (inputs (list bash gawk perf))
+    (home-page "https://github.com/brendangregg/perf-tools")
+    (synopsis "Performance analysis tools")
+    (description "Perf-tools is a collection of scripts for performance
+analysis and instrumentation based on Linux perf_events (aka perf) and
+ftrace.")
+    (license (list license:gpl2))))
+
 (define-public uftrace
   (package
     (name "uftrace")
-- 
2.37.1



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] gnu: Add perf-tools.
  2022-08-03 18:34 [PATCH] gnu: Add perf-tools Olivier Dion
@ 2022-08-03 20:29 ` Efraim Flashner
  2022-08-03 22:30   ` Olivier Dion via Development of GNU Guix and the GNU System distribution.
  0 siblings, 1 reply; 3+ messages in thread
From: Efraim Flashner @ 2022-08-03 20:29 UTC (permalink / raw)
  To: Olivier Dion; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 3498 bytes --]

Sorry for top posting.

You should send patches to guix-patches@gnu.org. Also I see you've added
gawk and perf as inputs, but a bunch of the scripts need to actually be
wrapped with those inputs.

On Wed, Aug 03, 2022 at 02:34:26PM -0400, Olivier Dion wrote:
> * gnu/packages/instrumentation.scm (perf-tools): New variable.
> ---
>  gnu/packages/instrumentation.scm | 46 ++++++++++++++++++++++++++++++++
>  1 file changed, 46 insertions(+)
> 
> diff --git a/gnu/packages/instrumentation.scm b/gnu/packages/instrumentation.scm
> index 4e23e9bed4..66329c55a1 100644
> --- a/gnu/packages/instrumentation.scm
> +++ b/gnu/packages/instrumentation.scm
> @@ -18,6 +18,7 @@
>  
>  (define-module (gnu packages instrumentation)
>    #:use-module (gnu packages base)
> +  #:use-module (gnu packages bash)
>    #:use-module (gnu packages bison)
>    #:use-module (gnu packages boost)
>    #:use-module (gnu packages datastructures)
> @@ -25,6 +26,7 @@ (define-module (gnu packages instrumentation)
>    #:use-module (gnu packages elf)
>    #:use-module (gnu packages engineering)
>    #:use-module (gnu packages flex)
> +  #:use-module (gnu packages gawk)
>    #:use-module (gnu packages glib)
>    #:use-module (gnu packages haskell-xyz)
>    #:use-module (gnu packages libunwind)
> @@ -290,6 +292,50 @@ (define-public lttng-tools
>  @code{lttng-relayd} for network streaming.")
>      (license (list  license:gpl2 license:lgpl2.1))))
>  
> +(define-public perf-tools
> +  (package
> +    (name "perf-tools")
> +    (version "1.0")
> +    (source (origin
> +              (method git-fetch)
> +              (uri (git-reference
> +                    (url "https://github.com/brendangregg/perf-tools")
> +                    (commit (string-append "v" version))))
> +              (file-name (git-file-name name version))
> +              (sha256
> +               (base32 "1ab735idi0h62yvhzd7822jj3555vygixv4xjrfrdvi8d2hhz6qn"))))
> +    (build-system copy-build-system)
> +    (arguments
> +     `(#:install-plan
> +       ',(append
> +          (map (cut list <> "bin/")
> +               '("disk/bitesize"
> +                 "fs/cachestat"
> +                 "execsnoop"
> +                 "kernel/funccount"
> +                 "kernel/funcgraph"
> +                 "kernel/funcslower"
> +                 "kernel/functrace"
> +                 "iolatency"
> +                 "iosnoop"
> +                 "killsnoop"
> +                 "kernel/kprobe"
> +                 "opensnoop"
> +                 "misc/perf-stat-hist"
> +                 "tools/reset-ftrace"
> +                 "syscount"
> +                 "net/tcpretrans"
> +                 "system/tpoint"
> +                 "user/uprobe"))
> +          '(("man/man8/" "share/man/man8")))))
> +    (inputs (list bash gawk perf))
> +    (home-page "https://github.com/brendangregg/perf-tools")
> +    (synopsis "Performance analysis tools")
> +    (description "Perf-tools is a collection of scripts for performance
> +analysis and instrumentation based on Linux perf_events (aka perf) and
> +ftrace.")
> +    (license (list license:gpl2))))
> +
>  (define-public uftrace
>    (package
>      (name "uftrace")
> -- 
> 2.37.1
> 
> 

-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] gnu: Add perf-tools.
  2022-08-03 20:29 ` Efraim Flashner
@ 2022-08-03 22:30   ` Olivier Dion via Development of GNU Guix and the GNU System distribution.
  0 siblings, 0 replies; 3+ messages in thread
From: Olivier Dion via Development of GNU Guix and the GNU System distribution. @ 2022-08-03 22:30 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: guix-devel

On Wed, 03 Aug 2022, Efraim Flashner <efraim@flashner.co.il> wrote:
> Sorry for top posting.
>
> You should send patches to guix-patches@gnu.org. Also I see you've added
> gawk and perf as inputs, but a bunch of the scripts need to actually be
> wrapped with those inputs.

Right.  Wrong ML.

-- 
Olivier Dion
oldiob.dev


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-08-03 22:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-03 18:34 [PATCH] gnu: Add perf-tools Olivier Dion
2022-08-03 20:29 ` Efraim Flashner
2022-08-03 22:30   ` Olivier Dion via Development of GNU Guix and the GNU System distribution.

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).