@@ -723,6 +723,20 @@ const SPARC_FEATURES: &[(&str, StabilityUncomputed, ImpliedFeatures)] = &[
723723 // tidy-alphabetical-end
724724] ;
725725
726+ const M68K_FEATURES : & [ ( & str , StabilityUncomputed , ImpliedFeatures ) ] = & [
727+ // tidy-alphabetical-start
728+ ( "isa-68000" , unstable ( sym:: m68k_target_feature) , & [ ] ) ,
729+ ( "isa-68010" , unstable ( sym:: m68k_target_feature) , & [ "isa-68000" ] ) ,
730+ ( "isa-68020" , unstable ( sym:: m68k_target_feature) , & [ "isa-68010" ] ) ,
731+ ( "isa-68030" , unstable ( sym:: m68k_target_feature) , & [ "isa-68020" ] ) ,
732+ ( "isa-68040" , unstable ( sym:: m68k_target_feature) , & [ "isa-68030" , "isa-68882" ] ) ,
733+ ( "isa-68060" , unstable ( sym:: m68k_target_feature) , & [ "isa-68040" ] ) ,
734+ // FPU
735+ ( "isa-68881" , unstable ( sym:: m68k_target_feature) , & [ ] ) ,
736+ ( "isa-68882" , unstable ( sym:: m68k_target_feature) , & [ "isa-68881" ] ) ,
737+ // tidy-alphabetical-end
738+ ] ;
739+
726740/// When rustdoc is running, provide a list of all known features so that all their respective
727741/// primitives may be documented.
728742///
@@ -742,6 +756,7 @@ pub fn all_rust_features() -> impl Iterator<Item = (&'static str, StabilityUncom
742756 . chain ( LOONGARCH_FEATURES )
743757 . chain ( IBMZ_FEATURES )
744758 . chain ( SPARC_FEATURES )
759+ . chain ( M68K_FEATURES )
745760 . cloned ( )
746761 . map ( |( f, s, _) | ( f, s) )
747762}
@@ -789,6 +804,7 @@ impl Target {
789804 "loongarch64" => LOONGARCH_FEATURES ,
790805 "s390x" => IBMZ_FEATURES ,
791806 "sparc" | "sparc64" => SPARC_FEATURES ,
807+ "m68k" => M68K_FEATURES ,
792808 _ => & [ ] ,
793809 }
794810 }
@@ -806,7 +822,7 @@ impl Target {
806822 "sparc" | "sparc64" => SPARC_FEATURES_FOR_CORRECT_VECTOR_ABI ,
807823 "hexagon" => HEXAGON_FEATURES_FOR_CORRECT_VECTOR_ABI ,
808824 "mips" | "mips32r6" | "mips64" | "mips64r6" => MIPS_FEATURES_FOR_CORRECT_VECTOR_ABI ,
809- "bpf" => & [ ] , // no vector ABI
825+ "bpf" | "m68k" => & [ ] , // no vector ABI
810826 "csky" => CSKY_FEATURES_FOR_CORRECT_VECTOR_ABI ,
811827 // FIXME: for some tier3 targets, we are overly cautious and always give warnings
812828 // when passing args in vector registers.
0 commit comments