@@ -517,6 +517,71 @@ const MIPS_FEATURES: &[(&str, Stability, ImpliedFeatures)] = &[
517517 // tidy-alphabetical-end
518518] ;
519519
520+ const NVPTX_FEATURES : & [ ( & str , Stability , ImpliedFeatures ) ] = & [
521+ // tidy-alphabetical-start
522+ ( "sm_20" , Unstable ( sym:: nvptx_target_feature) , & [ ] ) ,
523+ ( "sm_21" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_20" ] ) ,
524+ ( "sm_30" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_21" ] ) ,
525+ ( "sm_32" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_30" ] ) ,
526+ ( "sm_35" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_32" ] ) ,
527+ ( "sm_37" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_35" ] ) ,
528+ ( "sm_50" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_37" ] ) ,
529+ ( "sm_52" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_50" ] ) ,
530+ ( "sm_53" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_52" ] ) ,
531+ ( "sm_60" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_53" ] ) ,
532+ ( "sm_61" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_60" ] ) ,
533+ ( "sm_62" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_61" ] ) ,
534+ ( "sm_70" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_62" ] ) ,
535+ ( "sm_72" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_70" ] ) ,
536+ ( "sm_75" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_72" ] ) ,
537+ ( "sm_80" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_75" ] ) ,
538+ ( "sm_86" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_80" ] ) ,
539+ ( "sm_87" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_86" ] ) ,
540+ ( "sm_89" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_87" ] ) ,
541+ ( "sm_90" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_89" ] ) ,
542+ ( "sm_90a" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_90" ] ) ,
543+ // tidy-alphabetical-end
544+ // tidy-alphabetical-start
545+ ( "sm_100" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_90" ] ) ,
546+ ( "sm_100a" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_100" ] ) ,
547+ ( "sm_101" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_100" ] ) ,
548+ ( "sm_101a" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_101" ] ) ,
549+ ( "sm_120" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_101" ] ) ,
550+ ( "sm_120a" , Unstable ( sym:: nvptx_target_feature) , & [ "sm_120" ] ) ,
551+ // tidy-alphabetical-end
552+ // tidy-alphabetical-start
553+ ( "ptx32" , Unstable ( sym:: nvptx_target_feature) , & [ ] ) ,
554+ ( "ptx40" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx32" ] ) ,
555+ ( "ptx41" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx40" ] ) ,
556+ ( "ptx42" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx41" ] ) ,
557+ ( "ptx43" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx42" ] ) ,
558+ ( "ptx50" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx43" ] ) ,
559+ ( "ptx60" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx50" ] ) ,
560+ ( "ptx61" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx60" ] ) ,
561+ ( "ptx62" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx61" ] ) ,
562+ ( "ptx63" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx62" ] ) ,
563+ ( "ptx64" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx63" ] ) ,
564+ ( "ptx65" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx64" ] ) ,
565+ ( "ptx70" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx65" ] ) ,
566+ ( "ptx71" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx70" ] ) ,
567+ ( "ptx72" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx71" ] ) ,
568+ ( "ptx73" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx72" ] ) ,
569+ ( "ptx74" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx73" ] ) ,
570+ ( "ptx75" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx74" ] ) ,
571+ ( "ptx76" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx75" ] ) ,
572+ ( "ptx77" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx76" ] ) ,
573+ ( "ptx78" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx77" ] ) ,
574+ ( "ptx80" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx78" ] ) ,
575+ ( "ptx81" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx80" ] ) ,
576+ ( "ptx82" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx81" ] ) ,
577+ ( "ptx83" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx82" ] ) ,
578+ ( "ptx84" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx83" ] ) ,
579+ ( "ptx85" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx84" ] ) ,
580+ ( "ptx86" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx85" ] ) ,
581+ ( "ptx87" , Unstable ( sym:: nvptx_target_feature) , & [ "ptx86" ] ) ,
582+ // tidy-alphabetical-end
583+ ] ;
584+
520585static RISCV_FEATURES : & [ ( & str , Stability , ImpliedFeatures ) ] = & [
521586 // tidy-alphabetical-start
522587 ( "a" , Stable , & [ "zaamo" , "zalrsc" ] ) ,
@@ -782,6 +847,7 @@ pub fn all_rust_features() -> impl Iterator<Item = (&'static str, Stability)> {
782847 . chain ( HEXAGON_FEATURES . iter ( ) )
783848 . chain ( POWERPC_FEATURES . iter ( ) )
784849 . chain ( MIPS_FEATURES . iter ( ) )
850+ . chain ( NVPTX_FEATURES . iter ( ) )
785851 . chain ( RISCV_FEATURES . iter ( ) )
786852 . chain ( WASM_FEATURES . iter ( ) )
787853 . chain ( BPF_FEATURES . iter ( ) )
@@ -847,6 +913,7 @@ impl Target {
847913 "x86" | "x86_64" => X86_FEATURES ,
848914 "hexagon" => HEXAGON_FEATURES ,
849915 "mips" | "mips32r6" | "mips64" | "mips64r6" => MIPS_FEATURES ,
916+ "nvptx64" => NVPTX_FEATURES ,
850917 "powerpc" | "powerpc64" => POWERPC_FEATURES ,
851918 "riscv32" | "riscv64" => RISCV_FEATURES ,
852919 "wasm32" | "wasm64" => WASM_FEATURES ,
@@ -873,7 +940,7 @@ impl Target {
873940 "sparc" | "sparc64" => SPARC_FEATURES_FOR_CORRECT_VECTOR_ABI ,
874941 "hexagon" => HEXAGON_FEATURES_FOR_CORRECT_VECTOR_ABI ,
875942 "mips" | "mips32r6" | "mips64" | "mips64r6" => MIPS_FEATURES_FOR_CORRECT_VECTOR_ABI ,
876- "bpf" | "m68k" => & [ ] , // no vector ABI
943+ "nvptx64" | " bpf" | "m68k" => & [ ] , // no vector ABI
877944 "csky" => CSKY_FEATURES_FOR_CORRECT_VECTOR_ABI ,
878945 // FIXME: for some tier3 targets, we are overly cautious and always give warnings
879946 // when passing args in vector registers.
0 commit comments