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

Major optimization 6x faster #40

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

Curid
Copy link

@Curid Curid commented Aug 10, 2022

RTP to MPEGTS benchmark.
Before: 33556858 ns/op  4763101 B/op
After:   5169437 ns/op  3881852 B/op

I wrote this a few months ago and have been using it in production for weeks on end without issues. I no longer have a use for mpegts library, so I figured you could have it. There may be some small breaking changes, but all tests pass.

Changes:

  • Use icza/bitio for bit manipulation
  • Dynamic CRC32 calculation
  • Don't use fmt.Sprintf when parsing timestamp

@asticode
Copy link
Owner

Thanks! Could you create a PR with the optimizations only and not the reformatting/linting changes ?

@asticode asticode force-pushed the master branch 2 times, most recently from 106bbe5 to 0df190a Compare July 27, 2023 09:41
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

Successfully merging this pull request may close these issues.

None yet

2 participants