2003-04-04 Elena Zannoni <ezannoni@redhat.com>
authorElena Zannoni <ezannoni@kwikemart.cygnus.com>
Fri, 4 Apr 2003 19:30:49 +0000 (19:30 +0000)
committerElena Zannoni <ezannoni@kwikemart.cygnus.com>
Fri, 4 Apr 2003 19:30:49 +0000 (19:30 +0000)
        * x86-64-tdep.c (x86_64_push_arguments): Handle correctly the
        signed integer case.
        (classify_argument): Handle enumerations and references.

gdb/ChangeLog
gdb/x86-64-tdep.c

index 83cb7018268ebd6ac12c5756868ba1157f133e7e..a2afc12ac487383749388af524a8b2a3e699ad15 100644 (file)
@@ -1,3 +1,9 @@
+2003-04-04  Elena Zannoni  <ezannoni@redhat.com>
+
+        * x86-64-tdep.c (x86_64_push_arguments): Handle correctly the
+        signed integer case.
+        (classify_argument): Handle enumerations and references.
+
 2003-04-04  Andrew Cagney  <cagney@redhat.com>
 
        * frame.c (create_sentinel_frame): Initialize the sentinel frame's
index 5d43e0158198b91ae32e93ce26d33254fa0a5f0a..5b8abf6a571b8bd81beaee9d732b1fd28ecab8c2 100644 (file)
@@ -471,6 +471,8 @@ classify_argument (struct type *type,
          return 2;
        }
       break;
+    case TYPE_CODE_ENUM:
+    case TYPE_CODE_REF:
     case TYPE_CODE_INT:
     case TYPE_CODE_PTR:
       switch (bytes)
@@ -700,11 +702,17 @@ x86_64_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
                  intreg += 2;
                  break;
                case X86_64_INTEGERSI_CLASS:
-                 deprecated_write_register_gen (int_parameter_registers[intreg / 2],
-                                                VALUE_CONTENTS_ALL (args[i]) + offset);
-                 offset += 8;
-                 intreg++;
-                 break;
+                 {
+                   LONGEST num
+                     = extract_signed_integer (VALUE_CONTENTS_ALL (args[i])
+                                               + offset, 4);
+                   regcache_raw_write_signed (current_regcache,
+                                              int_parameter_registers[intreg / 2],                                           num);
+
+                   offset += 8;
+                   intreg++;
+                   break;
+                 }
                case X86_64_SSEDF_CLASS:
                case X86_64_SSESF_CLASS:
                case X86_64_SSE_CLASS: