Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJnvVWWJ=Bpd9Jydb6q=VXL7rs841eqbDMPvzD-+CGGVSbu+YA@mail.gmail.com>
Date: Tue, 26 Feb 2013 12:34:43 +0200
From: Ivan Kanakarakis <ivan.kanak@...il.com>
To: musl@...ts.openwall.com
Subject: Re: Fix for fields in utmp

here is the output from musl-tables' sizeof test (also attached).
I had to comment out 'elf_fpxregset_t' to make it build.
this is run with latest musl from git (HEAD e201d82)


Linux suicidemachine 3.7.5-1-ARCH #1 SMP PREEMPT Mon Jan 28 10:03:32
CET 2013 x86_64 GNU/Linux
----------------------------------
diff --git a/sizeof.c b/sizeof.c
index f334769..47a7790 100644
--- a/sizeof.c
+++ b/sizeof.c
@@ -252,7 +252,7 @@ p(div_t)
 p(double)
 p(double_t)
 p(elf_fpregset_t)
-p(elf_fpxregset_t)
+// FIXME p(elf_fpxregset_t)
 p(elf_greg_t)
 p(elf_gregset_t)
 p(epoll_data_t)
@@ -551,7 +551,7 @@ p(struct ucred)
 p(struct udphdr)
 p(struct user)
 p(struct user_fpregs_struct)
-p(struct user_fpxregs_struct)
+// FIXME p(struct user_fpxregs_struct)
 p(struct user_regs_struct)
 p(struct utimbuf)
 p(struct utmpx)
----------------------------------
./sizeof-glibc >data/glibc.sizeof
./sizeof-musl >data/musl.sizeof
diff -U1 data/glibc.sizeof data/musl.sizeof >data/sizeof.diff || true
----------------------------------
--- data/glibc.sizeof 2013-02-26 12:27:48.112569344 +0200
+++ data/musl.sizeof 2013-02-26 12:27:48.119236080 +0200
@@ -90,3 +90,3 @@
 float 4
-float_t 4
+float_t 8
 fpos_t 16
@@ -112,4 +112,4 @@
 int8_t 1
-int_fast16_t 8
-int_fast32_t 8
+int_fast16_t 4
+int_fast32_t 4
 int_fast64_t 8
@@ -122,3 +122,3 @@
 intptr_t 8
-jmp_buf 200
+jmp_buf 64
 key_t 4
@@ -181,6 +181,6 @@
 quad_t 8
-regex_t 64
+regex_t 56
 register_t 8
-regmatch_t 8
-regoff_t 4
+regmatch_t 16
+regoff_t 8
 res_state 8
@@ -196,3 +196,3 @@
 sighandler_t 8
-siginfo_t 128
+siginfo_t 136
 sigjmp_buf 200
@@ -215,3 +215,3 @@
 struct ar_hdr 60
-struct arpd_request 40
+struct arpd_request 28
 struct arphdr 8
@@ -222,3 +222,3 @@
 struct cmsghdr 16
-struct crypt_data 131232
+struct crypt_data 260
 struct dirent 280
@@ -282,3 +282,3 @@
 struct itimerval 32
-struct lastlog 292
+struct lastlog 296
 struct lconv 96
@@ -312,3 +312,3 @@
 struct ns_tsig_key 2072
-struct ntptimeval 72
+struct ntptimeval 32
 struct option 32
@@ -326,4 +326,4 @@
 struct rtentry 120
-struct rusage 144
-struct sched_param 4
+struct rusage 272
+struct sched_param 48
 struct sembuf 6
@@ -348,3 +348,3 @@
 struct sockaddr_ll 20
-struct sockaddr_storage 128
+struct sockaddr_storage 136
 struct sockaddr_un 110
@@ -361,3 +361,3 @@
 struct strrecvfd 20
-struct sysinfo 112
+struct sysinfo 368
 struct termios 60
@@ -376,3 +376,3 @@
 struct utimbuf 16
-struct utmpx 384
+struct utmpx 400
 struct utsname 390
@@ -399,4 +399,4 @@
 uint8_t 1
-uint_fast16_t 8
-uint_fast32_t 8
+uint_fast16_t 4
+uint_fast32_t 4
 uint_fast64_t 8
@@ -416,4 +416,4 @@
 wchar_t 4
-wctrans_t 8
-wctype_t 8
+wctrans_t 4
+wctype_t 4
 wint_t 4



On 26 February 2013 11:22, Szabolcs Nagy <nsz@...t70.net> wrote:
> * Rich Felker <dalias@...ifal.cx> [2013-02-26 01:49:29 -0500]:
>> On Wed, Feb 20, 2013 at 07:56:35PM -0500, Rich Felker wrote:
>> > On Wed, Feb 20, 2013 at 07:49:37PM +0100, Szabolcs Nagy wrote:
>> > > and the 64bit abi is different on musl
>> > > (see ut_session and ut_tv)
>> >
>> > That should be fixed. Since it's all stubs, I don't think ABI is a big
>> > issue here.
>>
>> Can you elaborate on what needs to be changed here?
>>
>
> from the code it seemed they have ifdefs for 64bit
>
> i think someone should run
>
> http://nsz.repo.hu/git/?p=musl-tables;a=blob;f=sizeof.c
>
> on x86_64 with glibc and musl and report back the
> outputs (you can git clone and make sizeof)
> (it may be useful to do this other archs as well)



--
Ivan c00kiemon5ter V Kanakarakis  >:3

View attachment "report.txt" of type "text/plain" (2484 bytes)

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.