@@ -58,7 +58,7 @@ mod attr_impl {
5858 // The subset of llvm::Attribute needed for arguments, packed into a bitfield.
5959 bitflags ! {
6060 #[ derive( Default , Debug ) ]
61- flags ArgAttribute : u8 {
61+ flags ArgAttribute : u16 {
6262 const ByVal = 1 << 0 ,
6363 const NoAlias = 1 << 1 ,
6464 const NoCapture = 1 << 2 ,
@@ -67,6 +67,7 @@ mod attr_impl {
6767 const SExt = 1 << 5 ,
6868 const StructRet = 1 << 6 ,
6969 const ZExt = 1 << 7 ,
70+ const InReg = 1 << 8 ,
7071 }
7172 }
7273}
@@ -80,7 +81,7 @@ macro_rules! for_each_kind {
8081impl ArgAttribute {
8182 fn for_each_kind < F > ( & self , mut f : F ) where F : FnMut ( llvm:: Attribute ) {
8283 for_each_kind ! ( self , f,
83- ByVal , NoAlias , NoCapture , NonNull , ReadOnly , SExt , StructRet , ZExt )
84+ ByVal , NoAlias , NoCapture , NonNull , ReadOnly , SExt , StructRet , ZExt , InReg )
8485 }
8586}
8687
@@ -573,7 +574,14 @@ impl FnType {
573574 }
574575
575576 match & ccx. sess ( ) . target . target . arch [ ..] {
576- "x86" => cabi_x86:: compute_abi_info ( ccx, self ) ,
577+ "x86" => {
578+ let flavor = if abi == Abi :: Fastcall {
579+ cabi_x86:: Flavor :: Fastcall
580+ } else {
581+ cabi_x86:: Flavor :: General
582+ } ;
583+ cabi_x86:: compute_abi_info ( ccx, self , flavor) ;
584+ } ,
577585 "x86_64" => if abi == Abi :: SysV64 {
578586 cabi_x86_64:: compute_abi_info ( ccx, self ) ;
579587 } else if abi == Abi :: Win64 || ccx. sess ( ) . target . target . options . is_like_windows {
0 commit comments