Re: Problem in Thread.c

"Sébastien Adam" <[email protected]> Sun, 16 Apr 2006 23:05:23 +0000
Newsgroups gmane.comp.java.vm.sablevm.devel
Message-ID <[email protected]>
--===============0287259411==
Content-Type: multipart/alternative; 
	boundary="----=_Part_7139_13336339.1145228723379"

------=_Part_7139_13336339.1145228723379
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Last news...

When I change the heap size... for example:

In gc_gencopy.c,

we replace:
#define SVM_DEFAULT_GENERATION_SIZE SVM_DEFAULT_FRAME_SIZE * 1024
with:
#define SVM_DEFAULT_GENERATION_SIZE SVM_DEFAULT_FRAME_SIZE * 512

I got the following error:
sablevm: gc_gencopy.c:455: _svmf_copy_object: Assertion `((void *)
obj->lockword) >=3D heap->to_generation->space.start && ((void *)
obj->lockword) < heap->to_generation->alloc.start' failed.

hummmm... this is really bad... It seems to be a problem in my gc :(



On 4/16/06, S=E9bastien Adam <[email protected]> wrote:
>
> > Hints for finding the problem:  You could scan the heap, at the start o=
f
> every GC, before copying any object, and verify that all lockwords do hav=
e
> their least significant bit set.  You should also scan the heap at the en=
d
> of GC, and do the same check.  This would reveal whether the problem is i=
n
> GC or elsewhere.
>
> It is already done...  Everything is ok in the gc.
>
>
> > If not, then you should probably create a "personal tag"[*] by copying
> the version of your sandbox that exhibits the problem, and send us
> another message with the instructions to reproduce the problem.
>
> The following tag has been created.
>
>
> svn://svn.sablevm.org/developers/sadam/tags/lock_gc_bug
>
> To get the segmentation fault, you can use the following:
>
> ./autogen.sh
> ./configure --prefix=3D/usr/ --enable-debugging-features --with-gc=3Dgc
> make install
> java -jar sablecc.jar j14.scc
>
> Where sablecc.jar is at the version 2.18 and j14.scc is the java 1.4gramm=
ar.  Both are found on
> sablecc.org.
>
> Seb
>
> On 4/16/06, Etienne Gagnon <[email protected]> wrote:
>
> > Hi Sebastien,
>
> Can you reproduce this problem in a plain version of SableVM 1.13 (i.e.
> without your new GC stuff)?  If yes, can you submit a bug report at
> http://sablevm.org/bugs.html with the instructions (and any required
> code example) to reproduce the problem?
>
> If not, then you should probably create a "personal tag"[*] by copying
> the version of your sandbox that exhibits the problem, and send us
> another message with the instructions to reproduce the problem.
>
> [*] e.g.
> $ export $SVN=3Dsvn+ssh://svn.sablevm.org/public/developers/sadam
> $ svn cp [-r????]\
>   $SVN/sandbox/[???] $SVN/tags/lock_gc_bug
>
> This will create the following tag for others to see:
>
> svn://svn.sablevm.org/developers/sadam/tags/lock_gc_bug
>
> The idea is that you can then continue changing your sandbox without
> worrying, as others will fetch the "frozen snapshot" of your sandbox
> represented by the tag.
>
> Hints for finding the problem:  You could scan the heap, at the start of
> every GC, before copying any object, and verify that all lockwords do
> have their least significant bit set.  You should also scan the heap at
> the end of GC, and do the same check.  This would reveal whether the
> problem is in GC or elsewhere.
>
> Have fun!
>
> Etienne
>
> S=E9bastien Adam wrote:
> > I developed a new generational gc in SableVM release 1.13.
> >
> > I get a segmentation fault at the last instruction in the following
> > code. This instruction is found at line 1364 in the method
> > _svmf_enter_object_monitor of Thread.c.
> >...
> > I don't work a lot with the Thread code but I don't think the problem i=
s
>
> > in _svmf_enter_object_monitor. Is there somebody that can help me to
> > resolve this problem? Where should I look?
>
> --
> Etienne M. Gagnon, Ph.D.             http://www.info2.uqam.ca/~egagnon/<h=
ttp://www.info2.uqam.ca/%7Eegagnon/>
> SableVM:                                       http://www.sablevm.org/
> SableCC:                                       http://www.sablecc.org/
>
>
>
> _______________________________________________
> SableVM-devel mailing list
> [email protected]
> http://sablevm.org/lists/control/listinfo/sablevm-devel
>
>
>
>
>

------=_Part_7139_13336339.1145228723379
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Last news... <br>
<br>
When I change the heap size... for example:<br>
<br>
In gc_gencopy.c, <br>
<br>
we replace:<br>
#define SVM_DEFAULT_GENERATION_SIZE SVM_DEFAULT_FRAME_SIZE * 1024<br>
with:<br>
#define SVM_DEFAULT_GENERATION_SIZE SVM_DEFAULT_FRAME_SIZE * 512<br><br>
I got the following error:<br>
sablevm: gc_gencopy.c:455: _svmf_copy_object: Assertion `((void *)
obj-&gt;lockword) &gt;=3D heap-&gt;to_generation-&gt;space.start
&amp;&amp; ((void *) obj-&gt;lockword) &lt;
heap-&gt;to_generation-&gt;alloc.start' failed.<br>
<br>
hummmm... this is really bad... It seems to be a problem in my gc :(<br>
<br>
<br>
<br><div><span class=3D"gmail_quote">On 4/16/06, <b class=3D"gmail_senderna=
me">S=E9bastien Adam</b> &lt;<a href=3D"mailto:[email protected]">se=
[email protected]</a>&gt; wrote:</span><blockquote class=3D"gmail_quot=
e" style=3D"border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt =
0.8ex; padding-left: 1ex;">
<div style=3D"direction: ltr;"><span class=3D"q">&gt; Hints for finding the=
 problem:&nbsp;&nbsp;You could scan the heap,
at the start of every GC, before copying any object, and verify that
all lockwords do have their least significant bit set.&nbsp;&nbsp;You
should also scan the heap at the end of GC, and do the same
check.&nbsp;&nbsp;This would reveal whether the problem is in GC or
elsewhere.<br>
<br></span></div><div style=3D"direction: ltr;">
It is already done...&nbsp; Everything is ok in the gc.</div><div style=3D"=
direction: ltr;"><span class=3D"q"><br>
<br>
&gt; If not, then you should probably create a &quot;personal tag&quot;[*] =
by copying<br>
the version of your sandbox that exhibits the problem, and send us<br>
another message with the instructions to reproduce the problem.<br>
<br></span></div><div style=3D"direction: ltr;">
The following tag has been created.</div><div style=3D"direction: ltr;"><sp=
an class=3D"q"><br>
<div style=3D"direction: ltr;"><br>
 svn://svn.sablevm.org/developers/sadam/tags/lock_gc_bug<br>
</div></span></div><div style=3D"direction: ltr;">
<br>
To get the segmentation fault, you can use the following:<br>
<br>./autogen.sh&nbsp;&nbsp;&nbsp;&nbsp; <br>
./configure --prefix=3D/usr/ --enable-debugging-features --with-gc=3Dgc&nbs=
p;&nbsp;&nbsp; <br>
make install<br>
java -jar sablecc.jar j14.scc&nbsp; <br>
<br>
Where sablecc.jar is at the version 2.18 and j14.scc is the java 1.4 gramma=
r.&nbsp; Both are found on <a href=3D"http://sablecc.org" target=3D"_blank"=
 onclick=3D"return top.js.OpenExtLink(window,event,this)">sablecc.org</a>.<=
br>
<br>
Seb<br>
<br><div></div><div style=3D"direction: ltr;"><span class=3D"e" id=3D"q_10a=
a4e8d44791eb9_6"><span class=3D"gmail_quote">On 4/16/06, <b class=3D"gmail_=
sendername">Etienne Gagnon</b> &lt;<a href=3D"mailto:[email protected]" t=
arget=3D"_blank" onclick=3D"return top.js.OpenExtLink(window,event,this)">
[email protected]</a>&gt; wrote:</span></span></div><div style=3D"directi=
on: ltr;"><blockquote class=3D"gmail_quote" style=3D"border-left: 1px solid=
 rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"></block=
quote>
</div><div style=3D"direction: ltr;"><span class=3D"e" id=3D"q_10aa4e8d4479=
1eb9_8">
Hi Sebastien,<br><br>Can you reproduce this problem in a plain version of S=
ableVM 1.13 (i.e.<br>without your new GC stuff)?&nbsp;&nbsp;If yes, can you=
 submit a bug report at<br><a href=3D"http://sablevm.org/bugs.html" target=
=3D"_blank" onclick=3D"return top.js.OpenExtLink(window,event,this)">
http://sablevm.org/bugs.html
</a> with the instructions (and any required<br>code example) to reproduce =
the problem?<br><br>If not, then you should probably create a &quot;persona=
l tag&quot;[*] by copying<br>the version of your sandbox that exhibits the =
problem, and send us
<br>another message with the instructions to reproduce the problem.<br><br>=
[*] e.g.<br>$ export $SVN=3Dsvn+ssh://svn.sablevm.org/public/developers/sad=
am<br>$ svn cp [-r????]\<br>&nbsp;&nbsp;$SVN/sandbox/[???] $SVN/tags/lock_g=
c_bug<br>

<br>This will create the following tag for others to see:<br><br> svn://svn=
.sablevm.org/developers/sadam/tags/lock_gc_bug<br><br>The idea is that you =
can then continue changing your sandbox without<br>worrying, as others will=
 fetch the &quot;frozen snapshot&quot; of your sandbox
<br>represented by the tag.<br><br>Hints for finding the problem:&nbsp;&nbs=
p;You could scan the heap, at the start of<br>every GC, before copying any =
object, and verify that all lockwords do<br>have their least significant bi=
t set.&nbsp;&nbsp;You should also scan the heap at
<br>the end of GC, and do the same check.&nbsp;&nbsp;This would reveal whet=
her the<br>problem is in GC or elsewhere.<br><br>Have fun!<br><br>Etienne<b=
r><br>S=E9bastien Adam wrote:<br>&gt; I developed a new generational gc in =
SableVM release=20
1.13.<br>&gt;<br>&gt; I get a segmentation fault at the last instruction in=
 the following<br>&gt; code. This instruction is found at line 1364 in the =
method<br>&gt; _svmf_enter_object_monitor of Thread.c.<br>&gt;...<br>&gt; I=
 don't work a lot with the Thread code but I don't think the problem is
<br>&gt; in _svmf_enter_object_monitor. Is there somebody that can help me =
to<br>&gt; resolve this problem? Where should I look?<br><br>--<br>Etienne =
M. Gagnon, Ph.D.&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp=
;&nbsp;&nbsp;<a href=3D"http://www.info2.uqam.ca/%7Eegagnon/" target=3D"_bl=
ank" onclick=3D"return top.js.OpenExtLink(window,event,this)">

http://www.info2.uqam.ca/~egagnon/</a><br>SableVM:&nbsp;&nbsp;&nbsp;&nbsp;&=
nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&=
nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href=3D"http://www.sablevm.org/" target=3D"_blank" onclick=3D"return top=
.js.OpenExtLink(window,event,this)">http://www.sablevm.org/</a><br>SableCC:=
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;
<a href=3D"http://www.sablecc.org/" target=3D"_blank" onclick=3D"return top=
.js.OpenExtLink(window,event,this)">http://www.sablecc.org/</a><br><br><br>=
<br></span></div><div style=3D"direction: ltr;">___________________________=
____________________
<br>SableVM-devel mailing list<br><a href=3D"mailto:[email protected]=
rg" target=3D"_blank" onclick=3D"return top.js.OpenExtLink(window,event,thi=
s)">[email protected]
</a><br><a href=3D"http://sablevm.org/lists/control/listinfo/sablevm-devel"=
 target=3D"_blank" onclick=3D"return top.js.OpenExtLink(window,event,this)"=
>http://sablevm.org/lists/control/listinfo/sablevm-devel</a><br><br><br><br=
>
</div><br>

</div></blockquote></div><br>

------=_Part_7139_13336339.1145228723379--


--===============0287259411==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
SableVM-devel mailing list
[email protected]
http://sablevm.org/lists/control/listinfo/sablevm-devel

--===============0287259411==--