Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
From: Herbert Valerio Riedel <hvr@hvrlab.ml.org>
To: axp-list@redhat.com
Cc: linux-kernel@vger.rutgers.edu
Subject: getdtablesize() / DU-loader (reason why netscape DU binaries don't work anymore with 2.1.131)
Date: Tue, 8 Dec 1998 16:17:44 +0100 (CET)	[thread overview]
Message-ID: <Pine.LNX.4.04.9812081606060.649-100000@phoenix.twisted.hvrlab.ml.org> (raw)
In-Reply-To: <19981208073537.A24193@xcski.com>

Hi all

consider this:


#include <stdio.h>
#include <unistd.h>

int main(int argc, char *argv[])
{
  int size = getdtablesize();

  printf("getdtablesize() = %i\n", size);

  return 0;
}

output of the above compiled under axp-linux with linux-gcc and run under
2.1.131-ac5:

getdtablesize() = 1024

output of the above compiled under DU4 with DU-gcc and run under
2.1.131-ac5:

getdtablesize() = 1048576 

(I am quite sure although I haven't verified, that the behaviour has
changed since 2.1.130) 

btw: 2.1.131-ac5 was compiled with egcs-1.1.1 and runs fine except for 
that one thing...

----------------------------------------------------------------------

here are the corresponding strace-logs:

execve("./dtable-linux", ["./dtable-linux"], [/* 29 vars */]) = 0
brk(0)                                  = 0x120100a30
open("/etc/ld.so.preload", O_RDONLY)    = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY)      = 4
fstat(4, {st_mode=01, st_size=913129959, ...}) = 0
mmap(0, 4831835312, PROT_READ, 0 /* MAP_??? */, 0, 0) = 0x20000010000
close(4)                                = 0
open("/lib/libc.so.6.1", O_RDONLY)      = 4
mmap(0, 0, PROT_NONE, 0 /* MAP_??? */, 0, 0) = 0x20000016000
munmap(0x20000016000, 8192)             = 0
mmap(0, 8192, PROT_NONE, 0 /* MAP_??? */, 0, 0) = 0x20000110000
mprotect(0x200001d8000, 1153256, PROT_NONE) = 0
mmap(0x200002d0000, 1153256, PROT_NONE, 0 /* MAP_??? */, 0, 0) = 0x200002d0000
mmap(0x200002e8000, 1153256, PROT_NONE, 0 /* MAP_??? */, 0, 0) = 0x200002e8000
close(4)                                = 0
munmap(0x20000010000, 17665)            = 0
personality(PER_LINUX)                  = 0
osf_getsysinfo(0x2d, 0x11ffffaf0, 0x11ffffb58, 0, 0x2) = 0
osf_setsysinfo(0xe, 0x11ffffaf0, 0x11ffffb58, 0, 0x2) = 0
getxpid()                               = 1055
getrlimit(RLIMIT_NOFILE, {rlim_cur=1024, rlim_max=1024}) = 0
fstat(1, {st_mode=01, st_size=913129959, ...}) = 0
mmap(0, 4831834800, 0x1ffffb58, 0 /* MAP_??? */, 2, 0) = 0x20000010000
ioctl(1, TCGETS, {B38400 opost isig icanon echo ...}) = 0
write(1, "getdtablesize() = 1024 \n", 24) = 24
munmap(0x20000010000, 8192)             = 0
exit(0)                                 = ?

--------------------------------------------------------------

execve("./dtable-du-gcc", ["./dtable-du-gcc"], [/* 29 vars */]) = 0
getpagesize()                           = 0x2000
getpagesize()                           = 0x2000
getrlimit(RLIMIT_DATA, {rlim_cur=RLIM_INFINITY, rlim_max=RLIM_INFINITY}) = 0
mmap(0x3ffc0004000, 4831836648, PROT_NONE, 0 /* MAP_??? */, 0, 0) = 0x3ffc0004000
getrlimit(RLIMIT_DATA, {rlim_cur=RLIM_INFINITY, rlim_max=RLIM_INFINITY}) = 0
mmap(0x3ffc0006000, 4831836648, PROT_NONE, 0 /* MAP_??? */, 0, 0) = 0x3ffc0006000
open("./dtable-du-gcc", O_RDONLY)       = 4
getxuid()                               = 500
getxgid(0x3ffc0002800)                  = 500
getxuid()                               = 500
getxgid(0x3ffc0002800)                  = 500
read(4, "\203\1\21\0\316>m6\0@\0\0\0\0\0\0"..., 2664) = 2664
mmap(0x120000000, 4831834176, 0xa68, 0 /* MAP_??? */, 0, 0) = 0x120000000
mmap(0x140000000, 4831834176, 0xa68, 0 /* MAP_??? */, 0, 0) = 0x140000000
open("/usr/shlib/libc.so", O_RDONLY)    = 5
read(5, "\203\1\23\0\372\341\3373\0\200\22"..., 2664) = 2664
mmap(0x3ff80080000, 4831833920, 0xa68, 0 /* MAP_??? */, 0, 0) = 0x3ff80080000
mmap(0x3ffc0080000, 4831833920, 0xa68, 0 /* MAP_??? */, 0, 0) = 0x3ffc0080000
mmap(0x3ffc0090000, 4831833920, 0xa68, 0 /* MAP_??? */, 0, 0) = 0x3ffc0090000
close(5)                                = 0
stat("/usr/shlib/libc.so", {st_mode=01, st_size=913129995, ...}) = 0
SYS_43(0x120000000, 0x2000, 0x140000000, 0x1a0, 0) = 0
close(4)                                = 0
getpagesize()                           = 0x2000
brk(0x14000e1a0)                        = 0x14000e1a0
getdtablesize()                         = 1048576
ioctl(1, TIOCGETP, 0x11ffff2d8)         = 0
write(1, "getdtablesize() = 1048576 \n", 27) = 27
close(0)                                = 0
close(1)                                = 0
close(2)                                = 0
sigprocmask(SIG_BLOCK, ~[ILL EMT FPE BUS SEGV SYS]) = 0 (old mask [])
exit(0)                                 = ?

--
"The idea that Bill Gates has appeared like a knight in shining armour to
lead all customers out of a mire of  technological chaos neatly ignores the
fact that it was he who, by peddling second-rate technology, led them into
it in the first place." - Douglas Adams, on Windows '95.



      parent reply	other threads:[~1998-12-08 15:24 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-12-08 12:35 jikes Paul Tomblin
1998-12-08  8:09 ` jikes Dan Morrill
1998-12-08 13:55   ` jikes Stephane Casset
1998-12-08 14:50     ` jikes Paul Tomblin
1998-12-08 15:43       ` Where? (was Re: jikes) B. James Phillippe
1998-12-08 11:49         ` Dan Morrill
1998-12-08 16:27         ` Paul Tomblin
1998-12-08 16:31         ` Robin Stephenson
1998-12-08 15:17 ` Herbert Valerio Riedel [this message]
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox