mailing list of musl libc
 help / color / mirror / code / Atom feed
From: Ivan Kanakarakis <ivan.kanak@gmail.com>
To: musl@lists.openwall.com
Subject: Re: Fix for fields in utmp
Date: Tue, 26 Feb 2013 12:34:43 +0200	[thread overview]
Message-ID: <CAJnvVWWJ=Bpd9Jydb6q=VXL7rs841eqbDMPvzD-+CGGVSbu+YA@mail.gmail.com> (raw)
In-Reply-To: <20130226092227.GE6181@port70.net>

[-- Attachment #1: Type: text/plain, Size: 3508 bytes --]

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@port70.net> wrote:
> * Rich Felker <dalias@aerifal.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

[-- Attachment #2: report.txt --]
[-- Type: text/plain, Size: 2484 bytes --]

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

  reply	other threads:[~2013-02-26 10:34 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-20 18:23 Chris Spiegel
2013-02-20 18:49 ` Szabolcs Nagy
2013-02-21  0:56   ` Rich Felker
2013-02-26  6:49     ` Rich Felker
2013-02-26  9:22       ` Szabolcs Nagy
2013-02-26 10:34         ` Ivan Kanakarakis [this message]
2013-02-26 20:21           ` Szabolcs Nagy
2013-02-26 23:33             ` Rich Felker
2013-03-02 23:29               ` Szabolcs Nagy
2013-03-04 22:06                 ` Rich Felker
2013-04-12 11:23                   ` Ivan Kanakarakis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJnvVWWJ=Bpd9Jydb6q=VXL7rs841eqbDMPvzD-+CGGVSbu+YA@mail.gmail.com' \
    --to=ivan.kanak@gmail.com \
    --cc=musl@lists.openwall.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).