Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Speed up Image.offset#9753

Open
akx wants to merge 1 commit into
python-pillow:mainpython-pillow/Pillow:mainfrom
akx:faster-offsetakx/Pillow:faster-offsetCopy head branch name to clipboard
Open

Speed up Image.offset#9753
akx wants to merge 1 commit into
python-pillow:mainpython-pillow/Pillow:mainfrom
akx:faster-offsetakx/Pillow:faster-offsetCopy head branch name to clipboard

Conversation

@akx

@akx akx commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

As #9649, #9675, #9736, #9737, #9738, #9739, #9740, #9743 (same techniques).

@codspeed-hq

codspeed-hq Bot commented Jul 1, 2026

Copy link
Copy Markdown

Merging this PR will improve performance by 42.2%

⚠️ Different runtime environments detected

Some benchmarks with significant performance changes were compared across different runtime environments,
which may affect the accuracy of the results.

Open the report in CodSpeed to investigate

⚡ 4 improved benchmarks
✅ 341 untouched benchmarks
⏩ 2 skipped benchmarks1

Performance Changes

Benchmark BASE HEAD Efficiency
test_offset[1024x1024-L] 8.9 ms 4.8 ms +84.75%
test_offset[1024x1024-RGBA] 10 ms 7.7 ms +30.33%
test_offset[1024x1024-LA] 10 ms 7.7 ms +30.32%
test_offset[1024x1024-RGB] 10 ms 7.7 ms +30.3%

Tip

Curious why this is faster? Comment @codspeedbot explain why this is faster on this PR, or directly use the CodSpeed MCP with your agent.


Comparing akx:faster-offset (20ecf42) with main (8f86212)

Open in CodSpeed

Footnotes

  1. 2 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@akx
akx marked this pull request as ready for review July 1, 2026 17:51
Comment thread src/libImaging/Offset.c Outdated
@akx
akx force-pushed the faster-offset branch from 4cb80ba to 53568b1 Compare July 4, 2026 10:30
Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
@akx
akx force-pushed the faster-offset branch from 53568b1 to 20ecf42 Compare July 20, 2026 07:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.