probable bug in IncopatMask.java

View: New views
2 Messages — Rating Filter:   Alert me  

probable bug in IncopatMask.java

by Dieter von Holten :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Hi folks,

after updating my local source-folders with the latest updates from central repository
i browsed through some of the deltas and found a suspect piece of code:
starting from line 196 some 'dif' is computed : why is an and-expression ( & ) used to
compute something for an IOR-bitop ?
Maybe someone closer to the function of this might have a look.

greetings
dieter von holten

_______________________________________________
Findbugs-discuss mailing list
Findbugs-discuss@...
https://mailman.cs.umd.edu/mailman/listinfo/findbugs-discuss

Re: probable bug in IncopatMask.java

by Bill Pugh :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I think the code is correct. You don't have a test case showing a problem due you?

The issue is a computation of the form

(exp | A) ?= B

We want to find out if there are any bits set in A but clear in B. If so, the two expressions will never be equal.

The expression for checking that is to see if A & ~B != 0.

Bill

On May 22, 2008, at 6:12 AM, info@... wrote:


Hi folks,

after updating my local source-folders with the latest updates from central repository
i browsed through some of the deltas and found a suspect piece of code:
starting from line 196 some 'dif' is computed : why is an and-expression ( & ) used to
compute something for an IOR-bitop ?
Maybe someone closer to the function of this might have a look.

greetings
dieter von holten
_______________________________________________
Findbugs-discuss mailing list
Findbugs-discuss@...
https://mailman.cs.umd.edu/mailman/listinfo/findbugs-discuss


_______________________________________________
Findbugs-discuss mailing list
Findbugs-discuss@...
https://mailman.cs.umd.edu/mailman/listinfo/findbugs-discuss
LightInTheBox - Buy quality products at wholesale price