1#![allow(unused)]
70
71use crate::lexer::PtxToken;
72use crate::unparser::{PtxUnparser, common::*};
73
74pub mod section_0 {
75 use super::*;
76 use crate::r#type::instruction::wmma_load::section_0::*;
77
78 impl PtxUnparser for WmmaLoadASyncAlignedLayoutShapeSsAtype {
79 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
80 self.unparse_tokens_mode(tokens, false);
81 }
82 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
83 push_opcode(tokens, "wmma");
84 push_directive(tokens, "load");
85 push_directive(tokens, "a");
86 push_directive(tokens, "sync");
87 push_directive(tokens, "aligned");
88 match &self.layout {
89 Layout::Row => {
90 push_directive(tokens, "row");
91 }
92 Layout::Col => {
93 push_directive(tokens, "col");
94 }
95 }
96 match &self.shape {
97 Shape::M16n16k16 => {
98 push_directive(tokens, "m16n16k16");
99 }
100 Shape::M8n32k16 => {
101 push_directive(tokens, "m8n32k16");
102 }
103 Shape::M32n8k16 => {
104 push_directive(tokens, "m32n8k16");
105 }
106 }
107 if let Some(ss_0) = self.ss.as_ref() {
108 match ss_0 {
109 Ss::SharedCta => {
110 push_directive(tokens, "shared::cta");
111 }
112 Ss::Global => {
113 push_directive(tokens, "global");
114 }
115 Ss::Shared => {
116 push_directive(tokens, "shared");
117 }
118 }
119 }
120 match &self.atype {
121 Atype::F16 => {
122 push_directive(tokens, "f16");
123 }
124 Atype::S8 => {
125 push_directive(tokens, "s8");
126 }
127 Atype::U8 => {
128 push_directive(tokens, "u8");
129 }
130 }
131 if spaced {
132 tokens.push(PtxToken::Space);
133 }
134 self.r.unparse_tokens_mode(tokens, spaced);
135 tokens.push(PtxToken::Comma);
136 if spaced {
137 tokens.push(PtxToken::Space);
138 }
139 self.p.unparse_tokens_mode(tokens, spaced);
140 if self.stride.is_some() {
141 tokens.push(PtxToken::Comma);
142 }
143 if let Some(opt_1) = self.stride.as_ref() {
144 if spaced {
145 tokens.push(PtxToken::Space);
146 }
147 opt_1.unparse_tokens_mode(tokens, spaced);
148 }
149 tokens.push(PtxToken::Semicolon);
150 if spaced {
151 tokens.push(PtxToken::Newline);
152 }
153 }
154 }
155
156 impl PtxUnparser for WmmaLoadBSyncAlignedLayoutShapeSsBtype {
157 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
158 self.unparse_tokens_mode(tokens, false);
159 }
160 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
161 push_opcode(tokens, "wmma");
162 push_directive(tokens, "load");
163 push_directive(tokens, "b");
164 push_directive(tokens, "sync");
165 push_directive(tokens, "aligned");
166 match &self.layout {
167 Layout::Row => {
168 push_directive(tokens, "row");
169 }
170 Layout::Col => {
171 push_directive(tokens, "col");
172 }
173 }
174 match &self.shape {
175 Shape::M16n16k16 => {
176 push_directive(tokens, "m16n16k16");
177 }
178 Shape::M8n32k16 => {
179 push_directive(tokens, "m8n32k16");
180 }
181 Shape::M32n8k16 => {
182 push_directive(tokens, "m32n8k16");
183 }
184 }
185 if let Some(ss_2) = self.ss.as_ref() {
186 match ss_2 {
187 Ss::SharedCta => {
188 push_directive(tokens, "shared::cta");
189 }
190 Ss::Global => {
191 push_directive(tokens, "global");
192 }
193 Ss::Shared => {
194 push_directive(tokens, "shared");
195 }
196 }
197 }
198 match &self.btype {
199 Btype::F16 => {
200 push_directive(tokens, "f16");
201 }
202 Btype::S8 => {
203 push_directive(tokens, "s8");
204 }
205 Btype::U8 => {
206 push_directive(tokens, "u8");
207 }
208 }
209 if spaced {
210 tokens.push(PtxToken::Space);
211 }
212 self.r.unparse_tokens_mode(tokens, spaced);
213 tokens.push(PtxToken::Comma);
214 if spaced {
215 tokens.push(PtxToken::Space);
216 }
217 self.p.unparse_tokens_mode(tokens, spaced);
218 if self.stride.is_some() {
219 tokens.push(PtxToken::Comma);
220 }
221 if let Some(opt_3) = self.stride.as_ref() {
222 if spaced {
223 tokens.push(PtxToken::Space);
224 }
225 opt_3.unparse_tokens_mode(tokens, spaced);
226 }
227 tokens.push(PtxToken::Semicolon);
228 if spaced {
229 tokens.push(PtxToken::Newline);
230 }
231 }
232 }
233
234 impl PtxUnparser for WmmaLoadCSyncAlignedLayoutShapeSsCtype {
235 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
236 self.unparse_tokens_mode(tokens, false);
237 }
238 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
239 push_opcode(tokens, "wmma");
240 push_directive(tokens, "load");
241 push_directive(tokens, "c");
242 push_directive(tokens, "sync");
243 push_directive(tokens, "aligned");
244 match &self.layout {
245 Layout::Row => {
246 push_directive(tokens, "row");
247 }
248 Layout::Col => {
249 push_directive(tokens, "col");
250 }
251 }
252 match &self.shape {
253 Shape::M16n16k16 => {
254 push_directive(tokens, "m16n16k16");
255 }
256 Shape::M8n32k16 => {
257 push_directive(tokens, "m8n32k16");
258 }
259 Shape::M32n8k16 => {
260 push_directive(tokens, "m32n8k16");
261 }
262 }
263 if let Some(ss_4) = self.ss.as_ref() {
264 match ss_4 {
265 Ss::SharedCta => {
266 push_directive(tokens, "shared::cta");
267 }
268 Ss::Global => {
269 push_directive(tokens, "global");
270 }
271 Ss::Shared => {
272 push_directive(tokens, "shared");
273 }
274 }
275 }
276 match &self.ctype {
277 Ctype::F16 => {
278 push_directive(tokens, "f16");
279 }
280 Ctype::F32 => {
281 push_directive(tokens, "f32");
282 }
283 Ctype::S32 => {
284 push_directive(tokens, "s32");
285 }
286 }
287 if spaced {
288 tokens.push(PtxToken::Space);
289 }
290 self.r.unparse_tokens_mode(tokens, spaced);
291 tokens.push(PtxToken::Comma);
292 if spaced {
293 tokens.push(PtxToken::Space);
294 }
295 self.p.unparse_tokens_mode(tokens, spaced);
296 if self.stride.is_some() {
297 tokens.push(PtxToken::Comma);
298 }
299 if let Some(opt_5) = self.stride.as_ref() {
300 if spaced {
301 tokens.push(PtxToken::Space);
302 }
303 opt_5.unparse_tokens_mode(tokens, spaced);
304 }
305 tokens.push(PtxToken::Semicolon);
306 if spaced {
307 tokens.push(PtxToken::Newline);
308 }
309 }
310 }
311}
312
313pub mod section_1 {
314 use super::*;
315 use crate::r#type::instruction::wmma_load::section_1::*;
316
317 impl PtxUnparser for WmmaLoadASyncAlignedLayoutShapeSsAtype1 {
318 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
319 self.unparse_tokens_mode(tokens, false);
320 }
321 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
322 push_opcode(tokens, "wmma");
323 push_directive(tokens, "load");
324 push_directive(tokens, "a");
325 push_directive(tokens, "sync");
326 push_directive(tokens, "aligned");
327 match &self.layout {
328 Layout::Row => {
329 push_directive(tokens, "row");
330 }
331 Layout::Col => {
332 push_directive(tokens, "col");
333 }
334 }
335 match &self.shape {
336 Shape::M16n16k16 => {
337 push_directive(tokens, "m16n16k16");
338 }
339 Shape::M8n32k16 => {
340 push_directive(tokens, "m8n32k16");
341 }
342 Shape::M32n8k16 => {
343 push_directive(tokens, "m32n8k16");
344 }
345 }
346 if let Some(ss_6) = self.ss.as_ref() {
347 match ss_6 {
348 Ss::SharedCta => {
349 push_directive(tokens, "shared::cta");
350 }
351 Ss::Global => {
352 push_directive(tokens, "global");
353 }
354 Ss::Shared => {
355 push_directive(tokens, "shared");
356 }
357 }
358 }
359 match &self.atype {
360 Atype::Bf16 => {
361 push_directive(tokens, "bf16");
362 }
363 }
364 if spaced {
365 tokens.push(PtxToken::Space);
366 }
367 self.r.unparse_tokens_mode(tokens, spaced);
368 tokens.push(PtxToken::Comma);
369 if spaced {
370 tokens.push(PtxToken::Space);
371 }
372 self.p.unparse_tokens_mode(tokens, spaced);
373 if self.stride.is_some() {
374 tokens.push(PtxToken::Comma);
375 }
376 if let Some(opt_7) = self.stride.as_ref() {
377 if spaced {
378 tokens.push(PtxToken::Space);
379 }
380 opt_7.unparse_tokens_mode(tokens, spaced);
381 }
382 tokens.push(PtxToken::Semicolon);
383 if spaced {
384 tokens.push(PtxToken::Newline);
385 }
386 }
387 }
388
389 impl PtxUnparser for WmmaLoadBSyncAlignedLayoutShapeSsBtype1 {
390 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
391 self.unparse_tokens_mode(tokens, false);
392 }
393 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
394 push_opcode(tokens, "wmma");
395 push_directive(tokens, "load");
396 push_directive(tokens, "b");
397 push_directive(tokens, "sync");
398 push_directive(tokens, "aligned");
399 match &self.layout {
400 Layout::Row => {
401 push_directive(tokens, "row");
402 }
403 Layout::Col => {
404 push_directive(tokens, "col");
405 }
406 }
407 match &self.shape {
408 Shape::M16n16k16 => {
409 push_directive(tokens, "m16n16k16");
410 }
411 Shape::M8n32k16 => {
412 push_directive(tokens, "m8n32k16");
413 }
414 Shape::M32n8k16 => {
415 push_directive(tokens, "m32n8k16");
416 }
417 }
418 if let Some(ss_8) = self.ss.as_ref() {
419 match ss_8 {
420 Ss::SharedCta => {
421 push_directive(tokens, "shared::cta");
422 }
423 Ss::Global => {
424 push_directive(tokens, "global");
425 }
426 Ss::Shared => {
427 push_directive(tokens, "shared");
428 }
429 }
430 }
431 match &self.btype {
432 Btype::Bf16 => {
433 push_directive(tokens, "bf16");
434 }
435 }
436 if spaced {
437 tokens.push(PtxToken::Space);
438 }
439 self.r.unparse_tokens_mode(tokens, spaced);
440 tokens.push(PtxToken::Comma);
441 if spaced {
442 tokens.push(PtxToken::Space);
443 }
444 self.p.unparse_tokens_mode(tokens, spaced);
445 if self.stride.is_some() {
446 tokens.push(PtxToken::Comma);
447 }
448 if let Some(opt_9) = self.stride.as_ref() {
449 if spaced {
450 tokens.push(PtxToken::Space);
451 }
452 opt_9.unparse_tokens_mode(tokens, spaced);
453 }
454 tokens.push(PtxToken::Semicolon);
455 if spaced {
456 tokens.push(PtxToken::Newline);
457 }
458 }
459 }
460
461 impl PtxUnparser for WmmaLoadCSyncAlignedLayoutShapeSsCtype1 {
462 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
463 self.unparse_tokens_mode(tokens, false);
464 }
465 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
466 push_opcode(tokens, "wmma");
467 push_directive(tokens, "load");
468 push_directive(tokens, "c");
469 push_directive(tokens, "sync");
470 push_directive(tokens, "aligned");
471 match &self.layout {
472 Layout::Row => {
473 push_directive(tokens, "row");
474 }
475 Layout::Col => {
476 push_directive(tokens, "col");
477 }
478 }
479 match &self.shape {
480 Shape::M16n16k16 => {
481 push_directive(tokens, "m16n16k16");
482 }
483 Shape::M8n32k16 => {
484 push_directive(tokens, "m8n32k16");
485 }
486 Shape::M32n8k16 => {
487 push_directive(tokens, "m32n8k16");
488 }
489 }
490 if let Some(ss_10) = self.ss.as_ref() {
491 match ss_10 {
492 Ss::SharedCta => {
493 push_directive(tokens, "shared::cta");
494 }
495 Ss::Global => {
496 push_directive(tokens, "global");
497 }
498 Ss::Shared => {
499 push_directive(tokens, "shared");
500 }
501 }
502 }
503 match &self.ctype {
504 Ctype::F32 => {
505 push_directive(tokens, "f32");
506 }
507 }
508 if spaced {
509 tokens.push(PtxToken::Space);
510 }
511 self.r.unparse_tokens_mode(tokens, spaced);
512 tokens.push(PtxToken::Comma);
513 if spaced {
514 tokens.push(PtxToken::Space);
515 }
516 self.p.unparse_tokens_mode(tokens, spaced);
517 if self.stride.is_some() {
518 tokens.push(PtxToken::Comma);
519 }
520 if let Some(opt_11) = self.stride.as_ref() {
521 if spaced {
522 tokens.push(PtxToken::Space);
523 }
524 opt_11.unparse_tokens_mode(tokens, spaced);
525 }
526 tokens.push(PtxToken::Semicolon);
527 if spaced {
528 tokens.push(PtxToken::Newline);
529 }
530 }
531 }
532}
533
534pub mod section_2 {
535 use super::*;
536 use crate::r#type::instruction::wmma_load::section_2::*;
537
538 impl PtxUnparser for WmmaLoadASyncAlignedLayoutShapeSsAtype2 {
539 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
540 self.unparse_tokens_mode(tokens, false);
541 }
542 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
543 push_opcode(tokens, "wmma");
544 push_directive(tokens, "load");
545 push_directive(tokens, "a");
546 push_directive(tokens, "sync");
547 push_directive(tokens, "aligned");
548 match &self.layout {
549 Layout::Row => {
550 push_directive(tokens, "row");
551 }
552 Layout::Col => {
553 push_directive(tokens, "col");
554 }
555 }
556 match &self.shape {
557 Shape::M16n16k8 => {
558 push_directive(tokens, "m16n16k8");
559 }
560 }
561 if let Some(ss_12) = self.ss.as_ref() {
562 match ss_12 {
563 Ss::SharedCta => {
564 push_directive(tokens, "shared::cta");
565 }
566 Ss::Global => {
567 push_directive(tokens, "global");
568 }
569 Ss::Shared => {
570 push_directive(tokens, "shared");
571 }
572 }
573 }
574 match &self.atype {
575 Atype::Tf32 => {
576 push_directive(tokens, "tf32");
577 }
578 }
579 if spaced {
580 tokens.push(PtxToken::Space);
581 }
582 self.r.unparse_tokens_mode(tokens, spaced);
583 tokens.push(PtxToken::Comma);
584 if spaced {
585 tokens.push(PtxToken::Space);
586 }
587 self.p.unparse_tokens_mode(tokens, spaced);
588 if self.stride.is_some() {
589 tokens.push(PtxToken::Comma);
590 }
591 if let Some(opt_13) = self.stride.as_ref() {
592 if spaced {
593 tokens.push(PtxToken::Space);
594 }
595 opt_13.unparse_tokens_mode(tokens, spaced);
596 }
597 tokens.push(PtxToken::Semicolon);
598 if spaced {
599 tokens.push(PtxToken::Newline);
600 }
601 }
602 }
603
604 impl PtxUnparser for WmmaLoadBSyncAlignedLayoutShapeSsBtype2 {
605 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
606 self.unparse_tokens_mode(tokens, false);
607 }
608 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
609 push_opcode(tokens, "wmma");
610 push_directive(tokens, "load");
611 push_directive(tokens, "b");
612 push_directive(tokens, "sync");
613 push_directive(tokens, "aligned");
614 match &self.layout {
615 Layout::Row => {
616 push_directive(tokens, "row");
617 }
618 Layout::Col => {
619 push_directive(tokens, "col");
620 }
621 }
622 match &self.shape {
623 Shape::M16n16k8 => {
624 push_directive(tokens, "m16n16k8");
625 }
626 }
627 if let Some(ss_14) = self.ss.as_ref() {
628 match ss_14 {
629 Ss::SharedCta => {
630 push_directive(tokens, "shared::cta");
631 }
632 Ss::Global => {
633 push_directive(tokens, "global");
634 }
635 Ss::Shared => {
636 push_directive(tokens, "shared");
637 }
638 }
639 }
640 match &self.btype {
641 Btype::Tf32 => {
642 push_directive(tokens, "tf32");
643 }
644 }
645 if spaced {
646 tokens.push(PtxToken::Space);
647 }
648 self.r.unparse_tokens_mode(tokens, spaced);
649 tokens.push(PtxToken::Comma);
650 if spaced {
651 tokens.push(PtxToken::Space);
652 }
653 self.p.unparse_tokens_mode(tokens, spaced);
654 if self.stride.is_some() {
655 tokens.push(PtxToken::Comma);
656 }
657 if let Some(opt_15) = self.stride.as_ref() {
658 if spaced {
659 tokens.push(PtxToken::Space);
660 }
661 opt_15.unparse_tokens_mode(tokens, spaced);
662 }
663 tokens.push(PtxToken::Semicolon);
664 if spaced {
665 tokens.push(PtxToken::Newline);
666 }
667 }
668 }
669
670 impl PtxUnparser for WmmaLoadCSyncAlignedLayoutShapeSsCtype2 {
671 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
672 self.unparse_tokens_mode(tokens, false);
673 }
674 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
675 push_opcode(tokens, "wmma");
676 push_directive(tokens, "load");
677 push_directive(tokens, "c");
678 push_directive(tokens, "sync");
679 push_directive(tokens, "aligned");
680 match &self.layout {
681 Layout::Row => {
682 push_directive(tokens, "row");
683 }
684 Layout::Col => {
685 push_directive(tokens, "col");
686 }
687 }
688 match &self.shape {
689 Shape::M16n16k8 => {
690 push_directive(tokens, "m16n16k8");
691 }
692 }
693 if let Some(ss_16) = self.ss.as_ref() {
694 match ss_16 {
695 Ss::SharedCta => {
696 push_directive(tokens, "shared::cta");
697 }
698 Ss::Global => {
699 push_directive(tokens, "global");
700 }
701 Ss::Shared => {
702 push_directive(tokens, "shared");
703 }
704 }
705 }
706 match &self.ctype {
707 Ctype::F32 => {
708 push_directive(tokens, "f32");
709 }
710 }
711 if spaced {
712 tokens.push(PtxToken::Space);
713 }
714 self.r.unparse_tokens_mode(tokens, spaced);
715 tokens.push(PtxToken::Comma);
716 if spaced {
717 tokens.push(PtxToken::Space);
718 }
719 self.p.unparse_tokens_mode(tokens, spaced);
720 if self.stride.is_some() {
721 tokens.push(PtxToken::Comma);
722 }
723 if let Some(opt_17) = self.stride.as_ref() {
724 if spaced {
725 tokens.push(PtxToken::Space);
726 }
727 opt_17.unparse_tokens_mode(tokens, spaced);
728 }
729 tokens.push(PtxToken::Semicolon);
730 if spaced {
731 tokens.push(PtxToken::Newline);
732 }
733 }
734 }
735}
736
737pub mod section_3 {
738 use super::*;
739 use crate::r#type::instruction::wmma_load::section_3::*;
740
741 impl PtxUnparser for WmmaLoadASyncAlignedLayoutShapeSsAtype3 {
742 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
743 self.unparse_tokens_mode(tokens, false);
744 }
745 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
746 push_opcode(tokens, "wmma");
747 push_directive(tokens, "load");
748 push_directive(tokens, "a");
749 push_directive(tokens, "sync");
750 push_directive(tokens, "aligned");
751 match &self.layout {
752 Layout::Row => {
753 push_directive(tokens, "row");
754 }
755 Layout::Col => {
756 push_directive(tokens, "col");
757 }
758 }
759 match &self.shape {
760 Shape::M8n8k4 => {
761 push_directive(tokens, "m8n8k4");
762 }
763 }
764 if let Some(ss_18) = self.ss.as_ref() {
765 match ss_18 {
766 Ss::SharedCta => {
767 push_directive(tokens, "shared::cta");
768 }
769 Ss::Global => {
770 push_directive(tokens, "global");
771 }
772 Ss::Shared => {
773 push_directive(tokens, "shared");
774 }
775 }
776 }
777 match &self.atype {
778 Atype::F64 => {
779 push_directive(tokens, "f64");
780 }
781 }
782 if spaced {
783 tokens.push(PtxToken::Space);
784 }
785 self.r.unparse_tokens_mode(tokens, spaced);
786 tokens.push(PtxToken::Comma);
787 if spaced {
788 tokens.push(PtxToken::Space);
789 }
790 self.p.unparse_tokens_mode(tokens, spaced);
791 if self.stride.is_some() {
792 tokens.push(PtxToken::Comma);
793 }
794 if let Some(opt_19) = self.stride.as_ref() {
795 if spaced {
796 tokens.push(PtxToken::Space);
797 }
798 opt_19.unparse_tokens_mode(tokens, spaced);
799 }
800 tokens.push(PtxToken::Semicolon);
801 if spaced {
802 tokens.push(PtxToken::Newline);
803 }
804 }
805 }
806
807 impl PtxUnparser for WmmaLoadBSyncAlignedLayoutShapeSsBtype3 {
808 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
809 self.unparse_tokens_mode(tokens, false);
810 }
811 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
812 push_opcode(tokens, "wmma");
813 push_directive(tokens, "load");
814 push_directive(tokens, "b");
815 push_directive(tokens, "sync");
816 push_directive(tokens, "aligned");
817 match &self.layout {
818 Layout::Row => {
819 push_directive(tokens, "row");
820 }
821 Layout::Col => {
822 push_directive(tokens, "col");
823 }
824 }
825 match &self.shape {
826 Shape::M8n8k4 => {
827 push_directive(tokens, "m8n8k4");
828 }
829 }
830 if let Some(ss_20) = self.ss.as_ref() {
831 match ss_20 {
832 Ss::SharedCta => {
833 push_directive(tokens, "shared::cta");
834 }
835 Ss::Global => {
836 push_directive(tokens, "global");
837 }
838 Ss::Shared => {
839 push_directive(tokens, "shared");
840 }
841 }
842 }
843 match &self.btype {
844 Btype::F64 => {
845 push_directive(tokens, "f64");
846 }
847 }
848 if spaced {
849 tokens.push(PtxToken::Space);
850 }
851 self.r.unparse_tokens_mode(tokens, spaced);
852 tokens.push(PtxToken::Comma);
853 if spaced {
854 tokens.push(PtxToken::Space);
855 }
856 self.p.unparse_tokens_mode(tokens, spaced);
857 if self.stride.is_some() {
858 tokens.push(PtxToken::Comma);
859 }
860 if let Some(opt_21) = self.stride.as_ref() {
861 if spaced {
862 tokens.push(PtxToken::Space);
863 }
864 opt_21.unparse_tokens_mode(tokens, spaced);
865 }
866 tokens.push(PtxToken::Semicolon);
867 if spaced {
868 tokens.push(PtxToken::Newline);
869 }
870 }
871 }
872
873 impl PtxUnparser for WmmaLoadCSyncAlignedLayoutShapeSsCtype3 {
874 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
875 self.unparse_tokens_mode(tokens, false);
876 }
877 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
878 push_opcode(tokens, "wmma");
879 push_directive(tokens, "load");
880 push_directive(tokens, "c");
881 push_directive(tokens, "sync");
882 push_directive(tokens, "aligned");
883 match &self.layout {
884 Layout::Row => {
885 push_directive(tokens, "row");
886 }
887 Layout::Col => {
888 push_directive(tokens, "col");
889 }
890 }
891 match &self.shape {
892 Shape::M8n8k4 => {
893 push_directive(tokens, "m8n8k4");
894 }
895 }
896 if let Some(ss_22) = self.ss.as_ref() {
897 match ss_22 {
898 Ss::SharedCta => {
899 push_directive(tokens, "shared::cta");
900 }
901 Ss::Global => {
902 push_directive(tokens, "global");
903 }
904 Ss::Shared => {
905 push_directive(tokens, "shared");
906 }
907 }
908 }
909 match &self.ctype {
910 Ctype::F64 => {
911 push_directive(tokens, "f64");
912 }
913 }
914 if spaced {
915 tokens.push(PtxToken::Space);
916 }
917 self.r.unparse_tokens_mode(tokens, spaced);
918 tokens.push(PtxToken::Comma);
919 if spaced {
920 tokens.push(PtxToken::Space);
921 }
922 self.p.unparse_tokens_mode(tokens, spaced);
923 if self.stride.is_some() {
924 tokens.push(PtxToken::Comma);
925 }
926 if let Some(opt_23) = self.stride.as_ref() {
927 if spaced {
928 tokens.push(PtxToken::Space);
929 }
930 opt_23.unparse_tokens_mode(tokens, spaced);
931 }
932 tokens.push(PtxToken::Semicolon);
933 if spaced {
934 tokens.push(PtxToken::Newline);
935 }
936 }
937 }
938}
939
940pub mod section_4 {
941 use super::*;
942 use crate::r#type::instruction::wmma_load::section_4::*;
943
944 impl PtxUnparser for WmmaLoadASyncAlignedRowShapeSsAtype {
945 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
946 self.unparse_tokens_mode(tokens, false);
947 }
948 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
949 push_opcode(tokens, "wmma");
950 push_directive(tokens, "load");
951 push_directive(tokens, "a");
952 push_directive(tokens, "sync");
953 push_directive(tokens, "aligned");
954 push_directive(tokens, "row");
955 match &self.shape {
956 Shape::M8n8k32 => {
957 push_directive(tokens, "m8n8k32");
958 }
959 }
960 if let Some(ss_24) = self.ss.as_ref() {
961 match ss_24 {
962 Ss::SharedCta => {
963 push_directive(tokens, "shared::cta");
964 }
965 Ss::Global => {
966 push_directive(tokens, "global");
967 }
968 Ss::Shared => {
969 push_directive(tokens, "shared");
970 }
971 }
972 }
973 match &self.atype {
974 Atype::S4 => {
975 push_directive(tokens, "s4");
976 }
977 Atype::U4 => {
978 push_directive(tokens, "u4");
979 }
980 }
981 if spaced {
982 tokens.push(PtxToken::Space);
983 }
984 self.r.unparse_tokens_mode(tokens, spaced);
985 tokens.push(PtxToken::Comma);
986 if spaced {
987 tokens.push(PtxToken::Space);
988 }
989 self.p.unparse_tokens_mode(tokens, spaced);
990 if self.stride.is_some() {
991 tokens.push(PtxToken::Comma);
992 }
993 if let Some(opt_25) = self.stride.as_ref() {
994 if spaced {
995 tokens.push(PtxToken::Space);
996 }
997 opt_25.unparse_tokens_mode(tokens, spaced);
998 }
999 tokens.push(PtxToken::Semicolon);
1000 if spaced {
1001 tokens.push(PtxToken::Newline);
1002 }
1003 }
1004 }
1005
1006 impl PtxUnparser for WmmaLoadBSyncAlignedColShapeSsBtype {
1007 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
1008 self.unparse_tokens_mode(tokens, false);
1009 }
1010 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
1011 push_opcode(tokens, "wmma");
1012 push_directive(tokens, "load");
1013 push_directive(tokens, "b");
1014 push_directive(tokens, "sync");
1015 push_directive(tokens, "aligned");
1016 push_directive(tokens, "col");
1017 match &self.shape {
1018 Shape::M8n8k32 => {
1019 push_directive(tokens, "m8n8k32");
1020 }
1021 }
1022 if let Some(ss_26) = self.ss.as_ref() {
1023 match ss_26 {
1024 Ss::SharedCta => {
1025 push_directive(tokens, "shared::cta");
1026 }
1027 Ss::Global => {
1028 push_directive(tokens, "global");
1029 }
1030 Ss::Shared => {
1031 push_directive(tokens, "shared");
1032 }
1033 }
1034 }
1035 match &self.btype {
1036 Btype::S4 => {
1037 push_directive(tokens, "s4");
1038 }
1039 Btype::U4 => {
1040 push_directive(tokens, "u4");
1041 }
1042 }
1043 if spaced {
1044 tokens.push(PtxToken::Space);
1045 }
1046 self.r.unparse_tokens_mode(tokens, spaced);
1047 tokens.push(PtxToken::Comma);
1048 if spaced {
1049 tokens.push(PtxToken::Space);
1050 }
1051 self.p.unparse_tokens_mode(tokens, spaced);
1052 if self.stride.is_some() {
1053 tokens.push(PtxToken::Comma);
1054 }
1055 if let Some(opt_27) = self.stride.as_ref() {
1056 if spaced {
1057 tokens.push(PtxToken::Space);
1058 }
1059 opt_27.unparse_tokens_mode(tokens, spaced);
1060 }
1061 tokens.push(PtxToken::Semicolon);
1062 if spaced {
1063 tokens.push(PtxToken::Newline);
1064 }
1065 }
1066 }
1067
1068 impl PtxUnparser for WmmaLoadCSyncAlignedLayoutShapeSsCtype4 {
1069 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
1070 self.unparse_tokens_mode(tokens, false);
1071 }
1072 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
1073 push_opcode(tokens, "wmma");
1074 push_directive(tokens, "load");
1075 push_directive(tokens, "c");
1076 push_directive(tokens, "sync");
1077 push_directive(tokens, "aligned");
1078 match &self.layout {
1079 Layout::Row => {
1080 push_directive(tokens, "row");
1081 }
1082 Layout::Col => {
1083 push_directive(tokens, "col");
1084 }
1085 }
1086 match &self.shape {
1087 Shape::M8n8k32 => {
1088 push_directive(tokens, "m8n8k32");
1089 }
1090 }
1091 if let Some(ss_28) = self.ss.as_ref() {
1092 match ss_28 {
1093 Ss::SharedCta => {
1094 push_directive(tokens, "shared::cta");
1095 }
1096 Ss::Global => {
1097 push_directive(tokens, "global");
1098 }
1099 Ss::Shared => {
1100 push_directive(tokens, "shared");
1101 }
1102 }
1103 }
1104 match &self.ctype {
1105 Ctype::S32 => {
1106 push_directive(tokens, "s32");
1107 }
1108 }
1109 if spaced {
1110 tokens.push(PtxToken::Space);
1111 }
1112 self.r.unparse_tokens_mode(tokens, spaced);
1113 tokens.push(PtxToken::Comma);
1114 if spaced {
1115 tokens.push(PtxToken::Space);
1116 }
1117 self.p.unparse_tokens_mode(tokens, spaced);
1118 if self.stride.is_some() {
1119 tokens.push(PtxToken::Comma);
1120 }
1121 if let Some(opt_29) = self.stride.as_ref() {
1122 if spaced {
1123 tokens.push(PtxToken::Space);
1124 }
1125 opt_29.unparse_tokens_mode(tokens, spaced);
1126 }
1127 tokens.push(PtxToken::Semicolon);
1128 if spaced {
1129 tokens.push(PtxToken::Newline);
1130 }
1131 }
1132 }
1133}
1134
1135pub mod section_5 {
1136 use super::*;
1137 use crate::r#type::instruction::wmma_load::section_5::*;
1138
1139 impl PtxUnparser for WmmaLoadASyncAlignedRowShapeSsAtype1 {
1140 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
1141 self.unparse_tokens_mode(tokens, false);
1142 }
1143 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
1144 push_opcode(tokens, "wmma");
1145 push_directive(tokens, "load");
1146 push_directive(tokens, "a");
1147 push_directive(tokens, "sync");
1148 push_directive(tokens, "aligned");
1149 push_directive(tokens, "row");
1150 match &self.shape {
1151 Shape::M8n8k128 => {
1152 push_directive(tokens, "m8n8k128");
1153 }
1154 }
1155 if let Some(ss_30) = self.ss.as_ref() {
1156 match ss_30 {
1157 Ss::SharedCta => {
1158 push_directive(tokens, "shared::cta");
1159 }
1160 Ss::Global => {
1161 push_directive(tokens, "global");
1162 }
1163 Ss::Shared => {
1164 push_directive(tokens, "shared");
1165 }
1166 }
1167 }
1168 match &self.atype {
1169 Atype::B1 => {
1170 push_directive(tokens, "b1");
1171 }
1172 }
1173 if spaced {
1174 tokens.push(PtxToken::Space);
1175 }
1176 self.r.unparse_tokens_mode(tokens, spaced);
1177 tokens.push(PtxToken::Comma);
1178 if spaced {
1179 tokens.push(PtxToken::Space);
1180 }
1181 self.p.unparse_tokens_mode(tokens, spaced);
1182 if self.stride.is_some() {
1183 tokens.push(PtxToken::Comma);
1184 }
1185 if let Some(opt_31) = self.stride.as_ref() {
1186 if spaced {
1187 tokens.push(PtxToken::Space);
1188 }
1189 opt_31.unparse_tokens_mode(tokens, spaced);
1190 }
1191 tokens.push(PtxToken::Semicolon);
1192 if spaced {
1193 tokens.push(PtxToken::Newline);
1194 }
1195 }
1196 }
1197
1198 impl PtxUnparser for WmmaLoadBSyncAlignedColShapeSsBtype1 {
1199 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
1200 self.unparse_tokens_mode(tokens, false);
1201 }
1202 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
1203 push_opcode(tokens, "wmma");
1204 push_directive(tokens, "load");
1205 push_directive(tokens, "b");
1206 push_directive(tokens, "sync");
1207 push_directive(tokens, "aligned");
1208 push_directive(tokens, "col");
1209 match &self.shape {
1210 Shape::M8n8k128 => {
1211 push_directive(tokens, "m8n8k128");
1212 }
1213 }
1214 if let Some(ss_32) = self.ss.as_ref() {
1215 match ss_32 {
1216 Ss::SharedCta => {
1217 push_directive(tokens, "shared::cta");
1218 }
1219 Ss::Global => {
1220 push_directive(tokens, "global");
1221 }
1222 Ss::Shared => {
1223 push_directive(tokens, "shared");
1224 }
1225 }
1226 }
1227 match &self.btype {
1228 Btype::B1 => {
1229 push_directive(tokens, "b1");
1230 }
1231 }
1232 if spaced {
1233 tokens.push(PtxToken::Space);
1234 }
1235 self.r.unparse_tokens_mode(tokens, spaced);
1236 tokens.push(PtxToken::Comma);
1237 if spaced {
1238 tokens.push(PtxToken::Space);
1239 }
1240 self.p.unparse_tokens_mode(tokens, spaced);
1241 if self.stride.is_some() {
1242 tokens.push(PtxToken::Comma);
1243 }
1244 if let Some(opt_33) = self.stride.as_ref() {
1245 if spaced {
1246 tokens.push(PtxToken::Space);
1247 }
1248 opt_33.unparse_tokens_mode(tokens, spaced);
1249 }
1250 tokens.push(PtxToken::Semicolon);
1251 if spaced {
1252 tokens.push(PtxToken::Newline);
1253 }
1254 }
1255 }
1256
1257 impl PtxUnparser for WmmaLoadCSyncAlignedLayoutShapeSsCtype5 {
1258 fn unparse_tokens(&self, tokens: &mut ::std::vec::Vec<PtxToken>) {
1259 self.unparse_tokens_mode(tokens, false);
1260 }
1261 fn unparse_tokens_mode(&self, tokens: &mut ::std::vec::Vec<PtxToken>, spaced: bool) {
1262 push_opcode(tokens, "wmma");
1263 push_directive(tokens, "load");
1264 push_directive(tokens, "c");
1265 push_directive(tokens, "sync");
1266 push_directive(tokens, "aligned");
1267 match &self.layout {
1268 Layout::Row => {
1269 push_directive(tokens, "row");
1270 }
1271 Layout::Col => {
1272 push_directive(tokens, "col");
1273 }
1274 }
1275 match &self.shape {
1276 Shape::M8n8k128 => {
1277 push_directive(tokens, "m8n8k128");
1278 }
1279 }
1280 if let Some(ss_34) = self.ss.as_ref() {
1281 match ss_34 {
1282 Ss::SharedCta => {
1283 push_directive(tokens, "shared::cta");
1284 }
1285 Ss::Global => {
1286 push_directive(tokens, "global");
1287 }
1288 Ss::Shared => {
1289 push_directive(tokens, "shared");
1290 }
1291 }
1292 }
1293 match &self.ctype {
1294 Ctype::S32 => {
1295 push_directive(tokens, "s32");
1296 }
1297 }
1298 if spaced {
1299 tokens.push(PtxToken::Space);
1300 }
1301 self.r.unparse_tokens_mode(tokens, spaced);
1302 tokens.push(PtxToken::Comma);
1303 if spaced {
1304 tokens.push(PtxToken::Space);
1305 }
1306 self.p.unparse_tokens_mode(tokens, spaced);
1307 if self.stride.is_some() {
1308 tokens.push(PtxToken::Comma);
1309 }
1310 if let Some(opt_35) = self.stride.as_ref() {
1311 if spaced {
1312 tokens.push(PtxToken::Space);
1313 }
1314 opt_35.unparse_tokens_mode(tokens, spaced);
1315 }
1316 tokens.push(PtxToken::Semicolon);
1317 if spaced {
1318 tokens.push(PtxToken::Newline);
1319 }
1320 }
1321 }
1322}