I'm running into an (almost?) infinite loop when running some of our tests under the exec utility on Linux (in a 12D build with gcc 3.4.6 on Red Hat Advanced Server 4, I haven't tried other configurations). The initial output of strace for one of the tests, 21.cwchar, is in the attached file. The test by itself runs fine to completion and doesn't produce any unusual output (no NULs).
Andrew, when you have a chance, can you take a look at it? If that's not going to be soon let me know if I should open an issue. Martin
execve("./run", ["run", "./21.cwchar"], [/* 35 vars */]) = 0 uname({sys="Linux", node="basari", ...}) = 0 brk(0) = 0x508000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2a95556000 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory) open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/tls/x86_64/libstd12D.so", O_RDONLY) = -1 ENOENT (No such file or directory) stat("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/tls/x86_64", 0x7fbfffec80) = -1 ENOENT (No such file or directory) open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/tls/libstd12D.so", O_RDONLY) = -1 ENOENT (No such file or directory) stat("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/tls", 0x7fbfffec80) = -1 ENOENT (No such file or directory) open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/x86_64/libstd12D.so", O_RDONLY) = -1 ENOENT (No such file or directory) stat("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/x86_64", 0x7fbfffec80) = -1 ENOENT (No such file or directory) open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/libstd12D.so", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\220\360"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=1019755, ...}) = 0 mmap(NULL, 1945424, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2a95557000 mprotect(0x2a95613000, 1175376, PROT_NONE) = 0 mmap(0x2a95713000, 32768, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xbc000) = 0x2a95713000 mmap(0x2a9571b000, 94032, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x2a9571b000 mprotect(0x7fbffff000, 4096, PROT_READ|PROT_WRITE|PROT_EXEC|PROT_GROWSDOWN) = 0 close(3) = 0 open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/libm.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/etc/ld.so.cache", O_RDONLY) = 3 fstat(3, {st_mode=S_IFREG|0644, st_size=190323, ...}) = 0 mmap(NULL, 190323, PROT_READ, MAP_PRIVATE, 3, 0) = 0x2a95732000 close(3) = 0 open("/lib64/tls/libm.so.6", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\360=\200"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=613297, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2a95761000 mmap(0x381b800000, 1593800, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x381b800000 mprotect(0x381b885000, 1049032, PROT_NONE) = 0 mmap(0x381b984000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x84000) = 0x381b984000 close(3) = 0 open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/libpthread.so.0", O_RDONLY) = -1 ENOENT (No such file or directory) open("/lib64/tls/libpthread.so.0", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0 V\0\034"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=106203, ...}) = 0 mmap(0x381c000000, 1131384, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x381c000000 mprotect(0x381c00f000, 1069944, PROT_NONE) = 0 mmap(0x381c10f000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xf000) = 0x381c10f000 mmap(0x381c111000, 13176, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x381c111000 close(3) = 0 open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/libc.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/lib64/tls/libc.so.6", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\240\304"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=1493409, ...}) = 0 mmap(0x381b500000, 2310088, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x381b500000 mprotect(0x381b62b000, 1085384, PROT_NONE) = 0 mmap(0x381b72b000, 20480, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x12b000) = 0x381b72b000 mmap(0x381b730000, 16328, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x381b730000 close(3) = 0 open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/libgcc_s.so.1", O_RDONLY) = -1 ENOENT (No such file or directory) open("/build/sebor/stdcxx-gcc-3.4.6_3-12D/lib/libgcc_s.so.1", O_RDONLY) = -1 ENOENT (No such file or directory) open("/lib64/libgcc_s.so.1", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>[EMAIL PROTECTED]"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=47496, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2a95762000 mmap(0x381dc00000, 1091904, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x381dc00000 mprotect(0x381dc0b000, 1046848, PROT_NONE) = 0 mmap(0x381dd0a000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xa000) = 0x381dd0a000 close(3) = 0 mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2a95763000 mprotect(0x381b72b000, 8192, PROT_READ) = 0 arch_prctl(ARCH_SET_FS, 0x2a957646a0) = 0 munmap(0x2a95732000, 190323) = 0 set_tid_address(0x2a95764730) = 16606 rt_sigaction(SIGRTMIN, {0x381c005190, [], SA_RESTORER|SA_SIGINFO, 0x381c00c430}, NULL, 8) = 0 rt_sigaction(SIGRT_1, {0x381c005210, [], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x381c00c430}, NULL, 8) = 0 rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0 getrlimit(RLIMIT_STACK, {rlim_cur=10240*1024, rlim_max=RLIM_INFINITY}) = 0 _sysctl({{CTL_KERN, KERN_VERSION}, 2, 0x7fbffff4c0, 35, (nil), 0}) = 0 brk(0) = 0x508000 brk(0x529000) = 0x529000 fstat(1, {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2a95732000 write(1, "NAME STATUS"..., 110NAME STATUS WARN ASSERTS FAILED PERCNT USER SYS REAL 21.cwchar ) = 110 open("./21.cwchar.log", O_RDONLY) = -1 ENOENT (No such file or directory) open("./21.cwchar.o.log", O_RDONLY) = -1 ENOENT (No such file or directory) stat("./21.cwchar", {st_mode=S_IFREG|0755, st_size=168826, ...}) = 0 clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x2a95764730) = 16607 times({tms_utime=0, tms_stime=0, tms_cutime=0, tms_cstime=0}) = 559762786 rt_sigaction(SIGALRM, {0x403f00, [], SA_RESTORER, 0x381c00c430}, NULL, 8) = 0 rt_sigaction(SIGHUP, {0x403f20, [], SA_RESTORER, 0x381c00c430}, NULL, 8) = 0 rt_sigaction(SIGINT, {0x403f20, [], SA_RESTORER, 0x381c00c430}, NULL, 8) = 0 rt_sigaction(SIGQUIT, {0x403f20, [], SA_RESTORER, 0x381c00c430}, NULL, 8) = 0 rt_sigaction(SIGTERM, {0x403f20, [], SA_RESTORER, 0x381c00c430}, NULL, 8) = 0 alarm(10) = 0 wait4(16607, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], WSTOPPED|WCONTINUED, NULL) = 16607 --- SIGCHLD (Child exited) @ 0 (0) --- alarm(0) = 10 kill(4294950689, SIGHUP) = -1 ESRCH (No such process) times({tms_utime=0, tms_stime=0, tms_cutime=0, tms_cstime=0}) = 559762787 open("./21.cwchar.out", O_RDONLY) = 3 fstat(3, {st_mode=S_IFREG|0644, st_size=182890591197, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2a95733000 read(3, "# INFO (S1) (10 lines):\n# TEXT: "..., 4096) = 4096 read(3, "ed return type const wchar_t*, g"..., 4096) = 4096 read(3, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096) = 4096 read(3, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096) = 4096 read(3, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096) = 4096 [...repeats indefinitely...]