GithubHelp home page GithubHelp logo

Comments (11)

retronym avatar retronym commented on July 26, 2024 6

JMH 1.24 includes -prof async.

from async-profiler.

retronym avatar retronym commented on July 26, 2024 2

from async-profiler.

nitsanw avatar nitsanw commented on July 26, 2024 1

@leventov OK, reading the conversation more closely I think I understand your requirement, still not sure async-profiler is the place for it, but lets see.
I believe what you are looking for is a jmh-profiler integration for async-profiler:

  • profile only includes the measurement period
  • profiler is started with some command line param, e.g: `-prof async-profiler:e=cpu,...

I think I misunderstood what you meant by including only the benchmark methods, I believe what you meant is include only the measurement period, which is the standard way JMH profilers work. That makes sense?
From my recollections of looking at profiler integration for JMH this is very doable, but it's not clear to me that such a project needs to be part of the async-profiler repo. It would make sense IMO to have it in it's own repo, and require users to include it in their "project to be profiled" and expect them to install async-profiler separately. This is consistent with the perf profiler experience(except that it is internal and therefore requires no extra dep).
Makes sense?

from async-profiler.

apangin avatar apangin commented on July 26, 2024

async-profiler produces output in a simple text format that you can easily filter with grep etc.

from async-profiler.

nitsanw avatar nitsanw commented on July 26, 2024

from async-profiler.

retronym avatar retronym commented on July 26, 2024

from async-profiler.

leventov avatar leventov commented on July 26, 2024

@nitsanw in my case @Setup contains some very heavy stuff, in fact heavier than the execution itself, and it contaminates the profile. It doesn't make the analysis impossible, but harder.

You can say the same thing about JMH's -gc option - why would you not include GC in benchmarking, it's a part of a real application. But sometimes this option is useful.

from async-profiler.

leventov avatar leventov commented on July 26, 2024

@apangin yes, it could probably be something as simple as after-the-fact filtering (although I think not as primitive as grep). I just think it's worth to maintain such utility in the async-profiler repository.

from async-profiler.

apangin avatar apangin commented on July 26, 2024

Why grep is not enough? What else do you expect from the feature?

from async-profiler.

apangin avatar apangin commented on July 26, 2024
  1. Async-profiler has both external API and now internal Java API that is enough for integration with other tools.
  2. There is already AsyncProfiler plugin for JMH available here.
  3. JMH profilers may depend on external tools (for example, perf or dtrace), but async-profiler hardly depends on JMH.
    So, I believe async-profiler requires no further actions regarding this issue.

from async-profiler.

retronym avatar retronym commented on July 26, 2024

I'm going to contribute an async-profiler integration to JMH. Here's my work so far: retronym/jmh#2

from async-profiler.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.