{-# language CPP #-}
-- No documentation found for Chapter "PipelineCreationFeedbackFlagBits"
module Vulkan.Core13.Enums.PipelineCreationFeedbackFlagBits  ( pattern PIPELINE_CREATION_FEEDBACK_VALID_BIT_EXT
                                                             , pattern PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT_EXT
                                                             , pattern PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT_EXT
                                                             , PipelineCreationFeedbackFlags
                                                             , PipelineCreationFeedbackFlagBits( PIPELINE_CREATION_FEEDBACK_VALID_BIT
                                                                                               , PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT
                                                                                               , PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT
                                                                                               , ..
                                                                                               )
                                                             ) where

import Data.Bits (Bits)
import Data.Bits (FiniteBits)
import Vulkan.Internal.Utils (enumReadPrec)
import Vulkan.Internal.Utils (enumShowsPrec)
import GHC.Show (showString)
import Numeric (showHex)
import Vulkan.Zero (Zero)
import Foreign.Storable (Storable)
import GHC.Read (Read(readPrec))
import GHC.Show (Show(showsPrec))
import Vulkan.Core10.FundamentalTypes (Flags)
-- No documentation found for TopLevel "VK_PIPELINE_CREATION_FEEDBACK_VALID_BIT_EXT"
pattern $bPIPELINE_CREATION_FEEDBACK_VALID_BIT_EXT :: PipelineCreationFeedbackFlagBits
$mPIPELINE_CREATION_FEEDBACK_VALID_BIT_EXT :: forall {r}.
PipelineCreationFeedbackFlagBits
-> ((# #) -> r) -> ((# #) -> r) -> r
PIPELINE_CREATION_FEEDBACK_VALID_BIT_EXT = PIPELINE_CREATION_FEEDBACK_VALID_BIT


-- No documentation found for TopLevel "VK_PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT_EXT"
pattern $bPIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT_EXT :: PipelineCreationFeedbackFlagBits
$mPIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT_EXT :: forall {r}.
PipelineCreationFeedbackFlagBits
-> ((# #) -> r) -> ((# #) -> r) -> r
PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT_EXT = PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT


-- No documentation found for TopLevel "VK_PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT_EXT"
pattern $bPIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT_EXT :: PipelineCreationFeedbackFlagBits
$mPIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT_EXT :: forall {r}.
PipelineCreationFeedbackFlagBits
-> ((# #) -> r) -> ((# #) -> r) -> r
PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT_EXT = PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT


type PipelineCreationFeedbackFlags = PipelineCreationFeedbackFlagBits

-- | VkPipelineCreationFeedbackFlagBits - Bitmask specifying pipeline or
-- pipeline stage creation feedback
--
-- = See Also
--
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_EXT_pipeline_creation_feedback VK_EXT_pipeline_creation_feedback>,
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_VERSION_1_3 VK_VERSION_1_3>,
-- 'Vulkan.Core13.Promoted_From_VK_EXT_pipeline_creation_feedback.PipelineCreationFeedback',
-- 'Vulkan.Core13.Promoted_From_VK_EXT_pipeline_creation_feedback.PipelineCreationFeedbackCreateInfo',
-- 'PipelineCreationFeedbackFlags'
newtype PipelineCreationFeedbackFlagBits = PipelineCreationFeedbackFlagBits Flags
  deriving newtype (PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
$c/= :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
== :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
$c== :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
Eq, Eq PipelineCreationFeedbackFlagBits
PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Ordering
PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
forall a.
Eq a
-> (a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
$cmin :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
max :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
$cmax :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
>= :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
$c>= :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
> :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
$c> :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
<= :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
$c<= :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
< :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
$c< :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Bool
compare :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Ordering
$ccompare :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> Ordering
Ord, Ptr PipelineCreationFeedbackFlagBits
-> IO PipelineCreationFeedbackFlagBits
Ptr PipelineCreationFeedbackFlagBits
-> Int -> IO PipelineCreationFeedbackFlagBits
Ptr PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits -> IO ()
Ptr PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> IO ()
PipelineCreationFeedbackFlagBits -> Int
forall b. Ptr b -> Int -> IO PipelineCreationFeedbackFlagBits
forall b. Ptr b -> Int -> PipelineCreationFeedbackFlagBits -> IO ()
forall a.
(a -> Int)
-> (a -> Int)
-> (Ptr a -> Int -> IO a)
-> (Ptr a -> Int -> a -> IO ())
-> (forall b. Ptr b -> Int -> IO a)
-> (forall b. Ptr b -> Int -> a -> IO ())
-> (Ptr a -> IO a)
-> (Ptr a -> a -> IO ())
-> Storable a
poke :: Ptr PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> IO ()
$cpoke :: Ptr PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits -> IO ()
peek :: Ptr PipelineCreationFeedbackFlagBits
-> IO PipelineCreationFeedbackFlagBits
$cpeek :: Ptr PipelineCreationFeedbackFlagBits
-> IO PipelineCreationFeedbackFlagBits
pokeByteOff :: forall b. Ptr b -> Int -> PipelineCreationFeedbackFlagBits -> IO ()
$cpokeByteOff :: forall b. Ptr b -> Int -> PipelineCreationFeedbackFlagBits -> IO ()
peekByteOff :: forall b. Ptr b -> Int -> IO PipelineCreationFeedbackFlagBits
$cpeekByteOff :: forall b. Ptr b -> Int -> IO PipelineCreationFeedbackFlagBits
pokeElemOff :: Ptr PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits -> IO ()
$cpokeElemOff :: Ptr PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits -> IO ()
peekElemOff :: Ptr PipelineCreationFeedbackFlagBits
-> Int -> IO PipelineCreationFeedbackFlagBits
$cpeekElemOff :: Ptr PipelineCreationFeedbackFlagBits
-> Int -> IO PipelineCreationFeedbackFlagBits
alignment :: PipelineCreationFeedbackFlagBits -> Int
$calignment :: PipelineCreationFeedbackFlagBits -> Int
sizeOf :: PipelineCreationFeedbackFlagBits -> Int
$csizeOf :: PipelineCreationFeedbackFlagBits -> Int
Storable, PipelineCreationFeedbackFlagBits
forall a. a -> Zero a
zero :: PipelineCreationFeedbackFlagBits
$czero :: PipelineCreationFeedbackFlagBits
Zero, Eq PipelineCreationFeedbackFlagBits
PipelineCreationFeedbackFlagBits
Int -> PipelineCreationFeedbackFlagBits
PipelineCreationFeedbackFlagBits -> Bool
PipelineCreationFeedbackFlagBits -> Int
PipelineCreationFeedbackFlagBits -> Maybe Int
PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
PipelineCreationFeedbackFlagBits -> Int -> Bool
PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
forall a.
Eq a
-> (a -> a -> a)
-> (a -> a -> a)
-> (a -> a -> a)
-> (a -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> a
-> (Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> Bool)
-> (a -> Maybe Int)
-> (a -> Int)
-> (a -> Bool)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int)
-> Bits a
popCount :: PipelineCreationFeedbackFlagBits -> Int
$cpopCount :: PipelineCreationFeedbackFlagBits -> Int
rotateR :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$crotateR :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
rotateL :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$crotateL :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
unsafeShiftR :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$cunsafeShiftR :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
shiftR :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$cshiftR :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
unsafeShiftL :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$cunsafeShiftL :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
shiftL :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$cshiftL :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
isSigned :: PipelineCreationFeedbackFlagBits -> Bool
$cisSigned :: PipelineCreationFeedbackFlagBits -> Bool
bitSize :: PipelineCreationFeedbackFlagBits -> Int
$cbitSize :: PipelineCreationFeedbackFlagBits -> Int
bitSizeMaybe :: PipelineCreationFeedbackFlagBits -> Maybe Int
$cbitSizeMaybe :: PipelineCreationFeedbackFlagBits -> Maybe Int
testBit :: PipelineCreationFeedbackFlagBits -> Int -> Bool
$ctestBit :: PipelineCreationFeedbackFlagBits -> Int -> Bool
complementBit :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$ccomplementBit :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
clearBit :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$cclearBit :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
setBit :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$csetBit :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
bit :: Int -> PipelineCreationFeedbackFlagBits
$cbit :: Int -> PipelineCreationFeedbackFlagBits
zeroBits :: PipelineCreationFeedbackFlagBits
$czeroBits :: PipelineCreationFeedbackFlagBits
rotate :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$crotate :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
shift :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
$cshift :: PipelineCreationFeedbackFlagBits
-> Int -> PipelineCreationFeedbackFlagBits
complement :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
$ccomplement :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
xor :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
$cxor :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
.|. :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
$c.|. :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
.&. :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
$c.&. :: PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
-> PipelineCreationFeedbackFlagBits
Bits, Bits PipelineCreationFeedbackFlagBits
PipelineCreationFeedbackFlagBits -> Int
forall b.
Bits b -> (b -> Int) -> (b -> Int) -> (b -> Int) -> FiniteBits b
countTrailingZeros :: PipelineCreationFeedbackFlagBits -> Int
$ccountTrailingZeros :: PipelineCreationFeedbackFlagBits -> Int
countLeadingZeros :: PipelineCreationFeedbackFlagBits -> Int
$ccountLeadingZeros :: PipelineCreationFeedbackFlagBits -> Int
finiteBitSize :: PipelineCreationFeedbackFlagBits -> Int
$cfiniteBitSize :: PipelineCreationFeedbackFlagBits -> Int
FiniteBits)

-- | 'PIPELINE_CREATION_FEEDBACK_VALID_BIT' indicates that the feedback
-- information is valid.
pattern $bPIPELINE_CREATION_FEEDBACK_VALID_BIT :: PipelineCreationFeedbackFlagBits
$mPIPELINE_CREATION_FEEDBACK_VALID_BIT :: forall {r}.
PipelineCreationFeedbackFlagBits
-> ((# #) -> r) -> ((# #) -> r) -> r
PIPELINE_CREATION_FEEDBACK_VALID_BIT = PipelineCreationFeedbackFlagBits 0x00000001

-- | 'PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT'
-- indicates that a readily usable pipeline or pipeline stage was found in
-- the @pipelineCache@ specified by the application in the pipeline
-- creation command.
--
-- An implementation /should/ set the
-- 'PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT' bit if
-- it was able to avoid the large majority of pipeline or pipeline stage
-- creation work by using the @pipelineCache@ parameter of
-- 'Vulkan.Core10.Pipeline.createGraphicsPipelines',
-- 'Vulkan.Extensions.VK_KHR_ray_tracing_pipeline.createRayTracingPipelinesKHR',
-- 'Vulkan.Extensions.VK_NV_ray_tracing.createRayTracingPipelinesNV', or
-- 'Vulkan.Core10.Pipeline.createComputePipelines'. When an implementation
-- sets this bit for the entire pipeline, it /may/ leave it unset for any
-- stage.
--
-- Note
--
-- Implementations are encouraged to provide a meaningful signal to
-- applications using this bit. The intention is to communicate to the
-- application that the pipeline or pipeline stage was created “as fast as
-- it gets” using the pipeline cache provided by the application. If an
-- implementation uses an internal cache, it is discouraged from setting
-- this bit as the feedback would be unactionable.
pattern $bPIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT :: PipelineCreationFeedbackFlagBits
$mPIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT :: forall {r}.
PipelineCreationFeedbackFlagBits
-> ((# #) -> r) -> ((# #) -> r) -> r
PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT = PipelineCreationFeedbackFlagBits 0x00000002

-- | 'PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT' indicates
-- that the base pipeline specified by the @basePipelineHandle@ or
-- @basePipelineIndex@ member of the @Vk*PipelineCreateInfo@ structure was
-- used to accelerate the creation of the pipeline.
--
-- An implementation /should/ set the
-- 'PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT' bit if it
-- was able to avoid a significant amount of work by using the base
-- pipeline.
--
-- Note
--
-- While “significant amount of work” is subjective, implementations are
-- encouraged to provide a meaningful signal to applications using this
-- bit. For example, a 1% reduction in duration may not warrant setting
-- this bit, while a 50% reduction would.
pattern $bPIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT :: PipelineCreationFeedbackFlagBits
$mPIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT :: forall {r}.
PipelineCreationFeedbackFlagBits
-> ((# #) -> r) -> ((# #) -> r) -> r
PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT = PipelineCreationFeedbackFlagBits 0x00000004

conNamePipelineCreationFeedbackFlagBits :: String
conNamePipelineCreationFeedbackFlagBits :: String
conNamePipelineCreationFeedbackFlagBits = String
"PipelineCreationFeedbackFlagBits"

enumPrefixPipelineCreationFeedbackFlagBits :: String
enumPrefixPipelineCreationFeedbackFlagBits :: String
enumPrefixPipelineCreationFeedbackFlagBits = String
"PIPELINE_CREATION_FEEDBACK_"

showTablePipelineCreationFeedbackFlagBits :: [(PipelineCreationFeedbackFlagBits, String)]
showTablePipelineCreationFeedbackFlagBits :: [(PipelineCreationFeedbackFlagBits, String)]
showTablePipelineCreationFeedbackFlagBits =
  [
    ( PipelineCreationFeedbackFlagBits
PIPELINE_CREATION_FEEDBACK_VALID_BIT
    , String
"VALID_BIT"
    )
  ,
    ( PipelineCreationFeedbackFlagBits
PIPELINE_CREATION_FEEDBACK_APPLICATION_PIPELINE_CACHE_HIT_BIT
    , String
"APPLICATION_PIPELINE_CACHE_HIT_BIT"
    )
  ,
    ( PipelineCreationFeedbackFlagBits
PIPELINE_CREATION_FEEDBACK_BASE_PIPELINE_ACCELERATION_BIT
    , String
"BASE_PIPELINE_ACCELERATION_BIT"
    )
  ]

instance Show PipelineCreationFeedbackFlagBits where
  showsPrec :: Int -> PipelineCreationFeedbackFlagBits -> ShowS
showsPrec =
    forall a i.
Eq a =>
String
-> [(a, String)]
-> String
-> (a -> i)
-> (i -> ShowS)
-> Int
-> a
-> ShowS
enumShowsPrec
      String
enumPrefixPipelineCreationFeedbackFlagBits
      [(PipelineCreationFeedbackFlagBits, String)]
showTablePipelineCreationFeedbackFlagBits
      String
conNamePipelineCreationFeedbackFlagBits
      (\(PipelineCreationFeedbackFlagBits Flags
x) -> Flags
x)
      (\Flags
x -> String -> ShowS
showString String
"0x" forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall a. (Integral a, Show a) => a -> ShowS
showHex Flags
x)

instance Read PipelineCreationFeedbackFlagBits where
  readPrec :: ReadPrec PipelineCreationFeedbackFlagBits
readPrec =
    forall i a.
Read i =>
String -> [(a, String)] -> String -> (i -> a) -> ReadPrec a
enumReadPrec
      String
enumPrefixPipelineCreationFeedbackFlagBits
      [(PipelineCreationFeedbackFlagBits, String)]
showTablePipelineCreationFeedbackFlagBits
      String
conNamePipelineCreationFeedbackFlagBits
      Flags -> PipelineCreationFeedbackFlagBits
PipelineCreationFeedbackFlagBits