Skip to content

  • Projects
  • Groups
  • Snippets
  • Help
  • This project
    • Loading...
  • Sign in / Register
S
swiftshader
  • Project
    • Overview
    • Details
    • Activity
    • Cycle Analytics
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Charts
  • Issues 0
    • Issues 0
    • List
    • Board
    • Labels
    • Milestones
  • Merge Requests 0
    • Merge Requests 0
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Charts
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Chen Yisong
  • swiftshader
  • Repository

Switch branch/tag
  • swiftshader
  • src
  • Renderer
  • PixelProcessor.cpp
Find file
BlameHistoryPermalink
  • Nicolas Capens's avatar
    Refactor GLES routine cache keys to use Memset<T> · 92eb0415
    Nicolas Capens authored Aug 20, 2019
    This ports the Vulkan side change to OpenGL ES and silences the GCC 8
    class-memaccess warning/error, while ensuring proper key initialization.
    
    Defines a Memset<T> class to be used as the first base class of cache
    key types, which makes it explicit that their underlying memory will be
    fully initialized before any member constructors are run.
    
    In particular this fixes Blitter::Options state having uninitialized
    bits after the bitfield, and Blitter::State having uninitialized padding
    bytes after Options so 'sourceFormat' is 32-bit aligned.
    
    Also adds is_memcmparable<T> for checking if memcmp() can be used to
    implement operator==() for cache keys. It's equivalent to
    std::is_trivially_copyable except it provides a fallback for STL
    implementations that don't support it.
    
    Also fix class-memset violations in LLVM 7.0 with their solution from
    a later version.
    
    Bug: b/135744933
    Change-Id: Ic1e5c2c6b944a5133fc55840c0508bc2cdd1d66a
    Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/33488
    Presubmit-Ready: Nicolas Capens <nicolascapens@google.com>
    Reviewed-by: 's avatarChris Forbes <chrisforbes@google.com>
    Tested-by: 's avatarNicolas Capens <nicolascapens@google.com>
    92eb0415
PixelProcessor.cpp 33.2 KB
EditWeb IDE
×

Replace PixelProcessor.cpp

Attach a file by drag & drop or click to upload


Cancel
A new branch will be created in your fork and a new merge request will be started.