Skip to contentSkip to conversation

guider: add a new runtime profiler package

PATCH Superseded Khem Raj 3 participants 8 messages Dec 30, 2018 – Jan 4, 2019

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/3 guider: add a new runtime profiler package

From: Peace Lee <[email protected]>

guider [1] is a system-wide performance analyzer for platforms based on linux kernel. it can measure vary system resource usage and trace thread/process activities. and it reports vary meaningful output to analyze system status.

[1] https://github.com/iipeace/guider

---
 .../recipes-devtools/guider/guider_3.9.3.bb   | 34 +++++++++++++++++++
 1 file changed, 34 insertions(+)
 create mode 100644 meta-oe/recipes-devtools/guider/guider_3.9.3.bb
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +34 -0
new file mode 100644
index 0000000000..96d6c62ae2
@@ -0,0 +1,34 @@
+SUMMARY = "runtime performance analyzer"
+HOMEPAGE = "https://github.com/iipeace/guider"
+BUGTRACKER = "https://github.com/iipeace/guider/issues"
+AUTHOR = "Peace Lee <[email protected]>"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=2c1c00f9d3ed9e24fa69b932b7e7aff2"
+
+SRC_URI = "git://github.com/iipeace/${BPN}"
+SRCREV = "ac05a2ce0ab480957d642d947d8f617bd224031d"
+
+S = "${WORKDIR}/git"
+R = "${RECIPE_SYSROOT_NATIVE}"
+
+inherit distutils
+
+GUIDER_OBJ = "guider.pyc"
+GUIDER_SCRIPT = "guider"
+
+do_install() {
+    python ${S}/setup.py install
+
+    install -d ${D}${bindir}
+    install -v -m 0755 ${R}/${bindir}/${GUIDER_SCRIPT} ${D}${bindir}/${GUIDER_SCRIPT}
+
+    install -d ${D}${datadir}/${BPN}
+    install -v -m 0755 ${R}/${datadir}/${BPN}/${GUIDER_OBJ} ${D}${datadir}/${BPN}/${GUIDER_OBJ}
+}
+
+RDEPENDS_${PN} = "python-ctypes python-shell \
+                  python-json python-subprocess"
+
+FILES_SOLIBSDEV = ""
+#FILES_${PN} = "usr"
Signature · 1 line
2.20.1
author
#1 lore raw

PATCH 2/3 tinymembench: Update to tip of master

---
 meta-oe/recipes-benchmark/tinymembench/tinymembench_git.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta-oe/recipes-benchmark/tinymembench/tinymembench_git.bb +1 -1
index 8cb59da737..842644b8a1 100644
@@ -8,7 +8,7 @@ LIC_FILES_CHKSUM = "file://main.c;endline=22;md5=879b9bbb60851454885b5fa47eb6b34
 
 PV = "0.4.0+git${SRCPV}"
 
-SRCREV = "2c789849709d837b4bd114c11ed2d9bdc65afbc6"
+SRCREV = "a2cf6d7e382e3aea1eb39173174d9fa28cad15f3"
 SRC_URI = "git://github.com/ssvb/tinymembench.git"
 
 S = "${WORKDIR}/git"
Signature · 1 line
2.20.1
author
#2 lore raw

PATCH 3/3 catch2: Replace the patch with upstreamable patch

In reply to Khem Raj

Update to tip of master

---
 .../catch2/0001-Remove-redundant-move.patch   | 53 ++++++++++---------
 meta-oe/recipes-test/catch2/catch2_2.5.0.bb   |  4 +-
 2 files changed, 29 insertions(+), 28 deletions(-)
meta-oe/recipes-test/catch2/catch2/0001-Remove-redundant-move.patch +27 -26
index c3f5fc9ce7..dc8a8915eb 100644
@@ -1,36 +1,37 @@
-From b2bd82a0c0d3d5dda588d12cc1672a03a9630784 Mon Sep 17 00:00:00 2001
-From: Khem Raj <[email protected]>
-Date: Mon, 17 Dec 2018 17:27:43 -0800
-Subject: [PATCH] Remove redundant move
+From 7d7428fd09d1bcee281f7b678df8fb71e9365b17 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Martin=20Ho=C5=99e=C5=88ovsk=C3=BD?=
+ <[email protected]>
+Date: Thu, 27 Dec 2018 16:08:04 +0100
+Subject: [PATCH] A different approach
 
-fixes errors like below
-
-/mnt/a/yoe/build/tmp/work/aarch64-yoe-linux-musl/catch2/2.5.0-r0/git/include/internal/catch_session.cpp:52:29:
-error: redundant move in return statement [-Werror=redundant-move]
-   52 |             return std::move(multi);
-      |                    ~~~~~~~~~^~~~~~~
-/mnt/a/yoe/build/tmp/work/aarch64-yoe-linux-musl/catch2/2.5.0-r0/git/include/internal/catch_session.cpp:52:29:
-note: remove 'std::move' call
-
-Upstream-Status: Submitted [https://github.com/catchorg/Catch2/pull/1474]
-Signed-off-by: Khem Raj <[email protected]>
 ---
- include/internal/catch_session.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
+ include/internal/catch_session.cpp | 15 ++++++++++-----
+ 1 file changed, 10 insertions(+), 5 deletions(-)
 
-diff --git a/include/internal/catch_session.cpp b/include/internal/catch_session.cpp
-index 0920521c..b66d57ac 100644
 --- a/include/internal/catch_session.cpp
 +++ b/include/internal/catch_session.cpp
-@@ -49,7 +49,7 @@ namespace Catch {
-                 multi->addListener(listener->create(Catch::ReporterConfig(config)));
+@@ -42,14 +42,20 @@ namespace Catch {
+                 return createReporter(config->getReporterName(), config);
+             }
+ 
+-            auto multi = std::unique_ptr<ListeningReporter>(new ListeningReporter);
++            // On older platforms, returning std::unique_ptr<ListeningReporter>
++            // when the return type is std::unique_ptr<IStreamingReporter>
++            // doesn't compile without a std::move call. However, this causes
++            // a warning on newer platforms. Thus, we have to work around
++            // it a bit and downcast the pointer manually.
++            auto ret = std::unique_ptr<IStreamingReporter>(new ListeningReporter);
++            auto& multi = static_cast<ListeningReporter&>(*ret);
+ 
+             auto const& listeners = Catch::getRegistryHub().getReporterRegistry().getListeners();
+             for (auto const& listener : listeners) {
+-                multi->addListener(listener->create(Catch::ReporterConfig(config)));
++                multi.addListener(listener->create(Catch::ReporterConfig(config)));
              }
-             multi->addReporter(createReporter(config->getReporterName(), config));
+-            multi->addReporter(createReporter(config->getReporterName(), config));
 -            return std::move(multi);
-+            return multi;
++            multi.addReporter(createReporter(config->getReporterName(), config));
++            return ret;
          }
  
  
--- 
-2.20.1
-
meta-oe/recipes-test/catch2/catch2_2.5.0.bb +2 -2
index 14a1ebe80d..26149b31e4 100644
@@ -9,7 +9,8 @@ SRC_URI = "git://github.com/catchorg/Catch2.git \
            file://0001-Remove-redundant-move.patch \
           "
 # v2.5.0
-SRCREV = "6ccd467094973824d89efb16cbc553e279f79823"
+#SRCREV = "6ccd467094973824d89efb16cbc553e279f79823"
+SRCREV = "461843b1f02a4bf5c59db88ff201d2c56fabf3a4"
 
 S = "${WORKDIR}/git"
 
@@ -23,4 +24,3 @@ do_install_append() {
 # Header-only library
 RDEPENDS_${PN}-dev = ""
 RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
-
Signature · 1 line
2.20.1
#3 lore raw
In reply to Khem Raj

Neat tool! I'll have to play with it a bit more.

Quoted 3 lines · Khem Raj

From: Peace Lee <[email protected]>

guider [1] is a system-wide performance analyzer for platforms based

Well, it seems to be more of a meta-tool that uses standard tools. In addition, it improves usability at the cost of defining policy such as immediately analyzing some data collection on target. It would be nice to succinctly summarize that if you can.

Quoted 1 line

on linux kernel. it can measure vary system resource usage and

s/it/It/
s/vary/a variety of/

Quoted 2 lines

trace thread/process activities. and it reports vary meaningful output to analyze system status.

It reports very meaningful output to analyze system status.

Quoted 37 lines

[1] https://github.com/iipeace/guider

---
  .../recipes-devtools/guider/guider_3.9.3.bb   | 34 +++++++++++++++++++
  1 file changed, 34 insertions(+)

create mode 100644 meta-oe/recipes-devtools/guider/guider_3.9.3.bb

meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +21 -0
new file mode 100644
index 0000000000..96d6c62ae2
@@ -0,0 +1,34 @@
+SUMMARY = "runtime performance analyzer"
+HOMEPAGE = "https://github.com/iipeace/guider"
+BUGTRACKER = "https://github.com/iipeace/guider/issues"
+AUTHOR = "Peace Lee <[email protected]>"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=2c1c00f9d3ed9e24fa69b932b7e7aff2"
+
+SRC_URI = "git://github.com/iipeace/${BPN}"
+SRCREV = "ac05a2ce0ab480957d642d947d8f617bd224031d"
+
+S = "${WORKDIR}/git"
+R = "${RECIPE_SYSROOT_NATIVE}"
+
+inherit distutils
+
+GUIDER_OBJ = "guider.pyc"
+GUIDER_SCRIPT = "guider"
+
+do_install() {
+    python ${S}/setup.py install

meta-oe/recipes-devtools/guider/guider_3.9.3.bb line 31

Quoted 10 lines
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +10 -0
+
+    install -d ${D}${bindir}
+    install -v -m 0755 ${R}/${bindir}/${GUIDER_SCRIPT} ${D}${bindir}/${GUIDER_SCRIPT}
+
+    install -d ${D}${datadir}/${BPN}
+    install -v -m 0755 ${R}/${datadir}/${BPN}/${GUIDER_OBJ} ${D}${datadir}/${BPN}/${GUIDER_OBJ}
+}
+
+RDEPENDS_${PN} = "python-ctypes python-shell \
+                  python-json python-subprocess"

Shouldn't the packages that guider uses be recommended at least? I'm not familiar with the app so maybe it can do useful things without top, perf, etc.

Should we add a kernel cfg fragment?

meta-oe/recipes-devtools/guider/guider_3.9.3.bb line 34

Quoted 3 lines
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +3 -0
+
+FILES_SOLIBSDEV = ""
+#FILES_${PN} = "usr"

Drop that line?

Quoted 1 line
Signature · 2 lines
# Randy MacLeod
# Wind River Linux
#4 lore raw

Thanks for your advice :)

Should I submit a new patch again after changing a below patch? I am not familiar with this process ;)
It couldn't be reached to openembedded-devel members When I sent patch first so that I sent github pull-request to Khem Raj.

Anyway, I agree with your comments (fixing typos, moving the recipe to meta-tool, dropping last some lines).
But what does "*Shouldn't the packages that guider uses be recommended at least?*" mean?
Guider only requires "python-ctypes, python-shell, python-json, python-subprocess" package :)
Some kernel configurations and patches are needed to trace user-level functions but it depends on users.

Happy new year!

Quoted 88 lines · Randy MacLeod

Neat tool! I'll have to play with it a bit more.

Quoted 3 lines · Khem Raj

From: Peace Lee <[email protected]>

guider [1] is a system-wide performance analyzer for platforms based

Well, it seems to be more of a meta-tool that uses standard tools. In addition, it improves usability at the cost of defining policy such as immediately analyzing some data collection on target. It would be nice to succinctly summarize that if you can.

Quoted 1 line

on linux kernel. it can measure vary system resource usage and

s/it/It/
s/vary/a variety of/

Quoted 2 lines

trace thread/process activities. and it reports vary meaningful output to analyze system status.

It reports very meaningful output to analyze system status.

Review

Quoted 11 lines

[1] https://github.com/iipeace/guider

---
  .../recipes-devtools/guider/guider_3.9.3.bb   | 34 +++++++++++++++++++
  1 file changed, 34 insertions(+)

create mode 100644 meta-oe/recipes-devtools/guider/guider_3.9.3.bb

(quoted diff) +0 -0

b/meta-oe/recipes-devtools/guider/guider_3.9.3.bb

Quoted 5 lines

new file mode 100644
index 0000000000..96d6c62ae2

meta-oe/recipes-devtools/guider/guider_3.9.3.bb line 9

Quoted 9 lines
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +9 -0
@@ -0,0 +1,34 @@
+SUMMARY = "runtime performance analyzer"
+HOMEPAGE = "https://github.com/iipeace/guider"
+BUGTRACKER = "https://github.com/iipeace/guider/issues"
+AUTHOR = "Peace Lee <[email protected]>"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=2c1c00f9d3ed9e24fa69b932b7e7aff2"
+
+SRC_URI = "git://github.com/iipeace/${BPN}

<http://github.com/iipeace/$%7BBPN%7D>"

Quoted 5 lines
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +5 -0
+SRCREV = "ac05a2ce0ab480957d642d947d8f617bd224031d"
+
+S = "${WORKDIR}/git"
+R = "${RECIPE_SYSROOT_NATIVE}"
+

meta-oe/recipes-devtools/guider/guider_3.9.3.bb

Quoted 10 lines
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +10 -0
+inherit distutils
+
+GUIDER_OBJ = "guider.pyc"
+GUIDER_SCRIPT = "guider"
+
+do_install() {
+    python ${S}/setup.py install
+
+    install -d ${D}${bindir}
+    install -v -m 0755 ${R}/${bindir}/${GUIDER_SCRIPT}

${D}${bindir}/${GUIDER_SCRIPT}

meta-oe/recipes-devtools/guider/guider_3.9.3.bb

Quoted 3 lines
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +3 -0
+
+    install -d ${D}${datadir}/${BPN}
+    install -v -m 0755 ${R}/${datadir}/${BPN}/${GUIDER_OBJ}

${D}${datadir}/${BPN}/${GUIDER_OBJ}

meta-oe/recipes-devtools/guider/guider_3.9.3.bb line 31

Quoted 4 lines
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +4 -0
+}
+
+RDEPENDS_${PN} = "python-ctypes python-shell \
+                  python-json python-subprocess"

Shouldn't the packages that guider uses be recommended at least? I'm not familiar with the app so maybe it can do useful things without top, perf, etc.

Should we add a kernel cfg fragment?

meta-oe/recipes-devtools/guider/guider_3.9.3.bb line 34

Quoted 3 lines
meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +3 -0
+
+FILES_SOLIBSDEV = ""
+#FILES_${PN} = "usr"

Drop that line?

Quoted 1 line

--
# Randy MacLeod
# Wind River Linux

#5 lore raw
Quoted 4 lines · Peace Lee

Thanks for your advice :)

Should I submit a new patch again after changing a below patch? I am not familiar with this process ;)

I expect that Khem will do that once he wakes up.

Quoted 1 line

It couldn't be reached to openembedded-devel members When I sent patch first so that I sent github pull-request to Khem Raj.

We send patches to the oe-devel list, people comment, the gatekeeper merges at some point. The process is documented here:

https://www.openembedded.org/wiki/How_to_submit_a_patch_to_OpenEmbedded

Quoted 3 lines

Anyway, I agree with your comments (fixing typos, moving the recipe to meta-tool, dropping last some lines). But what does "_Shouldn't the packages that guider uses be recommended at least?_" mean?

I thought that you were forking top, perf, etc and then screen-scrapping
the output but it seems that you have reimplemented(parts of)
the functionality of these tools so we don't need to add a DEPENDS/RECOMMENDS to the recipe to ensure that top for example is added to the system image.

Quoted 1 line

Guider only requires "python-ctypes, python-shell, python-json, python-subprocess" package :)

Khem's recipe has that covered then:

+RDEPENDS_${PN} = "python-ctypes python-shell \
+ python-json python-subprocess"

Quoted 1 line

Some kernel configurations and patches are needed to trace user-level functions but it depends on users.

The yocto-kenrel-cache:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/00-README

has the concept of features:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/features
such as:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/features/lttng

since this recipe is for meta-openembedded rather than oe-core, we'd leave it up to users as you say. meta-openembedded depends on oe-core but the two projects are organized by different people.

Do you have a document that explains your motivation for creating guider and perhaps documents a few cases where it's better than the standard tools? I likely just need to play with guider a bit more but it seems like a use case that walked people though a performance issue that you resolved more easily with guider than with the plethora of linux tools:
http://www.brendangregg.com/linuxperf.html
would be good marketing.

../Randy

Quoted 101 lines

Happy new year!

On Tue, Jan 1, 2019 at 4:30 AM Randy MacLeod <[email protected] <mailto:[email protected]>> wrote:

    Neat tool! I'll have to play with it a bit more.

    On 12/30/18 11:50 AM, Khem Raj wrote:
     > From: Peace Lee <[email protected] <mailto:[email protected]>>
     >
     > guider [1] is a system-wide performance analyzer for platforms based

    Well, it seems to be more of a meta-tool that uses standard tools.
    In addition, it improves usability at the cost of defining policy
    such as immediately analyzing some data collection on target.
    It would be nice to succinctly summarize that if you can.
     > on linux kernel. it can measure vary system resource usage and
    s/it/It/
    s/vary/a variety of/
     > trace thread/process activities. and it reports vary meaningful
     > output to analyze system status.
    It reports very meaningful output to analyze system status.
     >
     > [1] https://github.com/iipeace/guider
     >
     > Signed-off-by: Peace Lee <[email protected]
    <mailto:[email protected]>>
     > Signed-off-by: Khem Raj <[email protected]
    <mailto:[email protected]>>
     > ---
     >   .../recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>   | 34 +++++++++++++++++++
     >   1 file changed, 34 insertions(+)
     >   create mode 100644
    meta-oe/recipes-devtools/guider/guider_3.9.3.bb <http://guider_3.9.3.bb>
     >
     > diff --git a/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
    b/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
     > new file mode 100644
     > index 0000000000..96d6c62ae2
     > --- /dev/null
     > +++ b/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
     > @@ -0,0 +1,34 @@
     > +SUMMARY = "runtime performance analyzer"
     > +HOMEPAGE = "https://github.com/iipeace/guider"
     > +BUGTRACKER = "https://github.com/iipeace/guider/issues"
     > +AUTHOR = "Peace Lee <[email protected] <mailto:[email protected]>>"
     > +
     > +LICENSE = "GPLv2+"
     > +LIC_FILES_CHKSUM =
    "file://LICENSE;md5=2c1c00f9d3ed9e24fa69b932b7e7aff2"
     > +
     > +SRC_URI = "git://github.com/iipeace/${BPN}
    <http://github.com/iipeace/$%7BBPN%7D>"
     > +SRCREV = "ac05a2ce0ab480957d642d947d8f617bd224031d"
     > +
     > +S = "${WORKDIR}/git"
     > +R = "${RECIPE_SYSROOT_NATIVE}"
     > +
     > +inherit distutils
     > +
     > +GUIDER_OBJ = "guider.pyc"
     > +GUIDER_SCRIPT = "guider"
     > +
     > +do_install() {
     > +    python ${S}/setup.py install
     > +
     > +    install -d ${D}${bindir}
     > +    install -v -m 0755 ${R}/${bindir}/${GUIDER_SCRIPT}
    ${D}${bindir}/${GUIDER_SCRIPT}
     > +
     > +    install -d ${D}${datadir}/${BPN}
     > +    install -v -m 0755 ${R}/${datadir}/${BPN}/${GUIDER_OBJ}
    ${D}${datadir}/${BPN}/${GUIDER_OBJ}
     > +}
     > +
     > +RDEPENDS_${PN} = "python-ctypes python-shell \
     > +                  python-json python-subprocess"

    Shouldn't the packages that guider uses be recommended at least?
    I'm not familiar with the app so maybe it can do useful things without
    top, perf, etc.

    Should we add a kernel cfg fragment?

     > +
     > +FILES_SOLIBSDEV = ""
     > +#FILES_${PN} = "usr"
    Drop that line?

     >



    -- 
    # Randy MacLeod
    # Wind River Linux
Signature · 2 lines
# Randy MacLeod
# Wind River Linux
author
#6 lore raw
Quoted 9 lines · Randy MacLeod
Quoted 4 lines · Peace Lee

Thanks for your advice :)

Should I submit a new patch again after changing a below patch? I am not familiar with this process ;)

I expect that Khem will do that once he wakes up.

Quoted 8 lines
Quoted 2 lines

It couldn't be reached to openembedded-devel members When I sent patch first so that I sent github pull-request to Khem Raj.

We send patches to the oe-devel list, people comment, the gatekeeper merges at some point. The process is documented here:

https://www.openembedded.org/wiki/How_to_submit_a_patch_to_OpenEmbedded

Yes please prepare a v2 and its ok if you want to update your current pull on GH I can bring it into ml.

Quoted 158 lines
Quoted 5 lines

Anyway, I agree with your comments (fixing typos, moving the recipe to meta-tool, dropping last some lines).
But what does "_Shouldn't the packages that guider uses be recommended at least?_" mean?

I thought that you were forking top, perf, etc and then screen-scrapping
the output but it seems that you have reimplemented(parts of)
the functionality of these tools so we don't need to add a DEPENDS/RECOMMENDS to the recipe to ensure that top for example is added to the system image.

Quoted 2 lines

Guider only requires "python-ctypes, python-shell, python-json, python-subprocess" package :)

Khem's recipe has that covered then:

meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +2 -0
+RDEPENDS_${PN} = "python-ctypes python-shell \
+                  python-json python-subprocess"
Quoted 3 lines

Some kernel configurations and patches are needed to trace user-level functions but it depends on users.

The yocto-kenrel-cache:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/00-README

has the concept of features:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/features
such as:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/features/lttng

since this recipe is for meta-openembedded rather than oe-core, we'd leave it up to users as you say. meta-openembedded depends on oe-core but the two projects are organized by different people.

Do you have a document that explains your motivation for creating guider and perhaps documents a few cases where it's better than the standard tools? I likely just need to play with guider a bit more but it seems like a use case that walked people though a performance issue that you resolved more easily with guider than with the plethora of linux tools:
http://www.brendangregg.com/linuxperf.html
would be good marketing.

../Randy

Quoted 94 lines

Happy new year!

On Tue, Jan 1, 2019 at 4:30 AM Randy MacLeod <[email protected] <mailto:[email protected]>> wrote:

    Neat tool! I'll have to play with it a bit more.

    On 12/30/18 11:50 AM, Khem Raj wrote:
     > From: Peace Lee <[email protected] <mailto:[email protected]>>
     >
     > guider [1] is a system-wide performance analyzer for platforms based

    Well, it seems to be more of a meta-tool that uses standard tools.
    In addition, it improves usability at the cost of defining policy
    such as immediately analyzing some data collection on target.
    It would be nice to succinctly summarize that if you can.
     > on linux kernel. it can measure vary system resource usage and
    s/it/It/
    s/vary/a variety of/
     > trace thread/process activities. and it reports vary meaningful
     > output to analyze system status.
    It reports very meaningful output to analyze system status.
     >
     > [1] https://github.com/iipeace/guider
     >
     > Signed-off-by: Peace Lee <[email protected]
    <mailto:[email protected]>>
     > Signed-off-by: Khem Raj <[email protected]
    <mailto:[email protected]>>
     > ---
     >   .../recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>   | 34 +++++++++++++++++++
     >   1 file changed, 34 insertions(+)
     >   create mode 100644
    meta-oe/recipes-devtools/guider/guider_3.9.3.bb <http://guider_3.9.3.bb>
     >
     > diff --git a/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
    b/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
     > new file mode 100644
     > index 0000000000..96d6c62ae2
     > --- /dev/null
     > +++ b/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
     > @@ -0,0 +1,34 @@
     > +SUMMARY = "runtime performance analyzer"
     > +HOMEPAGE = "https://github.com/iipeace/guider"
     > +BUGTRACKER = "https://github.com/iipeace/guider/issues"
     > +AUTHOR = "Peace Lee <[email protected] <mailto:[email protected]>>"
     > +
     > +LICENSE = "GPLv2+"
     > +LIC_FILES_CHKSUM =
    "file://LICENSE;md5=2c1c00f9d3ed9e24fa69b932b7e7aff2"
     > +
     > +SRC_URI = "git://github.com/iipeace/${BPN}
    <http://github.com/iipeace/$%7BBPN%7D>"
     > +SRCREV = "ac05a2ce0ab480957d642d947d8f617bd224031d"
     > +
     > +S = "${WORKDIR}/git"
     > +R = "${RECIPE_SYSROOT_NATIVE}"
     > +
     > +inherit distutils
     > +
     > +GUIDER_OBJ = "guider.pyc"
     > +GUIDER_SCRIPT = "guider"
     > +
     > +do_install() {
     > +    python ${S}/setup.py install
     > +
     > +    install -d ${D}${bindir}
     > +    install -v -m 0755 ${R}/${bindir}/${GUIDER_SCRIPT}
    ${D}${bindir}/${GUIDER_SCRIPT}
     > +
     > +    install -d ${D}${datadir}/${BPN}
     > +    install -v -m 0755 ${R}/${datadir}/${BPN}/${GUIDER_OBJ}
    ${D}${datadir}/${BPN}/${GUIDER_OBJ}
     > +}
     > +
     > +RDEPENDS_${PN} = "python-ctypes python-shell \
     > +                  python-json python-subprocess"

    Shouldn't the packages that guider uses be recommended at least?
    I'm not familiar with the app so maybe it can do useful things without
    top, perf, etc.

    Should we add a kernel cfg fragment?

     > +
     > +FILES_SOLIBSDEV = ""
     > +#FILES_${PN} = "usr"
    Drop that line?
Quoted 8 lines
     >



    --
    # Randy MacLeod
    # Wind River Linux

--
# Randy MacLeod
# Wind River Linux

#7 lore raw
In reply to Randy MacLeod

Thanks for your advice Randy :)

Quoted 7 lines

Do you have a document that explains your motivation for creating guider and perhaps documents a few cases where it's better than the standard tools? I likely just need to play with guider a bit more but it seems like a use case that walked people though a performance issue that you resolved more easily with guider than with the plethora of linux tools:
http://www.brendangregg.com/linuxperf.html
would be good marketing.

The document for guider is only available at
https://iipeace.github.io/docs/guider.html.
I think so that I need to write more documents and articles for users of guider.
It's my plan for this year :)

I submitted patch v2 to GitHub,
please check it out if Khem Raj move it to ML.

Thanks.
Peace Lee.

Quoted 182 lines · Randy MacLeod
Quoted 4 lines · Peace Lee

Thanks for your advice :)

Should I submit a new patch again after changing a below patch? I am not familiar with this process ;)

I expect that Khem will do that once he wakes up.

Quoted 2 lines

It couldn't be reached to openembedded-devel members When I sent patch first so that I sent github pull-request to Khem Raj.

We send patches to the oe-devel list, people comment, the gatekeeper merges at some point. The process is documented here:

https://www.openembedded.org/wiki/How_to_submit_a_patch_to_OpenEmbedded

Quoted 5 lines

Anyway, I agree with your comments (fixing typos, moving the recipe to meta-tool, dropping last some lines).
But what does "_Shouldn't the packages that guider uses be recommended at least?_" mean?

I thought that you were forking top, perf, etc and then screen-scrapping
the output but it seems that you have reimplemented(parts of)
the functionality of these tools so we don't need to add a DEPENDS/RECOMMENDS to the recipe to ensure that top for example is added to the system image.

Quoted 2 lines

Guider only requires "python-ctypes, python-shell, python-json, python-subprocess" package :)

Khem's recipe has that covered then:

meta-oe/recipes-devtools/guider/guider_3.9.3.bb new file +2 -0
+RDEPENDS_${PN} = "python-ctypes python-shell \
+                  python-json python-subprocess"
Quoted 3 lines

Some kernel configurations and patches are needed to trace user-level functions but it depends on users.

The yocto-kenrel-cache:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/00-README

has the concept of features:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/features
such as:

http://git.yoctoproject.org/cgit/cgit.cgi/yocto-kernel-cache/tree/features/lttng

since this recipe is for meta-openembedded rather than oe-core, we'd leave it up to users as you say. meta-openembedded depends on oe-core but the two projects are organized by different people.

Do you have a document that explains your motivation for creating guider and perhaps documents a few cases where it's better than the standard tools? I likely just need to play with guider a bit more but it seems like a use case that walked people though a performance issue that you resolved more easily with guider than with the plethora of linux tools:
http://www.brendangregg.com/linuxperf.html
would be good marketing.

../Randy

Quoted 5 lines

Happy new year!

On Tue, Jan 1, 2019 at 4:30 AM Randy MacLeod <[email protected] <mailto:[email protected]>>

Quoted 7 lines · wrote:

Neat tool! I'll have to play with it a bit more.

On 12/30/18 11:50 AM, Khem Raj wrote:
> From: Peace Lee <[email protected] <mailto:[email protected]>> >
> guider [1] is a system-wide performance analyzer for platforms

based

Quoted 16 lines

Well, it seems to be more of a meta-tool that uses standard tools. In addition, it improves usability at the cost of defining policy such as immediately analyzing some data collection on target. It would be nice to succinctly summarize that if you can.
> on linux kernel. it can measure vary system resource usage and
s/it/It/
s/vary/a variety of/
> trace thread/process activities. and it reports vary meaningful > output to analyze system status.
It reports very meaningful output to analyze system status.
>
> [1] https://github.com/iipeace/guider
>
> Signed-off-by: Peace Lee <[email protected]
<mailto:[email protected]>>

Quoted 8 lines

> Signed-off-by: Khem Raj <[email protected]
<mailto:[email protected]>>
> ---
> .../recipes-devtools/guider/guider_3.9.3.bb
<http://guider_3.9.3.bb> | 34 +++++++++++++++++++
> 1 file changed, 34 insertions(+)
> create mode 100644
meta-oe/recipes-devtools/guider/guider_3.9.3.bb <

http://guider_3.9.3.bb>

Quoted 15 lines
     >
     > diff --git a/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
    b/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
     > new file mode 100644
     > index 0000000000..96d6c62ae2
     > --- /dev/null
     > +++ b/meta-oe/recipes-devtools/guider/guider_3.9.3.bb
    <http://guider_3.9.3.bb>
     > @@ -0,0 +1,34 @@
     > +SUMMARY = "runtime performance analyzer"
     > +HOMEPAGE = "https://github.com/iipeace/guider"
     > +BUGTRACKER = "https://github.com/iipeace/guider/issues"
     > +AUTHOR = "Peace Lee <[email protected] <mailto:[email protected]
Quoted 7 lines
Quoted 1 line

"

     > +
     > +LICENSE = "GPLv2+"
     > +LIC_FILES_CHKSUM =
    "file://LICENSE;md5=2c1c00f9d3ed9e24fa69b932b7e7aff2"
     > +
     > +SRC_URI = "git://github.com/iipeace/${BPN}

<http://github.com/iipeace/$%7BBPN%7D>

Quoted 20 lines
    <http://github.com/iipeace/$%7BBPN%7D>"
     > +SRCREV = "ac05a2ce0ab480957d642d947d8f617bd224031d"
     > +
     > +S = "${WORKDIR}/git"
     > +R = "${RECIPE_SYSROOT_NATIVE}"
     > +
     > +inherit distutils
     > +
     > +GUIDER_OBJ = "guider.pyc"
     > +GUIDER_SCRIPT = "guider"
     > +
     > +do_install() {
     > +    python ${S}/setup.py install
     > +
     > +    install -d ${D}${bindir}
     > +    install -v -m 0755 ${R}/${bindir}/${GUIDER_SCRIPT}
    ${D}${bindir}/${GUIDER_SCRIPT}
     > +
     > +    install -d ${D}${datadir}/${BPN}
     > +    install -v -m 0755 ${R}/${datadir}/${BPN}/${GUIDER_OBJ}
Quoted 8 lines
    ${D}${datadir}/${BPN}/${GUIDER_OBJ}
     > +}
     > +
     > +RDEPENDS_${PN} = "python-ctypes python-shell \
     > +                  python-json python-subprocess"

    Shouldn't the packages that guider uses be recommended at least?
    I'm not familiar with the app so maybe it can do useful things

without

Quoted 9 lines

top, perf, etc.

Should we add a kernel cfg fragment?

> +
> +FILES_SOLIBSDEV = ""
> +#FILES_${PN} = "usr"
Drop that line?

Quoted 8 lines

>

--
# Randy MacLeod
# Wind River Linux

--
# Randy MacLeod
# Wind River Linux