1 =================================================
2 Syntax of AMDGPU Assembler Operands and Modifiers
3 =================================================
11 The following conventions are used in syntax description:
13 =================== =============================================================
15 =================== =============================================================
16 {0..N} Any integer value in the range from 0 to N (inclusive).
17 Unless stated otherwise, this value may be specified as
18 either a literal or an llvm expression.
19 <x> Syntax and meaning of *<x>* is explained elsewhere.
20 =================== =============================================================
22 .. _amdgpu_syn_operands:
29 .. _amdgpu_syn_modifiers:
37 .. _amdgpu_synid_ds_offset8:
42 Specifies an immediate unsigned 8-bit offset, in bytes. The default value is 0.
44 Used with DS instructions which have 2 addresses.
46 ======================================== ================================================
48 ======================================== ================================================
49 offset:{0..0xFF} Specifies a 8-bit offset.
50 ======================================== ================================================
52 .. _amdgpu_synid_ds_offset16:
57 Specifies an immediate unsigned 16-bit offset, in bytes. The default value is 0.
59 Used with DS instructions which have 1 address.
61 ======================================== ================================================
63 ======================================== ================================================
64 offset:{0..0xFFFF} Specifies a 16-bit offset.
65 ======================================== ================================================
67 .. _amdgpu_synid_sw_offset16:
72 This is a special modifier which may be used with *ds_swizzle_b32* instruction only.
73 Specifies a sizzle pattern in numeric or symbolic form. The default value is 0.
75 See AMD documentation for more information.
77 ======================================================= ===================================================
79 ======================================================= ===================================================
80 offset:{0..0xFFFF} Specifies a 16-bit swizzle pattern
82 offset:swizzle(QUAD_PERM,{0..3},{0..3},{0..3},{0..3}) Specifies a quad permute mode pattern; each
84 offset:swizzle(BITMASK_PERM, "<mask>") Specifies a bitmask permute mode pattern
85 which converts a 5-bit lane id to another
86 lane id with which the lane interacts.
88 <mask> is a 5 character sequence which
89 specifies how to transform the bits of the
90 lane id. The following characters are allowed:
100 offset:swizzle(BROADCAST,{2..32},{0..N}) Specifies a broadcast mode.
101 Broadcasts the value of any particular lane to
102 all lanes in its group.
104 The first numeric parameter is a group
105 size and must be equal to 2, 4, 8, 16 or 32.
107 The second numeric parameter is an index of the
108 lane being broadcasted. The index must not exceed
110 offset:swizzle(SWAP,{1..16}) Specifies a swap mode.
111 Swaps the neighboring groups of
112 1, 2, 4, 8 or 16 lanes.
113 offset:swizzle(REVERSE,{2..32}) Specifies a reverse mode. Reverses
114 the lanes for groups of 2, 4, 8, 16 or 32 lanes.
115 ======================================================= ===================================================
117 .. _amdgpu_synid_gds:
122 Specifies whether to use GDS or LDS memory (LDS is the default).
124 ======================================== ================================================
126 ======================================== ================================================
128 ======================================== ================================================
134 .. _amdgpu_synid_done:
139 Specifies if this is the last export from the shader to the target. By default, current
140 instruction does not finish an export sequence.
142 ======================================== ================================================
144 ======================================== ================================================
145 done Indicates the last export operation.
146 ======================================== ================================================
148 .. _amdgpu_synid_compr:
153 Indicates if the data are compressed (not compressed by default).
155 ======================================== ================================================
157 ======================================== ================================================
158 compr Data are compressed.
159 ======================================== ================================================
166 Specifies valid mask flag state (off by default).
168 ======================================== ================================================
170 ======================================== ================================================
171 vm Set valid mask flag.
172 ======================================== ================================================
177 .. _amdgpu_synid_flat_offset12:
182 Specifies an immediate unsigned 12-bit offset, in bytes. The default value is 0.
184 Cannot be used with *global/scratch* opcodes. GFX9 only.
186 ======================================== ================================================
188 ======================================== ================================================
189 offset:{0..4095} Specifies a 12-bit unsigned offset.
190 ======================================== ================================================
192 .. _amdgpu_synid_flat_offset13:
197 Specifies an immediate signed 13-bit offset, in bytes. The default value is 0.
199 Can be used with *global/scratch* opcodes only. GFX9 only.
201 ======================================== ================================================
203 ======================================== ================================================
204 offset:{-4096..+4095} Specifies a 13-bit signed offset.
205 ======================================== ================================================
210 See a description :ref:`here<amdgpu_synid_glc>`.
215 See a description :ref:`here<amdgpu_synid_slc>`.
220 See a description :ref:`here<amdgpu_synid_tfe>`.
225 See a description :ref:`here<amdgpu_synid_nv>`.
230 .. _amdgpu_synid_dmask:
235 Specifies which channels (image components) are used by the operation. By default, no channels
238 ======================================== ================================================
240 ======================================== ================================================
241 dmask:{0..15} Each bit corresponds to one of 4 image
242 components (RGBA). If the specified bit value
243 is 0, the component is not used, value 1 means
244 that the component is used.
245 ======================================== ================================================
247 This modifier has some limitations depending on instruction kind:
249 ======================================== ================================================
250 Instruction Kind Valid dmask Values
251 ======================================== ================================================
252 32-bit atomic cmpswap 0x3
253 other 32-bit atomic instructions 0x1
254 64-bit atomic cmpswap 0xF
255 other 64-bit atomic instructions 0x3
256 GATHER4 0x1, 0x2, 0x4, 0x8
257 Other instructions any value
258 ======================================== ================================================
260 .. _amdgpu_synid_unorm:
265 Specifies whether address is normalized or not (normalized by default).
267 ======================================== ================================================
269 ======================================== ================================================
270 unorm Force address to be un-normalized.
271 ======================================== ================================================
276 See a description :ref:`here<amdgpu_synid_glc>`.
281 See a description :ref:`here<amdgpu_synid_slc>`.
283 .. _amdgpu_synid_r128:
288 Specifies texture resource size. The default size is 256 bits.
292 ======================================== ================================================
294 ======================================== ================================================
295 r128 Specifies 128 bits texture resource size.
296 ======================================== ================================================
301 See a description :ref:`here<amdgpu_synid_tfe>`.
303 .. _amdgpu_synid_lwe:
308 Specifies LOD warning status (LOD warning is disabled by default).
310 ======================================== ================================================
312 ======================================== ================================================
313 lwe Enables LOD warning.
314 ======================================== ================================================
321 Specifies if an array index must be sent to TA. By default, array index is not sent.
323 ======================================== ================================================
325 ======================================== ================================================
326 da Send an array-index to TA.
327 ======================================== ================================================
329 .. _amdgpu_synid_d16:
334 Specifies data size: 16 or 32 bits (32 bits by default). Not supported by GFX7.
336 ======================================== ================================================
338 ======================================== ================================================
339 d16 Enables 16-bits data mode.
341 On loads, convert data in memory to 16-bit
342 format before storing it in VGPRs.
344 For stores, convert 16-bit data in VGPRs to
345 32 bits before going to memory.
347 Note that 16-bit data are stored in VGPRs
348 unpacked in GFX8.0. In GFX8.1 and GFX9 16-bit
350 ======================================== ================================================
352 .. _amdgpu_synid_a16:
357 Specifies size of image address components: 16 or 32 bits (32 bits by default). GFX9 only.
359 ======================================== ================================================
361 ======================================== ================================================
362 a16 Enables 16-bits image address components.
363 ======================================== ================================================
365 Miscellaneous Modifiers
366 -----------------------
368 .. _amdgpu_synid_glc:
373 This modifier has different meaning for loads, stores, and atomic operations.
374 The default value is off (0).
376 See AMD documentation for details.
378 ======================================== ================================================
380 ======================================== ================================================
381 glc Set glc bit to 1.
382 ======================================== ================================================
384 .. _amdgpu_synid_slc:
389 Specifies cache policy. The default value is off (0).
391 See AMD documentation for details.
393 ======================================== ================================================
395 ======================================== ================================================
396 slc Set slc bit to 1.
397 ======================================== ================================================
399 .. _amdgpu_synid_tfe:
404 Controls access to partially resident textures. The default value is off (0).
406 See AMD documentation for details.
408 ======================================== ================================================
410 ======================================== ================================================
411 tfe Set tfe bit to 1.
412 ======================================== ================================================
419 Specifies if instruction is operating on non-volatile memory. By default, memory is volatile.
423 ======================================== ================================================
425 ======================================== ================================================
426 nv Indicates that instruction operates on
428 ======================================== ================================================
430 MUBUF/MTBUF Modifiers
431 ---------------------
433 .. _amdgpu_synid_idxen:
438 Specifies whether address components include an index. By default, no components are used.
440 Can be used together with :ref:`offen<amdgpu_synid_offen>`.
442 Cannot be used with :ref:`addr64<amdgpu_synid_addr64>`.
444 ======================================== ================================================
446 ======================================== ================================================
447 idxen Address components include an index.
448 ======================================== ================================================
450 .. _amdgpu_synid_offen:
455 Specifies whether address components include an offset. By default, no components are used.
457 Can be used together with :ref:`idxen<amdgpu_synid_idxen>`.
459 Cannot be used with :ref:`addr64<amdgpu_synid_addr64>`.
461 ======================================== ================================================
463 ======================================== ================================================
464 offen Address components include an offset.
465 ======================================== ================================================
467 .. _amdgpu_synid_addr64:
472 Specifies whether a 64-bit address is used. By default, no address is used.
474 GFX7 only. Cannot be used with :ref:`offen<amdgpu_synid_offen>` and
475 :ref:`idxen<amdgpu_synid_idxen>` modifiers.
477 ======================================== ================================================
479 ======================================== ================================================
480 addr64 A 64-bit address is used.
481 ======================================== ================================================
483 .. _amdgpu_synid_buf_offset12:
488 Specifies an immediate unsigned 12-bit offset, in bytes. The default value is 0.
490 ======================================== ================================================
492 ======================================== ================================================
493 offset:{0..0xFFF} Specifies a 12-bit unsigned offset.
494 ======================================== ================================================
499 See a description :ref:`here<amdgpu_synid_glc>`.
504 See a description :ref:`here<amdgpu_synid_slc>`.
506 .. _amdgpu_synid_lds:
511 Specifies where to store the result: VGPRs or LDS (VGPRs by default).
513 ======================================== ================================================
515 ======================================== ================================================
516 lds Store result in LDS.
517 ======================================== ================================================
522 See a description :ref:`here<amdgpu_synid_tfe>`.
524 .. _amdgpu_synid_dfmt:
531 .. _amdgpu_synid_nfmt:
544 See a description :ref:`here<amdgpu_synid_glc>`.
549 See a description :ref:`here<amdgpu_synid_nv>`.
554 .. _amdgpu_synid_high:
559 Specifies which half of the LDS word to use. Low half of LDS word is used by default.
562 ======================================== ================================================
564 ======================================== ================================================
565 high Use high half of LDS word.
566 ======================================== ================================================
568 VOP1/VOP2 DPP Modifiers
569 -----------------------
573 .. _amdgpu_synid_dpp_ctrl:
578 Specifies how data are shared between threads. This is a mandatory modifier.
579 There is no default value.
581 Note. The lanes of a wavefront are organized in four banks and four rows.
583 ======================================== ================================================
585 ======================================== ================================================
586 quad_perm:[{0..3},{0..3},{0..3},{0..3}] Full permute of 4 threads.
587 row_mirror Mirror threads within row.
588 row_half_mirror Mirror threads within 1/2 row (8 threads).
589 row_bcast:15 Broadcast 15th thread of each row to next row.
590 row_bcast:31 Broadcast thread 31 to rows 2 and 3.
591 wave_shl:1 Wavefront left shift by 1 thread.
592 wave_rol:1 Wavefront left rotate by 1 thread.
593 wave_shr:1 Wavefront right shift by 1 thread.
594 wave_ror:1 Wavefront right rotate by 1 thread.
595 row_shl:{1..15} Row shift left by 1-15 threads.
596 row_shr:{1..15} Row shift right by 1-15 threads.
597 row_ror:{1..15} Row rotate right by 1-15 threads.
598 ======================================== ================================================
600 .. _amdgpu_synid_row_mask:
605 Controls which rows are enabled for data sharing. By default, all rows are enabled.
607 Note. The lanes of a wavefront are organized in four banks and four rows.
609 ======================================== ================================================
611 ======================================== ================================================
612 row_mask:{0..15} Each of 4 bits in the mask controls one
613 row (0 - disabled, 1 - enabled).
614 ======================================== ================================================
616 .. _amdgpu_synid_bank_mask:
621 Controls which banks are enabled for data sharing. By default, all banks are enabled.
623 Note. The lanes of a wavefront are organized in four banks and four rows.
625 ======================================== ================================================
627 ======================================== ================================================
628 bank_mask:{0..15} Each of 4 bits in the mask controls one
629 bank (0 - disabled, 1 - enabled).
630 ======================================== ================================================
632 .. _amdgpu_synid_bound_ctrl:
637 Controls data sharing when accessing an invalid lane. By default, data sharing with
638 invalid lanes is disabled.
640 ======================================== ================================================
642 ======================================== ================================================
643 bound_ctrl:0 Enables data sharing with invalid lanes.
644 Accessing data from an invalid lane will
646 ======================================== ================================================
648 VOP1/VOP2/VOPC SDWA Modifiers
649 -----------------------------
656 See a description :ref:`here<amdgpu_synid_clamp>`.
661 See a description :ref:`here<amdgpu_synid_omod>`.
665 .. _amdgpu_synid_dst_sel:
670 Selects which bits in the destination are affected. By default, all bits are affected.
672 ======================================== ================================================
674 ======================================== ================================================
675 dst_sel:DWORD Use bits 31:0.
676 dst_sel:BYTE_0 Use bits 7:0.
677 dst_sel:BYTE_1 Use bits 15:8.
678 dst_sel:BYTE_2 Use bits 23:16.
679 dst_sel:BYTE_3 Use bits 31:24.
680 dst_sel:WORD_0 Use bits 15:0.
681 dst_sel:WORD_1 Use bits 31:16.
682 ======================================== ================================================
685 .. _amdgpu_synid_dst_unused:
690 Controls what to do with the bits in the destination which are not selected
691 by :ref:`dst_sel<amdgpu_synid_dst_sel>`.
692 By default, unused bits are preserved.
694 ======================================== ================================================
696 ======================================== ================================================
697 dst_unused:UNUSED_PAD Pad with zeros.
698 dst_unused:UNUSED_SEXT Sign-extend upper bits, zero lower bits.
699 dst_unused:UNUSED_PRESERVE Preserve bits.
700 ======================================== ================================================
702 .. _amdgpu_synid_src0_sel:
707 Controls which bits in the src0 are used. By default, all bits are used.
709 ======================================== ================================================
711 ======================================== ================================================
712 src0_sel:DWORD Use bits 31:0.
713 src0_sel:BYTE_0 Use bits 7:0.
714 src0_sel:BYTE_1 Use bits 15:8.
715 src0_sel:BYTE_2 Use bits 23:16.
716 src0_sel:BYTE_3 Use bits 31:24.
717 src0_sel:WORD_0 Use bits 15:0.
718 src0_sel:WORD_1 Use bits 31:16.
719 ======================================== ================================================
721 .. _amdgpu_synid_src1_sel:
726 Controls which bits in the src1 are used. By default, all bits are used.
728 ======================================== ================================================
730 ======================================== ================================================
731 src1_sel:DWORD Use bits 31:0.
732 src1_sel:BYTE_0 Use bits 7:0.
733 src1_sel:BYTE_1 Use bits 15:8.
734 src1_sel:BYTE_2 Use bits 23:16.
735 src1_sel:BYTE_3 Use bits 31:24.
736 src1_sel:WORD_0 Use bits 15:0.
737 src1_sel:WORD_1 Use bits 31:16.
738 ======================================== ================================================
740 VOP1/VOP2/VOPC SDWA Operand Modifiers
741 -------------------------------------
743 Operand modifiers are not used separately. They are applied to source operands.
750 See a description :ref:`here<amdgpu_synid_abs>`.
755 See a description :ref:`here<amdgpu_synid_neg>`.
757 .. _amdgpu_synid_sext:
762 Sign-extends value of a (sub-dword) operand to fill all 32 bits.
763 Has no effect for 32-bit operands.
765 Valid for integer operands only.
767 ======================================== ================================================
769 ======================================== ================================================
770 sext(<operand>) Sign-extend operand value.
771 ======================================== ================================================
776 .. _amdgpu_synid_vop3_op_sel:
781 Selects the low [15:0] or high [31:16] operand bits for source and destination operands.
782 By default, low bits are used for all operands.
784 The number of values specified with the op_sel modifier must match the number of instruction
785 operands (both source and destination). First value controls src0, second value controls src1
786 and so on, except that the last value controls destination.
787 The value 0 selects the low bits, while 1 selects the high bits.
789 Note. op_sel modifier affects 16-bit operands only. For 32-bit operands the value specified
794 ======================================== ============================================================
796 ======================================== ============================================================
797 op_sel:[{0..1},{0..1}] Select operand bits for instructions with 1 source operand.
798 op_sel:[{0..1},{0..1},{0..1}] Select operand bits for instructions with 2 source operands.
799 op_sel:[{0..1},{0..1},{0..1},{0..1}] Select operand bits for instructions with 3 source operands.
800 ======================================== ============================================================
802 .. _amdgpu_synid_clamp:
807 Clamp meaning depends on instruction.
809 For *v_cmp* instructions, clamp modifier indicates that the compare signals
810 if a floating point exception occurs. By default, signaling is disabled.
811 Not supported by GFX7.
813 For integer operations, clamp modifier indicates that the result must be clamped
814 to the largest and smallest representable value. By default, there is no clamping.
815 Integer clamping is not supported by GFX7.
817 For floating point operations, clamp modifier indicates that the result must be clamped
818 to the range [0.0, 1.0]. By default, there is no clamping.
820 Note. Clamp modifier is applied after :ref:`output modifiers<amdgpu_synid_omod>` (if any).
822 ======================================== ================================================
824 ======================================== ================================================
825 clamp Enables clamping (or signaling).
826 ======================================== ================================================
828 .. _amdgpu_synid_omod:
833 Specifies if an output modifier must be applied to the result.
834 By default, no output modifiers are applied.
836 Note. Output modifiers are applied before :ref:`clamping<amdgpu_synid_clamp>` (if any).
838 Output modifiers are valid for f32 and f64 floating point results only.
839 They must not be used with f16.
841 Note. *v_cvt_f16_f32* is an exception. This instruction produces f16 result
842 but accepts output modifiers.
844 ======================================== ================================================
846 ======================================== ================================================
847 mul:2 Multiply the result by 2.
848 mul:4 Multiply the result by 4.
849 div:2 Multiply the result by 0.5.
850 ======================================== ================================================
852 VOP3 Operand Modifiers
853 ----------------------
855 Operand modifiers are not used separately. They are applied to source operands.
857 .. _amdgpu_synid_abs:
862 Computes absolute value of its operand. Applied before :ref:`neg<amdgpu_synid_neg>` (if any).
863 Valid for floating point operands only.
865 ======================================== ================================================
867 ======================================== ================================================
868 abs(<operand>) Get absolute value of operand.
869 \|<operand>| The same as above.
870 ======================================== ================================================
872 .. _amdgpu_synid_neg:
877 Computes negative value of its operand. Applied after :ref:`abs<amdgpu_synid_abs>` (if any).
878 Valid for floating point operands only.
880 ======================================== ================================================
882 ======================================== ================================================
883 neg(<operand>) Get negative value of operand.
884 -<operand> The same as above.
885 ======================================== ================================================
890 This section describes modifiers of regular VOP3P instructions.
891 *v_mad_mix* modifiers are described :ref:`in a separate section<amdgpu_synid_mad_mix>`.
895 .. _amdgpu_synid_op_sel:
900 Selects the low [15:0] or high [31:16] operand bits as input to the operation
901 which results in the lower-half of the destination.
902 By default, low bits are used for all operands.
904 The number of values specified with the op_sel modifier must match the number of source
905 operands. First value controls src0, second value controls src1 and so on.
906 The value 0 selects the low bits, while 1 selects the high bits.
908 ======================================== =============================================================
910 ======================================== =============================================================
911 op_sel:[{0..1}] Select operand bits for instructions with 1 source operand.
912 op_sel:[{0..1},{0..1}] Select operand bits for instructions with 2 source operands.
913 op_sel:[{0..1},{0..1},{0..1}] Select operand bits for instructions with 3 source operands.
914 ======================================== =============================================================
916 .. _amdgpu_synid_op_sel_hi:
921 Selects the low [15:0] or high [31:16] operand bits as input to the operation
922 which results in the upper-half of the destination.
923 By default, high bits are used for all operands.
925 The number of values specified with the op_sel_hi modifier must match the number of source
926 operands. First value controls src0, second value controls src1 and so on.
927 The value 0 selects the low bits, while 1 selects the high bits.
929 ======================================== =============================================================
931 ======================================== =============================================================
932 op_sel_hi:[{0..1}] Select operand bits for instructions with 1 source operand.
933 op_sel_hi:[{0..1},{0..1}] Select operand bits for instructions with 2 source operands.
934 op_sel_hi:[{0..1},{0..1},{0..1}] Select operand bits for instructions with 3 source operands.
935 ======================================== =============================================================
937 .. _amdgpu_synid_neg_lo:
942 Specifies whether to change sign of operand values selected by
943 :ref:`op_sel<amdgpu_synid_op_sel>`. These values are then used
944 as input to the operation which results in the upper-half of the destination.
946 The number of values specified with this modifier must match the number of source
947 operands. First value controls src0, second value controls src1 and so on.
949 The value 0 indicates that the corresponding operand value is used unmodified,
950 the value 1 indicates that negative value of the operand must be used.
952 By default, operand values are used unmodified.
954 This modifier is valid for floating point operands only.
956 ======================================== ==================================================================
958 ======================================== ==================================================================
959 neg_lo:[{0..1}] Select affected operands for instructions with 1 source operand.
960 neg_lo:[{0..1},{0..1}] Select affected operands for instructions with 2 source operands.
961 neg_lo:[{0..1},{0..1},{0..1}] Select affected operands for instructions with 3 source operands.
962 ======================================== ==================================================================
964 .. _amdgpu_synid_neg_hi:
969 Specifies whether to change sign of operand values selected by
970 :ref:`op_sel_hi<amdgpu_synid_op_sel_hi>`. These values are then used
971 as input to the operation which results in the upper-half of the destination.
973 The number of values specified with this modifier must match the number of source
974 operands. First value controls src0, second value controls src1 and so on.
976 The value 0 indicates that the corresponding operand value is used unmodified,
977 the value 1 indicates that negative value of the operand must be used.
979 By default, operand values are used unmodified.
981 This modifier is valid for floating point operands only.
983 ======================================== ==================================================================
985 ======================================== ==================================================================
986 neg_hi:[{0..1}] Select affected operands for instructions with 1 source operand.
987 neg_hi:[{0..1},{0..1}] Select affected operands for instructions with 2 source operands.
988 neg_hi:[{0..1},{0..1},{0..1}] Select affected operands for instructions with 3 source operands.
989 ======================================== ==================================================================
994 See a description :ref:`here<amdgpu_synid_clamp>`.
996 .. _amdgpu_synid_mad_mix:
998 VOP3P V_MAD_MIX Modifiers
999 -------------------------
1001 These instructions use VOP3P format but have different modifiers.
1005 .. _amdgpu_synid_mad_mix_op_sel:
1010 This operand has meaning only for 16-bit source operands as indicated by
1011 :ref:`mad_mix_op_sel_hi<amdgpu_synid_mad_mix_op_sel_hi>`.
1012 It specifies to select either the low [15:0] or high [31:16] operand bits
1013 as input to the operation.
1015 The value 0 indicates the low bits, the value 1 indicates the high 16 bits.
1016 By default, low bits are used for all operands.
1018 ======================================== ================================================
1020 ======================================== ================================================
1021 op_sel:[{0..1},{0..1},{0..1}] Select location of each 16-bit source operand.
1022 ======================================== ================================================
1024 .. _amdgpu_synid_mad_mix_op_sel_hi:
1029 Selects the size of source operands: either 32 bits or 16 bits.
1030 By default, 32 bits are used for all source operands.
1032 The value 0 indicates 32 bits, the value 1 indicates 16 bits.
1033 The location of 16 bits in the operand may be specified by
1034 :ref:`mad_mix_op_sel<amdgpu_synid_mad_mix_op_sel>`.
1036 ======================================== ================================================
1038 ======================================== ================================================
1039 op_sel_hi:[{0..1},{0..1},{0..1}] Select size of each source operand.
1040 ======================================== ================================================
1045 See a description :ref:`here<amdgpu_synid_abs>`.
1050 See a description :ref:`here<amdgpu_synid_neg>`.
1055 See a description :ref:`here<amdgpu_synid_clamp>`.