* [Bug java/19295] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
@ 2005-01-06 19:15 ` overholt at redhat dot com
2005-01-06 20:00 ` [Bug java/19295] [4.0 regression] " tromey at gcc dot gnu dot org
` (8 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: overholt at redhat dot com @ 2005-01-06 19:15 UTC (permalink / raw)
To: java-prs
------- Additional Comments From overholt at redhat dot com 2005-01-06 19:15 -------
Created an attachment (id=7884)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=7884&action=view)
test case
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
2005-01-06 19:15 ` [Bug java/19295] " overholt at redhat dot com
@ 2005-01-06 20:00 ` tromey at gcc dot gnu dot org
2005-01-06 20:04 ` pinskia at gcc dot gnu dot org
` (7 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: tromey at gcc dot gnu dot org @ 2005-01-06 20:00 UTC (permalink / raw)
To: java-prs
------- Additional Comments From tromey at gcc dot gnu dot org 2005-01-06 20:00 -------
I've investigated this a little.
The bug does not occur with gcj 3.3 or 3.4, so I am marking
it as a regression.
The trouble starts in fold_single_bit_test(). Here we transform
"tagBits & IsArrayType" into a new expression involving some
casts and an RSHIFT_EXPR.
The immediate problem seems to be that one of the casts looks like:
<nop_expr <unsigned long> <long>>
In this situation jcf-write emits i2l, which is incorrect.
Overall this is another instance of "we shouldn't use fold in gcj".
One possible fix might be to make fold_single_bit_test conditional
on the can_use_bit_fields_p langhook.
Another might be to change jcf-write to handle this sort of cast,
though I wonder if this can really be done safely.
--
What |Removed |Added
----------------------------------------------------------------------------
Summary|Incorrect bytecode produced |[4.0 regression] Incorrect
|for bitwise AND |bytecode produced for
| |bitwise AND
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
2005-01-06 19:15 ` [Bug java/19295] " overholt at redhat dot com
2005-01-06 20:00 ` [Bug java/19295] [4.0 regression] " tromey at gcc dot gnu dot org
@ 2005-01-06 20:04 ` pinskia at gcc dot gnu dot org
2005-01-19 18:52 ` mmitchel at gcc dot gnu dot org
` (6 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-01-06 20:04 UTC (permalink / raw)
To: java-prs
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Keywords| |wrong-code
Last reconfirmed|0000-00-00 00:00:00 |2005-01-06 20:04:12
date| |
Target Milestone|--- |4.0.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
` (2 preceding siblings ...)
2005-01-06 20:04 ` pinskia at gcc dot gnu dot org
@ 2005-01-19 18:52 ` mmitchel at gcc dot gnu dot org
2005-01-19 19:24 ` steven at gcc dot gnu dot org
` (5 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2005-01-19 18:52 UTC (permalink / raw)
To: java-prs
------- Additional Comments From mmitchel at gcc dot gnu dot org 2005-01-19 18:52 -------
Ada and Java bugs are not release-critical; therefore, I've removed the target
milsetone.
--
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.0.0 |---
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
` (3 preceding siblings ...)
2005-01-19 18:52 ` mmitchel at gcc dot gnu dot org
@ 2005-01-19 19:24 ` steven at gcc dot gnu dot org
2005-01-19 22:37 ` tromey at gcc dot gnu dot org
` (4 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: steven at gcc dot gnu dot org @ 2005-01-19 19:24 UTC (permalink / raw)
To: java-prs
------- Additional Comments From steven at gcc dot gnu dot org 2005-01-19 19:24 -------
Mark, can we keep known wrong-code bugs targeted for 4.0 please? Java/Ada
or other languages shouldn't make a difference for wrong code bugs. They
are the most serious kind we have.
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |mark at codesourcery dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
` (4 preceding siblings ...)
2005-01-19 19:24 ` steven at gcc dot gnu dot org
@ 2005-01-19 22:37 ` tromey at gcc dot gnu dot org
2005-01-19 22:44 ` mark at codesourcery dot com
` (3 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: tromey at gcc dot gnu dot org @ 2005-01-19 22:37 UTC (permalink / raw)
To: java-prs
------- Additional Comments From tromey at gcc dot gnu dot org 2005-01-19 22:37 -------
I'm working on this.
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |tromey at gcc dot gnu dot
|dot org |org
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
` (5 preceding siblings ...)
2005-01-19 22:37 ` tromey at gcc dot gnu dot org
@ 2005-01-19 22:44 ` mark at codesourcery dot com
2005-01-24 14:34 ` cvs-commit at gcc dot gnu dot org
` (2 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: mark at codesourcery dot com @ 2005-01-19 22:44 UTC (permalink / raw)
To: java-prs
------- Additional Comments From mark at codesourcery dot com 2005-01-19 22:44 -------
Subject: Re: [4.0 regression] Incorrect bytecode produced
for bitwise AND
steven at gcc dot gnu dot org wrote:
> ------- Additional Comments From steven at gcc dot gnu dot org 2005-01-19 19:24 -------
> Mark, can we keep known wrong-code bugs targeted for 4.0 please? Java/Ada
> or other languages shouldn't make a difference for wrong code bugs. They
> are the most serious kind we have.
I'm changing things so that only release-blockers have the 4.0 target.
Java bugs are never release-blockers. I'm writing up an email about
this which I hope to send out today.
Thanks,
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
` (6 preceding siblings ...)
2005-01-19 22:44 ` mark at codesourcery dot com
@ 2005-01-24 14:34 ` cvs-commit at gcc dot gnu dot org
2005-01-24 14:41 ` pinskia at gcc dot gnu dot org
2005-02-11 16:35 ` overholt at redhat dot com
9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2005-01-24 14:34 UTC (permalink / raw)
To: java-prs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-01-24 14:34 -------
Subject: Bug 19295
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: sayle@gcc.gnu.org 2005-01-24 14:34:20
Modified files:
gcc/java : ChangeLog jcf-write.c
libjava : ChangeLog
Added files:
libjava/testsuite/libjava.compile: PR19295.java
Log message:
PR java/19295
* jcf-write.c (generate_bytecode_insns): Conversions between
integer types of the same precision shouldn't generate widening
or narrowing conversion bytecodes.
* testsuite/libjava.compile/PR19295.java: New test case.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/java/ChangeLog.diff?cvsroot=gcc&r1=1.1532&r2=1.1533
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/java/jcf-write.c.diff?cvsroot=gcc&r1=1.159&r2=1.160
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libjava/ChangeLog.diff?cvsroot=gcc&r1=1.3292&r2=1.3293
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libjava/testsuite/libjava.compile/PR19295.java.diff?cvsroot=gcc&r1=NONE&r2=1.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
` (7 preceding siblings ...)
2005-01-24 14:34 ` cvs-commit at gcc dot gnu dot org
@ 2005-01-24 14:41 ` pinskia at gcc dot gnu dot org
2005-02-11 16:35 ` overholt at redhat dot com
9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-01-24 14:41 UTC (permalink / raw)
To: java-prs
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-01-24 14:41 -------
Fixed.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.0.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug java/19295] [4.0 regression] Incorrect bytecode produced for bitwise AND
2005-01-06 19:14 [Bug java/19295] New: Incorrect bytecode produced for bitwise AND overholt at redhat dot com
` (8 preceding siblings ...)
2005-01-24 14:41 ` pinskia at gcc dot gnu dot org
@ 2005-02-11 16:35 ` overholt at redhat dot com
9 siblings, 0 replies; 11+ messages in thread
From: overholt at redhat dot com @ 2005-02-11 16:35 UTC (permalink / raw)
To: java-prs
------- Additional Comments From overholt at redhat dot com 2005-02-10 23:46 -------
Verified.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |VERIFIED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19295
^ permalink raw reply [flat|nested] 11+ messages in thread