{-# language CPP #-}
-- | = Name
--
-- VK_EXT_shader_atomic_float - device extension
--
-- == VK_EXT_shader_atomic_float
--
-- [__Name String__]
--     @VK_EXT_shader_atomic_float@
--
-- [__Extension Type__]
--     Device extension
--
-- [__Registered Extension Number__]
--     261
--
-- [__Revision__]
--     1
--
-- [__Extension and Version Dependencies__]
--
--     -   Requires Vulkan 1.0
--
--     -   Requires @VK_KHR_get_physical_device_properties2@
--
-- [__Contact__]
--
--     -   Vikram Kushwaha
--         <https://github.com/KhronosGroup/Vulkan-Docs/issues/new?title=VK_EXT_shader_atomic_float:%20&body=@vkushwaha-nv%20 >
--
-- == Other Extension Metadata
--
-- [__Last Modified Date__]
--     2020-07-15
--
-- [__IP Status__]
--     No known IP claims.
--
-- [__Interactions and External Dependencies__]
--
--     -   This extension requires
--         <https://htmlpreview.github.io/?https://github.com/KhronosGroup/SPIRV-Registry/blob/master/extensions/EXT/SPV_EXT_shader_atomic_float_add.html SPV_EXT_shader_atomic_float_add>
--
--     -   This extension provides API support for
--         <https://github.com/KhronosGroup/GLSL/tree/master/extensions/ext/GLSL_EXT_shader_atomic_float.txt GL_EXT_shader_atomic_float>
--
-- [__Contributors__]
--
--     -   Vikram Kushwaha, NVIDIA
--
--     -   Jeff Bolz, NVIDIA
--
-- == Description
--
-- This extension allows a shader to contain floating-point atomic
-- operations on buffer, workgroup, and image memory. It also advertises
-- the SPIR-V @AtomicFloat32AddEXT@ and @AtomicFloat64AddEXT@ capabilities
-- that allows atomic addition on floating-points numbers. The supported
-- operations include @OpAtomicFAddEXT@, @OpAtomicExchange@, @OpAtomicLoad@
-- and @OpAtomicStore@.
--
-- == New Structures
--
-- -   Extending
--     'Vulkan.Core11.Promoted_From_VK_KHR_get_physical_device_properties2.PhysicalDeviceFeatures2',
--     'Vulkan.Core10.Device.DeviceCreateInfo':
--
--     -   'PhysicalDeviceShaderAtomicFloatFeaturesEXT'
--
-- == New Enum Constants
--
-- -   'EXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME'
--
-- -   'EXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION'
--
-- -   Extending 'Vulkan.Core10.Enums.StructureType.StructureType':
--
--     -   'Vulkan.Core10.Enums.StructureType.STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_ATOMIC_FLOAT_FEATURES_EXT'
--
-- == New SPIR-V Capabilities
--
-- -   <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#spirvenv-capabilities-table-AtomicFloat32AddEXT AtomicFloat32AddEXT>
--
-- -   <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#spirvenv-capabilities-table-AtomicFloat64AddEXT AtomicFloat64AddEXT>
--
-- == Version History
--
-- -   Revision 1, 2020-07-15 (Vikram Kushwaha)
--
--     -   Internal revisions
--
-- = See Also
--
-- 'PhysicalDeviceShaderAtomicFloatFeaturesEXT'
--
-- = Document Notes
--
-- For more information, see the
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_EXT_shader_atomic_float Vulkan Specification>
--
-- This page is a generated document. Fixes and changes should be made to
-- the generator scripts, not directly.
module Vulkan.Extensions.VK_EXT_shader_atomic_float  ( PhysicalDeviceShaderAtomicFloatFeaturesEXT(..)
                                                     , EXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION
                                                     , pattern EXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION
                                                     , EXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME
                                                     , pattern EXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME
                                                     ) where

import Foreign.Marshal.Alloc (allocaBytesAligned)
import Foreign.Ptr (nullPtr)
import Foreign.Ptr (plusPtr)
import Data.String (IsString)
import Data.Typeable (Typeable)
import Foreign.Storable (Storable)
import Foreign.Storable (Storable(peek))
import Foreign.Storable (Storable(poke))
import qualified Foreign.Storable (Storable(..))
import GHC.Generics (Generic)
import Foreign.Ptr (Ptr)
import Data.Kind (Type)
import Vulkan.Core10.FundamentalTypes (bool32ToBool)
import Vulkan.Core10.FundamentalTypes (boolToBool32)
import Vulkan.Core10.FundamentalTypes (Bool32)
import Vulkan.CStruct (FromCStruct)
import Vulkan.CStruct (FromCStruct(..))
import Vulkan.Core10.Enums.StructureType (StructureType)
import Vulkan.CStruct (ToCStruct)
import Vulkan.CStruct (ToCStruct(..))
import Vulkan.Zero (Zero(..))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_ATOMIC_FLOAT_FEATURES_EXT))
-- | VkPhysicalDeviceShaderAtomicFloatFeaturesEXT - Structure describing
-- features supported by VK_EXT_shader_atomic_float
--
-- == Valid Usage (Implicit)
--
-- = See Also
--
-- 'Vulkan.Core10.FundamentalTypes.Bool32',
-- 'Vulkan.Core10.Enums.StructureType.StructureType'
data PhysicalDeviceShaderAtomicFloatFeaturesEXT = PhysicalDeviceShaderAtomicFloatFeaturesEXT
  { -- | #features-shaderBufferFloat32Atomics# @shaderBufferFloat32Atomics@
    -- indicates whether shaders /can/ perform 32-bit floating-point load,
    -- store and exchange atomic operations on storage buffers.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderBufferFloat32Atomics :: Bool
  , -- | #features-shaderBufferFloat32AtomicAdd# @shaderBufferFloat32AtomicAdd@
    -- indicates whether shaders /can/ perform 32-bit floating-point add atomic
    -- operations on storage buffers.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderBufferFloat32AtomicAdd :: Bool
  , -- | #features-shaderBufferFloat64Atomics# @shaderBufferFloat64Atomics@
    -- indicates whether shaders /can/ perform 64-bit floating-point load,
    -- store and exchange atomic operations on storage buffers.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderBufferFloat64Atomics :: Bool
  , -- | #features-shaderBufferFloat64AtomicAdd# @shaderBufferFloat64AtomicAdd@
    -- indicates whether shaders /can/ perform 64-bit floating-point add atomic
    -- operations on storage buffers.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderBufferFloat64AtomicAdd :: Bool
  , -- | #features-shaderSharedFloat32Atomics# @shaderSharedFloat32Atomics@
    -- indicates whether shaders /can/ perform 32-bit floating-point load,
    -- store and exchange atomic operations on shared memory.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderSharedFloat32Atomics :: Bool
  , -- | #features-shaderSharedFloat32AtomicAdd# @shaderSharedFloat32AtomicAdd@
    -- indicates whether shaders /can/ perform 32-bit floating-point add atomic
    -- operations on shared memory.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderSharedFloat32AtomicAdd :: Bool
  , -- | #features-shaderSharedFloat64Atomics# @shaderSharedFloat64Atomics@
    -- indicates whether shaders /can/ perform 64-bit floating-point load,
    -- store and exchange atomic operations on shared memory.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderSharedFloat64Atomics :: Bool
  , -- | #features-shaderSharedFloat64AtomicAdd# @shaderSharedFloat64AtomicAdd@
    -- indicates whether shaders /can/ perform 64-bit floating-point add atomic
    -- operations on shared memory.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderSharedFloat64AtomicAdd :: Bool
  , -- | #features-shaderImageFloat32Atomics# @shaderImageFloat32Atomics@
    -- indicates whether shaders /can/ perform 32-bit floating-point load,
    -- store and exchange atomic image operations.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderImageFloat32Atomics :: Bool
  , -- | #features-shaderImageFloat32AtomicAdd# @shaderImageFloat32AtomicAdd@
    -- indicates whether shaders /can/ perform 32-bit floating-point add atomic
    -- image operations.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
shaderImageFloat32AtomicAdd :: Bool
  , -- | #features-sparseImageFloat32Atomics# @sparseImageFloat32Atomics@
    -- indicates whether 32-bit floating-point load, store and exchange atomic
    -- operations /can/ be used on sparse images.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
sparseImageFloat32Atomics :: Bool
  , -- | #features-sparseImageFloat32AtomicAdd# @sparseImageFloat32AtomicAdd@
    -- indicates whether 32-bit floating-point add atomic operations /can/ be
    -- used on sparse images.
    PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
sparseImageFloat32AtomicAdd :: Bool
  }
  deriving (Typeable, PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
(PhysicalDeviceShaderAtomicFloatFeaturesEXT
 -> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool)
-> (PhysicalDeviceShaderAtomicFloatFeaturesEXT
    -> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool)
-> Eq PhysicalDeviceShaderAtomicFloatFeaturesEXT
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
$c/= :: PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
== :: PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
$c== :: PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Bool
Eq)
#if defined(GENERIC_INSTANCES)
deriving instance Generic (PhysicalDeviceShaderAtomicFloatFeaturesEXT)
#endif
deriving instance Show PhysicalDeviceShaderAtomicFloatFeaturesEXT

instance ToCStruct PhysicalDeviceShaderAtomicFloatFeaturesEXT where
  withCStruct :: PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> (Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b) -> IO b
withCStruct x :: PhysicalDeviceShaderAtomicFloatFeaturesEXT
x f :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b
f = Int
-> Int
-> (Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 64 8 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b) -> IO b)
-> (Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p -> Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p PhysicalDeviceShaderAtomicFloatFeaturesEXT
x (Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b
f Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p)
  pokeCStruct :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b -> IO b
pokeCStruct p :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p PhysicalDeviceShaderAtomicFloatFeaturesEXT{..} f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_ATOMIC_FLOAT_FEATURES_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderBufferFloat32Atomics))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderBufferFloat32AtomicAdd))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderBufferFloat64Atomics))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderBufferFloat64AtomicAdd))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderSharedFloat32Atomics))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 36 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderSharedFloat32AtomicAdd))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderSharedFloat64Atomics))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 44 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderSharedFloat64AtomicAdd))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderImageFloat32Atomics))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 52 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
shaderImageFloat32AtomicAdd))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
sparseImageFloat32Atomics))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 60 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
sparseImageFloat32AtomicAdd))
    IO b
f
  cStructSize :: Int
cStructSize = 64
  cStructAlignment :: Int
cStructAlignment = 8
  pokeZeroCStruct :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO b -> IO b
pokeZeroCStruct p :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_ATOMIC_FLOAT_FEATURES_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 36 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 44 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 52 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 60 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    IO b
f

instance FromCStruct PhysicalDeviceShaderAtomicFloatFeaturesEXT where
  peekCStruct :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> IO PhysicalDeviceShaderAtomicFloatFeaturesEXT
peekCStruct p :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p = do
    Bool32
shaderBufferFloat32Atomics <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32))
    Bool32
shaderBufferFloat32AtomicAdd <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Bool32))
    Bool32
shaderBufferFloat64Atomics <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Bool32))
    Bool32
shaderBufferFloat64AtomicAdd <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Bool32))
    Bool32
shaderSharedFloat32Atomics <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Bool32))
    Bool32
shaderSharedFloat32AtomicAdd <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 36 :: Ptr Bool32))
    Bool32
shaderSharedFloat64Atomics <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Bool32))
    Bool32
shaderSharedFloat64AtomicAdd <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 44 :: Ptr Bool32))
    Bool32
shaderImageFloat32Atomics <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr Bool32))
    Bool32
shaderImageFloat32AtomicAdd <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 52 :: Ptr Bool32))
    Bool32
sparseImageFloat32Atomics <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Bool32))
    Bool32
sparseImageFloat32AtomicAdd <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
p Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 60 :: Ptr Bool32))
    PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> IO PhysicalDeviceShaderAtomicFloatFeaturesEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure (PhysicalDeviceShaderAtomicFloatFeaturesEXT
 -> IO PhysicalDeviceShaderAtomicFloatFeaturesEXT)
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> IO PhysicalDeviceShaderAtomicFloatFeaturesEXT
forall a b. (a -> b) -> a -> b
$ Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT
PhysicalDeviceShaderAtomicFloatFeaturesEXT
             (Bool32 -> Bool
bool32ToBool Bool32
shaderBufferFloat32Atomics) (Bool32 -> Bool
bool32ToBool Bool32
shaderBufferFloat32AtomicAdd) (Bool32 -> Bool
bool32ToBool Bool32
shaderBufferFloat64Atomics) (Bool32 -> Bool
bool32ToBool Bool32
shaderBufferFloat64AtomicAdd) (Bool32 -> Bool
bool32ToBool Bool32
shaderSharedFloat32Atomics) (Bool32 -> Bool
bool32ToBool Bool32
shaderSharedFloat32AtomicAdd) (Bool32 -> Bool
bool32ToBool Bool32
shaderSharedFloat64Atomics) (Bool32 -> Bool
bool32ToBool Bool32
shaderSharedFloat64AtomicAdd) (Bool32 -> Bool
bool32ToBool Bool32
shaderImageFloat32Atomics) (Bool32 -> Bool
bool32ToBool Bool32
shaderImageFloat32AtomicAdd) (Bool32 -> Bool
bool32ToBool Bool32
sparseImageFloat32Atomics) (Bool32 -> Bool
bool32ToBool Bool32
sparseImageFloat32AtomicAdd)

instance Storable PhysicalDeviceShaderAtomicFloatFeaturesEXT where
  sizeOf :: PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int
sizeOf ~PhysicalDeviceShaderAtomicFloatFeaturesEXT
_ = 64
  alignment :: PhysicalDeviceShaderAtomicFloatFeaturesEXT -> Int
alignment ~PhysicalDeviceShaderAtomicFloatFeaturesEXT
_ = 8
  peek :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> IO PhysicalDeviceShaderAtomicFloatFeaturesEXT
peek = Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> IO PhysicalDeviceShaderAtomicFloatFeaturesEXT
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
  poke :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO ()
poke ptr :: Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
ptr poked :: PhysicalDeviceShaderAtomicFloatFeaturesEXT
poked = Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT -> IO () -> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
ptr PhysicalDeviceShaderAtomicFloatFeaturesEXT
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())

instance Zero PhysicalDeviceShaderAtomicFloatFeaturesEXT where
  zero :: PhysicalDeviceShaderAtomicFloatFeaturesEXT
zero = Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> PhysicalDeviceShaderAtomicFloatFeaturesEXT
PhysicalDeviceShaderAtomicFloatFeaturesEXT
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero


type EXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION = 1

-- No documentation found for TopLevel "VK_EXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION"
pattern EXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION :: forall a . Integral a => a
pattern $bEXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION :: a
$mEXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION :: forall r a. Integral a => a -> (Void# -> r) -> (Void# -> r) -> r
EXT_SHADER_ATOMIC_FLOAT_SPEC_VERSION = 1


type EXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME = "VK_EXT_shader_atomic_float"

-- No documentation found for TopLevel "VK_EXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME"
pattern EXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME :: forall a . (Eq a, IsString a) => a
pattern $bEXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME :: a
$mEXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME :: forall r a.
(Eq a, IsString a) =>
a -> (Void# -> r) -> (Void# -> r) -> r
EXT_SHADER_ATOMIC_FLOAT_EXTENSION_NAME = "VK_EXT_shader_atomic_float"