public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* Re: java/7095: GCJ built multithreaded program keeps creating zombies
@ 2002-12-18 15:12 tromey
  0 siblings, 0 replies; 2+ messages in thread
From: tromey @ 2002-12-18 15:12 UTC (permalink / raw)
  To: aeby, gcc-bugs, gcc-prs, java-prs, nobody

Synopsis: GCJ built multithreaded program keeps creating zombies

State-Changed-From-To: open->analyzed
State-Changed-By: tromey
State-Changed-When: Wed Dec 18 15:12:05 2002
State-Changed-Why:
    This is most likely a problem with glibc or the kernel.
    Offhand I don't see how libgcj could cause this problem.
    We pretty much leave low-level thread stuff up to the
    underlying platform.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=7095


^ permalink raw reply	[flat|nested] 2+ messages in thread

* java/7095: GCJ built multithreaded program keeps creating zombies
@ 2002-06-21  6:06 aeby
  0 siblings, 0 replies; 2+ messages in thread
From: aeby @ 2002-06-21  6:06 UTC (permalink / raw)
  To: gcc-gnats


>Number:         7095
>Category:       java
>Synopsis:       GCJ built multithreaded program keeps creating zombies
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          support
>Submitter-Id:   net
>Arrival-Date:   Fri Jun 21 05:56:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Thomas Aeby
>Release:        unknown-1.0
>Organization:
>Environment:
RedHat 7.2, Linux 2.4.7, glibc 2.2.4+linuxthreads, 
GCC 3.1 (POSIX threads enabled)
>Description:
I'm trying to use GCJ in order to compile some Java classes
into native binaries. While this works great there is still
one problem left I have not been able to solve: A program
creating (many) sub-threads will leave this sub-threads as
zombie processes when they die. This is reproducible using
a very small sample program (as attached here). 

The problem does not necessarily occur immediately after
starting the binary, sometimes a program may run as expected
for a few hours, then starts creating zombies (and from that
time on each terminating thread will end up as a zombie, as
far as I can see), sometimes the "zombie creation" starts
immediately. The program still works, thus the running
threads are not affected (well, at least until the process
table overflows).

Since I am not sure if this is really a bug (why would
nobody else have reported it, then?) or just some
misconfiguration in my runtime environment I declared this
request be a support request. 
>How-To-Repeat:
Compile the attached sample code with

  gcj -o test --main=test test.java

and run the so-created binary until you get a number of
zombies (this might take a few hours!)
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="test.java"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="test.java"

cHVibGljIGNsYXNzIHRlc3QgewogICAgCiAgICBwcml2YXRlIGNsYXNzIG15dGhyZWFkIGV4dGVu
ZHMgVGhyZWFkIHsKICAgICAgICBwdWJsaWMgbXl0aHJlYWQoKSB7CgkgICAgU3lzdGVtLm91dC5w
cmludGxuKCAic3RhcnRpbmcgIiArIGdldE5hbWUoKSApOwoJfQoKCXByb3RlY3RlZCB2b2lkIGZp
bmFsaXplKCkgewoJICAgIFN5c3RlbS5vdXQucHJpbnRsbiggImZpbmFsaXppbmcgIiArIGdldE5h
bWUoKSApOwoJfQoKCXB1YmxpYyB2b2lkIHJ1bigpIHsKCSAgICBTeXN0ZW0ub3V0LnByaW50bG4o
ICJqdXN0IGRvaW5nIHNvbWV0aGluZyIgKTsKCX0KICAgIH0KCiAgICBwdWJsaWMgc3RhdGljIHZv
aWQgbWFpbiggU3RyaW5nIGFyZ3NbXSApIHsKCXdoaWxlKCB0cnVlICkgewoJICAgIFRocmVhZCB0
MSA9IG5ldyBteXRocmVhZCgpOwoJICAgIFRocmVhZCB0MiA9IG5ldyBteXRocmVhZCgpOwoJICAg
IHQxLnN0YXJ0KCk7CgkgICAgdDIuc3RhcnQoKTsKCSAgICB0cnkgewoJICAgICAgICBUaHJlYWQu
c2xlZXAoIDIwMDAgKTsKCSAgICB9CgkgICAgY2F0Y2goIEV4Y2VwdGlvbiBlICkge30KCSAgICB0
cnkgewoJICAgICAgICB0MS5qb2luKCk7CgkgICAgfQoJICAgIGNhdGNoKCBFeGNlcHRpb24gZSAp
IHsgU3lzdGVtLm91dC5wcmludGxuKCBlICk7fQoJICAgIHRyeSB7CgkgICAgICAgIHQyLmpvaW4o
KTsKCSAgICB9CgkgICAgY2F0Y2goIEV4Y2VwdGlvbiBlICkgeyBTeXN0ZW0ub3V0LnByaW50bG4o
IGUgKTt9CgkgICAgUnVudGltZS5nZXRSdW50aW1lKCkuZ2MoKTsKCX0KICAgIH0KfTsK


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-12-18 23:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-18 15:12 java/7095: GCJ built multithreaded program keeps creating zombies tromey
  -- strict thread matches above, loose matches on Subject: below --
2002-06-21  6:06 aeby

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 read-only IMAP folder(s) and NNTP newsgroup(s).