Source/Packages

Realization.Nvidia.SM86.StreamingAttentionSM86

packages/realizations/cooperative/nvidia-sm86/src/Realization/Nvidia/SM86/StreamingAttentionSM86.alpha

3,230 lines493 declarations193.3 KiBSHA-256 cc0366b3d857

def · lines 375–385

saLoopTail

Full file
---- the loop's tail: the next key tile, one fewer left ----
375def saLoopTail = (lambda unrestricted seq : Nat . (lambda unrestricted bodyInstructions : Nat .
376  (saAddImm saKeyOffset saKeyOffset (naturalMultiply saTile (naturalMultiply saHeadWidth saHalfBytes))
377  (saAddImm saValueOffset saValueOffset (naturalMultiply saTile saHalfBytes)
378  (saAddImm saCount saCount 4294967295
379  (saGreater saP1 saCount 0
380  (saWhen saP1
381    (constructor SM86InstructionBody SM86Branch
382      (saU (naturalSaturatingSubtract 4294967296 (naturalMultiply 16 (naturalAdd bodyInstructions 5))))
383      (sm86Unsigned32 (byte 255) (byte 255) (byte 131) (byte 3))
384      saPlain)
385    sm86ProgramEmpty)))))))

The compiler supplied declaration spans and resolved links from this source snapshot. This page does not assert that this file belongs to a checked closure.