Skip to content

Conversation

@antonfirsov
Copy link
Member

Prerequisites

  • I have written a descriptive pull-request title
  • I have verified that there are no overlapping pull-requests open
  • I have verified that I am following the existing coding patterns and practice as demonstrated in the repository. These follow strict Stylecop rules 👮.
  • I have provided test coverage for my change (where applicable)

Description

The buffer allocation/disposal has shown up as a small but visible bottleneck in PNG decoder profiling results. Headers are always very small, we should stackalloc the buffer for them.

@codecov
Copy link

codecov bot commented Nov 7, 2021

Codecov Report

Merging #1812 (af90336) into master (a06011a) will increase coverage by 0.14%.
The diff coverage is 85.71%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1812      +/-   ##
==========================================
+ Coverage   87.19%   87.33%   +0.14%     
==========================================
  Files         936      936              
  Lines       47920    47922       +2     
  Branches     6012     6016       +4     
==========================================
+ Hits        41783    41852      +69     
+ Misses       5144     5078      -66     
+ Partials      993      992       -1     
Flag Coverage Δ
unittests 87.33% <85.71%> (+0.14%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/ImageSharp/Image.Decode.cs 86.76% <85.71%> (-1.12%) ⬇️
...ageSharp/Formats/Webp/Lossless/PredictorEncoder.cs 98.10% <0.00%> (+5.29%) ⬆️
.../ImageSharp/Formats/Webp/Lossless/LosslessUtils.cs 97.61% <0.00%> (+6.80%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a06011a...af90336. Read the comment docs.

Copy link
Member

@JimBobSquarePants JimBobSquarePants left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice easy one to review this 👍

@JimBobSquarePants JimBobSquarePants merged commit 94b9962 into master Nov 8, 2021
@JimBobSquarePants JimBobSquarePants deleted the af/InternalDetectFormat-DoNotAllocate branch November 8, 2021 15:26
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.

3 participants