This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Handle SET_TYPE on x86_64


The following patch is needed for GPC support and has been approved by
Jan Hubicka offline.

Bootstrapped, regtested on x86_64-gnu-linux (both 3.3 and mainline),
committed to mainline only,

Andreas

2003-10-22  Waldek Hebisch <hebisch@math.uni.wroc.pl>

	* config/i386/i386.c (classify_argument): Handle SET_TYPE.

============================================================
Index: gcc/config/i386/i386.c
--- gcc/config/i386/i386.c	20 Oct 2003 18:32:50 -0000	1.610
+++ gcc/config/i386/i386.c	21 Oct 2003 13:36:57 -0000
@@ -2080,6 +2080,31 @@ classify_argument (enum machine_mode mod
 		}
 	    }
 	}
+      else if (TREE_CODE (type) == SET_TYPE)
+	{
+	  if (bytes <= 4)
+	    {
+	      classes[0] = X86_64_INTEGERSI_CLASS;
+	      return 1;
+	    }
+	  else if (bytes <= 8)
+	    {
+	      classes[0] = X86_64_INTEGER_CLASS;
+	      return 1;
+	    }
+	  else if (bytes <= 12)
+	    {
+	      classes[0] = X86_64_INTEGER_CLASS;
+	      classes[1] = X86_64_INTEGERSI_CLASS;
+	      return 2;
+	    }
+	  else
+	    {
+	      classes[0] = X86_64_INTEGER_CLASS;
+	      classes[1] = X86_64_INTEGER_CLASS;
+	      return 2;
+	    }
+	}
       else
 	abort ();
 

-- 
 Andreas Jaeger, aj@suse.de, http://www.suse.de/~aj
  SuSE Linux AG, Deutschherrnstr. 15-19, 90429 Nürnberg, Germany
   GPG fingerprint = 93A3 365E CE47 B889 DF7F  FED1 389A 563C C272 A126

Attachment: pgp00000.pgp
Description: PGP signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]