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

Fix bug with id_pat and read_bytes_const #479

Merged
merged 1 commit into from
Sep 8, 2024

Conversation

wcampbell0x2a
Copy link
Collaborator

  • Fix setting last read length, intsead of incorrectly adding

Copy link

github-actions bot commented Sep 7, 2024

Benchmark for 00814fa

Click to view benchmark
Test Base PR %
count 5.0±0.01µs 3.5±0.05µs -30.00%
deku_read_bits 1211.2±20.57ns 1143.4±38.68ns -5.60%
deku_read_byte 6.1±0.03ns 5.9±0.04ns -3.28%
deku_read_enum 4.5±0.06ns 4.7±0.06ns +4.44%
deku_read_vec 43.1±0.33ns 30.1±0.38ns -30.16%
deku_write_bits 184.5±4.73ns 180.1±5.15ns -2.38%
deku_write_byte 24.9±0.43ns 24.6±0.57ns -1.20%
deku_write_enum 23.0±0.37ns 22.7±0.41ns -1.30%
deku_write_vec 416.3±8.28ns 400.6±5.63ns -3.77%
read_all 5.5±0.02µs 3.8±0.07µs -30.91%
read_all_bytes 5.6±0.07µs 3.9±0.08µs -30.36%

@wcampbell0x2a wcampbell0x2a force-pushed the properly-increment-already-read-bits branch from 6ffc9eb to 0440037 Compare September 7, 2024 16:33
Copy link

github-actions bot commented Sep 7, 2024

Benchmark for 94f9658

Click to view benchmark
Test Base PR %
count 5.0±0.01µs 2.7±0.04µs -46.00%
deku_read_bits 1162.8±23.87ns 1204.9±11.98ns +3.62%
deku_read_byte 5.9±0.04ns 5.3±0.11ns -10.17%
deku_read_enum 4.7±0.02ns 4.4±0.04ns -6.38%
deku_read_vec 42.2±0.34ns 31.9±0.47ns -24.41%
deku_write_bits 184.2±6.48ns 180.0±3.48ns -2.28%
deku_write_byte 24.8±0.17ns 24.5±0.22ns -1.21%
deku_write_enum 23.0±0.46ns 22.7±0.75ns -1.30%
deku_write_vec 413.7±6.51ns 402.2±4.36ns -2.78%
read_all 3.7±0.06µs 5.5±0.03µs +48.65%
read_all_bytes 3.8±0.07µs 5.5±0.04µs +44.74%

* Reset last_bit_read_amt before reading for enum id
* Always add to last_bits_read_amt
@wcampbell0x2a wcampbell0x2a force-pushed the properly-increment-already-read-bits branch from 0440037 to e95d055 Compare September 7, 2024 17:15
Copy link

github-actions bot commented Sep 7, 2024

Benchmark for 0a1e1a4

Click to view benchmark
Test Base PR %
count 5.0±0.01µs 5.0±0.01µs 0.00%
deku_read_bits 1243.0±12.79ns 1179.2±13.82ns -5.13%
deku_read_byte 6.1±0.22ns 5.2±0.03ns -14.75%
deku_read_enum 4.5±0.07ns 4.4±0.02ns -2.22%
deku_read_vec 43.1±0.21ns 41.8±1.49ns -3.02%
deku_write_bits 186.0±2.78ns 183.4±1.91ns -1.40%
deku_write_byte 24.9±0.39ns 24.9±0.45ns 0.00%
deku_write_enum 23.0±0.35ns 22.7±0.51ns -1.30%
deku_write_vec 425.2±7.46ns 411.9±4.15ns -3.13%
read_all 5.5±0.04µs 5.6±0.09µs +1.82%
read_all_bytes 5.5±0.03µs 5.6±0.02µs +1.82%

@sharksforarms
Copy link
Owner

Thanks 🙏

@sharksforarms sharksforarms merged commit c4b78b2 into master Sep 8, 2024
15 checks passed
@sharksforarms sharksforarms deleted the properly-increment-already-read-bits branch September 8, 2024 04:34
@sharksforarms
Copy link
Owner

Will release a 0.18.1 tomorrow.

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.

2 participants