Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimization pass #154

Closed
noahlevenson opened this issue May 5, 2023 · 1 comment
Closed

Optimization pass #154

noahlevenson opened this issue May 5, 2023 · 1 comment

Comments

@noahlevenson
Copy link
Contributor

The clients in particular have never been optimized. I've been holding most of the optimization ideas in my head since fall of 2022. There's lots of hot paths that are clearly inefficient. We just never had time to take a pass at it.

@oxtoacart, via Slack:

I'm download a very large file and watching a YouTube video, and CPU usage is quite high

Showing top 20 nodes out of 138
      flat  flat%   sum%        cum   cum%
     0.01s 0.024% 0.024%     15.67s 37.91%  runtime.systemstack
     0.02s 0.048% 0.073%     15.52s 37.55%  runtime.wakep
         0     0% 0.073%     15.50s 37.50%  runtime.startm
    15.48s 37.45% 37.53%     15.48s 37.45%  runtime.pthread_cond_signal
         0     0% 37.53%     15.48s 37.45%  runtime.semawakeup
         0     0% 37.53%     15.46s 37.41%  runtime.notewakeup
     0.01s 0.024% 37.55%     14.65s 35.45%  runtime.goready.func1
         0     0% 37.55%     14.64s 35.42%  runtime.ready
         0     0% 37.55%      6.14s 14.86%  runtime.mcall
         0     0% 37.55%      6.08s 14.71%  runtime.schedule
         0     0% 37.55%      5.82s 14.08%  runtime.park_m
     0.01s 0.024% 37.58%      5.60s 13.55%  runtime.findRunnable
         0     0% 37.58%      5.37s 12.99%  runtime._System
         0     0% 37.58%      4.78s 11.57%  github.com/pion/sctp.(*Association).readLoop
         0     0% 37.58%      4.76s 11.52%  github.com/pion/sctp.(*Association).handleInbound
         0     0% 37.58%      4.74s 11.47%  github.com/pion/sctp.(*Association).handleChunk
         0     0% 37.58%      4.74s 11.47%  github.com/pion/sctp.(*Association).handleSack
     0.02s 0.048% 37.62%      4.72s 11.42%  github.com/pion/sctp.(*Association).processSelectiveAck
         0     0% 37.62%      4.68s 11.32%  github.com/pion/sctp.(*payloadQueue).pop
     0.01s 0.024% 37.65%      4.68s 11.32%  github.com/pion/sctp.(*payloadQueue).updateSortedKeys
Showing top 20 nodes out of 138
      flat  flat%   sum%        cum   cum%
    15.48s 37.45% 37.45%     15.48s 37.45%  runtime.pthread_cond_signal
     3.06s  7.40% 44.86%      3.06s  7.40%  runtime.pthread_cond_wait
@noahlevenson
Copy link
Contributor Author

Duplicate of #165

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant