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
  • Vulkan
  • VkPhysicalDevice.hpp
Find file
BlameHistoryPermalink
  • Nicolas Capens's avatar
    Implement timestamp query support · 3c4fd15f
    Nicolas Capens authored Mar 10, 2021
    This change set VkQueueFamilyProperties::timestampValidBits to non-zero
    (64) to indicate support for timestamps.
    
    It also enables the timestampComputeAndGraphics feature to indicate that
    all graphics and compute queues (we only have a single one at the
    moment) support timestamp queries. Note that applications often check
    this aggregate flag instead of the individual queue family properties.
    
    timestampPeriod was lowered from 60 to 1, since we're writing timestamps
    with nanosecond granularity. Actually obtaining the time was already in
    place, see QueryPool::writeTimestamp(), but it didn't put the query in
    the 'available' state.
    
    The clock was replaced with std::chrono::steady_clock, which typically
    provides higher resolution than system_clock [1]. While it doesn't offer
    wall clock related time, this is not a requirement of Vulkan timestamps.
    
    Query::INVALID_TYPE was eliminated. Queries belong to a query pool which
    takes a valid type at construction. This also allowed to eliminate
    Query::prepare().
    
    [1] https://www.modernescpp.com/index.php/the-three-clocks
    
    Bug: b/142643809
    Tests: dEQP-VK.pipeline.timestamp.*
    Change-Id: Icb7c8c5ed78052eba9df630a4c1cb450bda7f85b
    Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/53488
    Presubmit-Ready: Nicolas Capens <nicolascapens@google.com>
    Kokoro-Result: kokoro <noreply+kokoro@google.com>
    Tested-by: 's avatarNicolas Capens <nicolascapens@google.com>
    Reviewed-by: 's avatarAlexis Hétu <sugoi@google.com>
    3c4fd15f
VkPhysicalDevice.hpp 4.87 KB
EditWeb IDE
×

Replace VkPhysicalDevice.hpp

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.