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

DecodeUlawRead and DecodeAlawRead to accept buffer instead returning #4

Closed
emiago opened this issue Mar 6, 2024 · 1 comment
Closed

Comments

@emiago
Copy link

emiago commented Mar 6, 2024

Add
DecodeUlaw and DecodeAlaw as one more alternative where you accept buffer for PC instead returning it.

Caller can make reuse of buffer memory, considering this are uncompressed formats and size can be calculated.
Should be small fix to add?

@emiago emiago closed this as completed Mar 6, 2024
@emiago emiago reopened this Mar 6, 2024
@zaf
Copy link
Owner

zaf commented Dec 14, 2024

It will be addressed here: #3
It introduces functions that use user defined buffers:

BenchmarkEncodeUlaw-4     	   13824	     86166 ns/op	 472.39 MB/s	   20480 B/op	       1 allocs/op
BenchmarkEncodeUlawTo-4   	   14311	     82727 ns/op	 492.03 MB/s	       0 B/op	       0 allocs/op
BenchmarkDecodeUlaw-4     	   35204	     33762 ns/op	 602.82 MB/s	   40960 B/op	       1 allocs/op
BenchmarkDecodeUlawTo-4   	   45838	     25614 ns/op	 794.58 MB/s	       0 B/op	       0 allocs/op
BenchmarkUlaw2Alaw-4      	   78462	     14701 ns/op	1384.36 MB/s	   20480 B/op	       1 allocs/op
BenchmarkUlaw2AlawTo-4    	  101139	     11891 ns/op	1711.47 MB/s	       0 B/op	       0 allocs/op

@zaf zaf closed this as completed Dec 14, 2024
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

2 participants