Skip to content

Sync S16: merge upstream PDFium up to 2b52a82ab (Nov 2 2026) - #112

Merged
bobsingor merged 15 commits into
embedpdf/mainfrom
embedpdf/sync/2b52a82ab
Nov 4, 2026
Merged

bobsingor merged 15 commits into
embedpdf/mainfrom
embedpdf/sync/2b52a82ab

Conversation

@bobsingor

Copy link
Copy Markdown
Contributor

Release-gate sync: 14 upstream commits, 5f092b5 to 2b52a82 (the newest at least a day old). Report: docs/embedpdf/syncs/2026-11-04-2b52a82ab.md.

  • Upstream removed the "standard" CMYK conversion for images drawn with a soft mask or a non-normal blend mode (2b52a82ab); they now convert CMYK like everything else, so such images render slightly differently. Our decoded image store no longer keys on the removed bStdCS flag, and the image redactor calls the loader without it.
  • Images with a Pattern color space fail to load instead of reaching a NOTREACHED() crash (bbb9926d4).
  • Skia, V8, ICU, zlib and test tool rolls; every target's patches still apply.
  • No conflicts; no API change.
  • Layer-mode writers: records EPDFAnnotEmbedderTest.AcrobatCommentWrittenBackReadsTheSame, which Write a markup annotation's comment as rich text #110 added without recording (the release gate would reject it), and the current object counts.

Local checks (darwin-arm64): 1320 unit tests pass; embedder tests unchanged (the 12 known Mac golden failures); layer mode; tag, C API, globals and exports checks; every target's patches; wasm32 build.

If you run CI on this branch, let it finish before merging: merging deletes the branch, and build jobs that start afterwards fail at checkout. Merge with a merge commit, not squash.

pdfium-autoroll@skia-public.iam.gserviceaccount.com and others added 15 commits November 1, 2026 20:52
https://chromium.googlesource.com/chromium/src/third_party/jinja2.git/+log/c3027d884967..fde3c16799bd

If this roll has caused a breakage, revert this CL and set the roller
to dry run mode using the controls here:
https://autoroll.skia.org/r/jinja2-pdfium
Please CC dhoss@chromium.org,thestig@chromium.org,thestig@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Change-Id: I25a3ba2f0ffb1c0887600e164c7f614cd533a163
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162870
Bot-Commit: pdfium-autoroll@skia-public.iam.gserviceaccount.com <pdfium-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: pdfium-autoroll@skia-public.iam.gserviceaccount.com <pdfium-autoroll@skia-public.iam.gserviceaccount.com>
https://chromium.googlesource.com/catapult.git/+log/e1165abbf12a..c29dedc30c9f

If this roll has caused a breakage, revert this CL and set the roller
to dry run mode using the controls here:
https://autoroll.skia.org/r/catapult-pdfium
Please CC dhoss@chromium.org,thestig@chromium.org,thestig@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Change-Id: I8465c2a86ffaa39596c8bdcfa473364f9e3dba24
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162871
Bot-Commit: pdfium-autoroll@skia-public.iam.gserviceaccount.com <pdfium-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: pdfium-autoroll@skia-public.iam.gserviceaccount.com <pdfium-autoroll@skia-public.iam.gserviceaccount.com>
https://chromium.googlesource.com/chromium/src/third_party/zlib.git/+log/456ae730017b..9f9f52c60a14

If this roll has caused a breakage, revert this CL and set the roller
to dry run mode using the controls here:
https://autoroll.skia.org/r/zlib-pdfium
Please CC thestig@chromium.org,thestig@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Change-Id: I6da52876900e0dfb62c4398bcc151df2530b2d4a
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162890
Bot-Commit: pdfium-autoroll@skia-public.iam.gserviceaccount.com <pdfium-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: pdfium-autoroll@skia-public.iam.gserviceaccount.com <pdfium-autoroll@skia-public.iam.gserviceaccount.com>
Reclient (reproxy) and buildtools/reclient have been removed. Merge the
download_and_configure_reclient_cfgs hooks in DEPS and stop passing
--reproxy_cfg_template and --use_luci_auth_credshelper.

Bug: 379584977
Change-Id: I65c1511676521f04e0d2f55f9ef4c9edfaf37590
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162850
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Auto-Submit: Fumitoshi Ukai <ukai@google.com>
https://chromium.googlesource.com/chromium/src/tools/win.git/+log/ae34cdd9867c..d72db9e30405

Created with:
  roll-dep tools/win

Change-Id: I018519985e92700765211d1a6878e7ea3a3a254f
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162790
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Auto-Submit: Lei Zhang <thestig@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
https://chromium.googlesource.com/chromium/deps/icu.git/+log/5aa526207171..a0ea93436c52

Created with:
  roll-dep third_party/icu

Change-Id: I8a9414acbc581ebe23fd6e737062a588ab1492b7
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162791
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Auto-Submit: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
https://chromium.googlesource.com/external/github.com/fastfloat/fast_float.git/+log/b0ab987b3dfd..42f254836ee4

Created with:
  roll-dep third_party/fast_float/src

Change-Id: I7ea08f7e6a13ffc4252ffa5e36da8885f98acfad
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162751
Auto-Submit: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
https://chromium.googlesource.com/external/github.com/google/googletest.git/+log/4fe3307fb2d9..0b656495436f

Created with:
  roll-dep third_party/googletest/src

Change-Id: I28ebf45fb0f7f71d2f3b01f0570ee741ab640305
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162770
Auto-Submit: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
…rolls)

https://skia.googlesource.com/skia.git/+log/0abfcf118530..607de4b035dc

Created with:
  roll-dep third_party/skia

Change-Id: I37907bf68345a8bc457b48d56765370c246c3d53
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162810
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
https://chromium.googlesource.com/v8/v8.git/+log/0d546234ecf0..bb54fc4e853a

Version 15.9.42

Explicitly set GN v8_enable_ecma402_icu4x = false to avoid an
unconditional dependency on Rust for an unused feature.

Created with:
  roll-dep v8

Change-Id: Ie28b457b4fe180157616bcc4188aede97b2da260
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162830
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
https://chromium.googlesource.com/external/github.com/llvm/llvm-project/libc.git/+log/14e51fd2cd7e..d8f2045008e2

Created with:
  roll-dep third_party/llvm-libc/src

Change-Id: I34f0d023ab44adc2f57c74d2a0635e31472f19bb
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162930
Reviewed-by: Andy Phan <andyphan@chromium.org>
Commit-Queue: Andy Phan <andyphan@chromium.org>
Auto-Submit: Lei Zhang <thestig@chromium.org>
Follow Google C++ style by eliminating Hungarian notation prefix
and using snake_case for the boolean parameter. Also update the
comments to clarify that transparency masks are only valid for CMYK
colorspaces and not the specific non-CMYK color space.

No functional change.

Change-Id: I5676029bbbebd50f893d72c2510fb47b83863e74
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162950
Commit-Queue: Lei Zhang <thestig@chromium.org>
Auto-Submit: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
ISO 32000-1:2008, section 8.9.5.1, table 89 states that the ColorSpace
entry of an image dictionary "can be any type of color space except
Pattern". Make CPDF_DIB::LoadColorInfo() fail when the image color
space family is CPDF_ColorSpace::Family::kPattern.

Previously, an 8 bpc image with a Pattern color space and a default
decode array caused CPDF_DIB::TranslateScanline24bppDefaultDecode() to
call CPDF_ColorSpace::TranslateImageLine() on a CPDF_PatternCS, which
hits the NOTREACHED() in CPDF_PatternCS::GetRGB(). Rejecting the color
space up front avoids this, and allows removing the scattered kPattern
checks elsewhere in CPDF_DIB that are now dead code.

Add an embedder test with an image using [/Pattern /DeviceRGB] that
previously crashed on the NOTREACHED().

Fixed: 581053336
Change-Id: I46fd4d9147de92ae06bc6c49e4303db5925fea9a
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/162910
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
CPDF_ColorSpace::IsStdConversionEnabled() is only checked in
CPDF_DeviceCS::GetRGB() and CPDF_DeviceCS::TranslateImageLine() for
`Family::kDeviceCMYK`, where it switches from AdobeCmykToStandardRgb()
to a simple `1 - min(1, C + K)` formula when `bStdCS` is set to true
(e.g. when rendering images with non-normal blend modes or soft masks).

This code has two callers:

1. CPDF_DeviceCS::TranslateImageLine() is unreachable because CPDF_DIB
   resets EnableStdConversion() when image loading finishes, before
   CPDF_DIB::GetScanline() translates scanlines.
2. CPDF_DeviceCS::GetRGB() is reachable from the bug_557320961 pixel
   test. However, the rendered output with the IsStdConversionEnabled()
   code path does not match other PDF renderers, while the else-case
   does.

Remove IsStdConversionEnabled(), EnableStdConversion(), and the
associated `bStdCS` / `std_cs_` plumbing across CPDF_ColorSpace,
CPDF_BasedCS, CPDF_DeviceCS, CPDF_DIB, CPDF_Image, CPDF_ImageLoader,
CPDF_PageImageCache, CPDF_ImageRenderer, and CPDF_RenderStatus.

Not only does this simplify the code, but it also makes the rendering
more correct. With the code removed, update the bug_557320961 test
expectation.

This CL is AI generated.

Bug: 557320961
Change-Id: I759c4416c963a249533b4ae9c9f4490ebd2d0e25
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/161730
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Andy Phan <andyphan@chromium.org>
Release-gate sync: 14 upstream commits, 5f092b5 to 2b52a82 (the newest
at least a day old). Report: docs/embedpdf/syncs/2026-11-04-2b52a82ab.md.

- Upstream removed the "standard" CMYK conversion for images with soft
  masks or blend modes; our decoded image store no longer keys on it,
  and the image redactor calls the loader without it.
- Images with a Pattern color space fail to load instead of crashing.
- Skia, V8, ICU, zlib and test tool rolls; all our patches still apply.
- No conflicts; no API change.
- Record the layer-mode writer #110 added
  (AcrobatCommentWrittenBackReadsTheSame), which the release gate would
  otherwise reject, and the current counts.
@bobsingor
bobsingor merged commit f1ba46f into embedpdf/main Nov 4, 2026
1 check passed
@bobsingor
bobsingor deleted the embedpdf/sync/2b52a82ab branch November 4, 2026 10:24
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.

4 participants