This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PR16867: Fix a long standing DCE bug


On Thu, 2004-08-12 at 10:49, Tom Tromey wrote:

> Unless someone is going to fix this immediately, could you file a PR
> for it?
> 
There are two places in Java where pure builtins are not being marked as
such.  One is in decl.c:java_init_decl_processing, the other is in
builtins.c:initialize_builtins.

The C front end has an attribute machinery that sets the pure attribute
and side-effects for builtins.  But Java uses its own thing, and it
doesn't even seems to set TREE_SIDE_EFFECTS correctly.  Attribute
handling is pretty inconsistent.

I'm tempted to set DECL_IS_PURE on the whole lot of them, but I don't
think that's always correct (the C front end checks whether we're using
trapping math and what not).

I think I will defer this to a Java person.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17007

I attached the verification patch to the PR.


Thanks.  Diego.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]