info-gnuprologjava
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Info-gnuprologjava] Deadlocks.


From: Daniel Thomas
Subject: Re: [Info-gnuprologjava] Deadlocks.
Date: Mon, 21 Mar 2011 20:20:58 +0000

Hello,

I am aware of findbugs and I have previously used sonar which
incorporates findbugs to try and help find the deadlock problems but
though it helped fix lots of bad code and some bugs it didn't identify
the particular problem of interest. There is still some mileage in using
it to fix some of the remaining poor code.

I hope your working through the code goes well, feel free to ask any
questions you have and please send in any patches.

Daniel

On Tue, 2011-03-22 at 00:31 +0530, Jatin Puri wrote:
> Hello
> 
> Thanks for the detailed response.
> Well regarding to check if the current classes are Thread-Safe, there
> is an awesome piece of software called FindBugs.
> FindBugs is an open source program which looks for bugs in Java code.
> It uses static analysis to identify hundreds of different potential
> types of errors in Java programs. FindBugs operates on Java
> bytecode,rather than source code.
> 
> When I ran on some of the code snippets, the output showed some what
> it believes to be bugs. The attached file is the output.
> (Although I did not add the necessary class to the input which shall
> check for Dead Locks, but from personal experience find it to be very
> accurate)
> But I think I would follow a traditional way of going through the code
> directly hence will accompany me to understand the API in great
> detail. On the way will try making API more clearer. To check for
> bugs, FindBugs is always there.
> Further will surely go through the links you had given, should again
> be useful.
> 
> Best Regards,
> Jatin Puri
> 
> 
> On Mon, Mar 21, 2011 at 11:32 PM, Daniel Thomas <address@hidden>
> wrote:
>         Hello,
>         
>         On Mon, 2011-03-21 at 12:30 +0530, Jatin Puri wrote:
>         > Hello,
>         >
>         > I was going through the savannah bug tracker, and it seems
>         there have
>         > been cases reported of dead-locks.
>         
>         
>         Yes when I was testing for concurrency flaws I found
>         https://savannah.gnu.org/bugs/?30630 this was found by running
>         the inria
>         tests in parallel with 4 threads.
>         
>         > I started browsing through the code, but the API doesnt much
>         say about
>         > the policies it is performing say for example if a class is
>         Thread
>         > confined, then there is no mention of it. Because if it is
>         obviously
>         > there is no need to make it Thread-safe.
>         
>         
>         Indeed. This is rather irritating, unfortunately the original
>         author did
>         not write much if any API documentation and I haven't
>         documented the
>         basic functionality for everything user facing yet. My current
>         idea for
>         addressing this problem is to use one of the automated means
>         for
>         checking this information through annotations.
>         
> https://www.srcf.ucam.org/~drt24/blog/2010/10/proving-java-terminates-or-runs-forever-avoiding-deadlock-automatically-with-compile-time-checking/
>  contains some of my thoughts on this (though not applied specifically to 
> this problem)
>         
>         > So is there any file or diagram available which explains the
>         process
>         > in brief ?. If not then it will be a time consuming task to
>         understand
>         > the complete library and then sit to solve it.
>         
>         
>         The only documentation that exists it the documentation which
>         I have
>         written. This constitutes the manual
>         http://www.gnu.org/software/gnuprologjava/manual/ and the API
>         documentation (which you have already found). Both are still
>         unfortunately rather lacking in content, particularly from the
>         point of
>         view of development.
>         
>         Fortunately there is someone who knows their way around the
>         code base
>         (me) last year there wasn't anyone. If you have specific
>         questions about
>         how things fit together then please ask me and I will write
>         the answers
>         into the documentation.
>         
>         > Best Regards,
>         > Jatin Puri
>         >
>         > --
>         > Jatin Puri
>         > B.E(Hons) Computer Science
>         > Msc(Hons) Mathematics
>         > Bits Pilani Goa Campus
>         > India
>         
>         
>         Best Regards,
>         
>         Daniel Thomas
> 
> 
> 
> -- 
> Jatin Puri
> B.E(Hons) Computer Science
> Msc(Hons) Mathematics
> Bits Pilani Goa Campus
> India
> 
> 

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

[Prev in Thread] Current Thread [Next in Thread]