Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 558c956f7912931a5b81df741b72d4e3961bf406
      
https://github.com/WebKit/WebKit/commit/558c956f7912931a5b81df741b72d4e3961bf406
  Author: Ahmad Saleem <[email protected]>
  Date:   2026-10-06 (Tue, 06 Oct 2026)

  Changed paths:
    M Source/WebCore/dom/DataTransfer.cpp
    M Source/WebCore/dom/DataTransfer.h

  Log Message:
  -----------
  Reduce padding in DataTransfer
https://bugs.webkit.org/show_bug.cgi?id=326538
rdar://189329011

Reviewed by Charlie Wolfe.

Reorder DataTransfer's data members to remove padding holes left by the
4-byte enums, the bool and the IntPoint sitting between 8-byte members.

m_storeMode now fills the 4 bytes left free after the
RefCountedAndCanMakeWeakPtr base (Itanium ABI), and the small members
of the DRAG_SUPPORT block (m_dragLocation, m_type,
m_shouldUpdateDragImage) are grouped after its pointer-sized members.

sizeof(DataTransfer) on 64-bit release builds:
  Apple arm64/x86_64, Linux (Clang/GCC): 120 -> 104 bytes
  Windows x64/ARM64 (MSVC ABI):          120 -> 112 bytes
  32-bit targets:                        unchanged

The destruction order of members with non-trivial destructors is
unchanged; only trivially destructible members moved relative to them.

No behavior change, so no new tests.

* Source/WebCore/dom/DataTransfer.cpp:
(WebCore::DataTransfer::DataTransfer):
* Source/WebCore/dom/DataTransfer.h:

Canonical link: https://commits.webkit.org/322908@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to