Re: kalloc.c and recent gcc's

2005-09-02 Thread Thomas Schwinge
On Thu, Sep 01, 2005 at 01:25:29PM +0200, Alfred M. Szmidt wrote:
>Can we be sure that we don't have to also hook realloc() and
>memalign()?
> 
> I don't think so, check the code for realloc/memalign to be sure, I
> don't have access to it here.

I don't think they're used in the Hurd code; those who originally wrote
(or adapted) kalloc.c would have taken care of that, I suppose.
My question was rather if we can be sure that realloc() or memalign()
aren't used by e.g. printf() or other library functions that
mach-defpager is calling.


Regards,
 Thomas


___
Bug-hurd mailing list
Bug-hurd@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-hurd


Re: cv3 you need it PHÂRRMACY

2005-09-02 Thread Nyala Quiroz



 

Grehop and setings, VISl.T A-PharamacyByMail Save YVE Ove% onarmacy witou CAN SAr 60 your phh us. VaIis Vler meddicatioIium Ciaagra and many othns
___
Bug-hurd mailing list
Bug-hurd@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-hurd


Re: [PATCH] Building the Hurd with gcc-4.0

2005-09-02 Thread Thomas Schwinge
On Fri, Sep 02, 2005 at 12:49:50AM +0200, Thomas Schwinge wrote:
> Hi!
> 
> The attached `hurd_v.s._gcc-4.0.patch' makes the Hurd buildable with
> gcc-4.0.

A fix (to be applied after the above patch) is attached:
`hurd_v.s._gcc-4.0.fixes.patch'
The patch only fixes my previous patch, so no new ChangeLog entry is
needed.

Thanks to Neal Walfield and Peter De Schrijver.


Imo, a similar fix is also needed (additionally to those that Neal
already pointed out and Alfred fixed) for Alfred's patch to make glibc
build with gcc-4.0:
http://sources.redhat.com/ml/libc-alpha/2005-08/msg00018.html>
#v+
- *((integer_t *) t)++ = (integer_t) arg;
+ *(integer_t *) t = (integer_t) arg;
+ t += sizeof (integer_t);
 #else
- *((integer_t *) p)++ = (integer_t) arg;
+ *(integer_t *) p = (integer_t) arg;
+ p += sizeof (integer_t);
#v-
... should rather be...
#v+
- *((integer_t *) t)++ = (integer_t) arg;
+ *(integer_t *) t = (integer_t) arg;
+ t = (mach_msg_type_t *) ((integer_t *) t + 1);
 #else
- *((integer_t *) p)++ = (integer_t) arg;
+ *(integer_t *) p = (integer_t) arg;
+ p = (void *) ((integer_t *) p + 1);
#v-

Correct?


Regards,
 Thomas
Fri Sep  2 15:22:00 CEST 2005  Thomas Schwinge <[EMAIL PROTECTED]>
  * Make it build with gcc-4.0: Fixes.
diff -rN -u old-hurd-0-branch.1.tmp-1/boot/boot.c 
new-hurd-0-branch.1.tmp-1/boot/boot.c
--- old-hurd-0-branch.1.tmp-1/boot/boot.c   2005-09-03 02:00:26.465879504 
+0200
+++ new-hurd-0-branch.1.tmp-1/boot/boot.c   2005-09-03 02:00:26.495874944 
+0200
@@ -368,16 +368,16 @@
   + (argc + 2) * sizeof (char *) + sizeof (integer_t));
   p = args + ((vm_address_t) arg_pos & (vm_page_size - 1));
   *(int *) p = argc;
-  p += sizeof (int *);
+  p = (char *) ((int *) p + 1);
   for (i = 0; i < argc; i++)
 {
   *(char **) p = argv[i] - strings + (char *) str_start;
-  p += sizeof (char **);
+  p = (char *) ((char **) p + 1);
 }
   *(char **) p = 0;
-  p += sizeof (char **);
+  p = (char *) ((char **) p + 1);
   *(char **) p = 0;
-  p += sizeof (char **);
+  p = (char *) ((char **) p + 1);
   memcpy (p, strings, stringlen);
   bzero (args, (vm_offset_t) arg_pos & (vm_page_size - 1));
   vm_write (task, trunc_page ((vm_offset_t) arg_pos), (vm_address_t) args,

___
Bug-hurd mailing list
Bug-hurd@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-hurd