public inbox for java-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Bryce McKinlay <mckinlay@redhat.com>
To: Andrew Haley <aph@redhat.com>
Cc: java-patches@gcc.gnu.org, gcc-patches@gcc.gnu.org
Subject: Re: Calls to built-in functions are not Binary Compatible
Date: Mon, 06 Mar 2006 16:02:00 -0000	[thread overview]
Message-ID: <440C5D06.8030905@redhat.com> (raw)
In-Reply-To: <17417.28490.265576.328548@zapata.pink>

Andrew Haley wrote:
> Bryce McKinlay writes:
>  > Doesn't this disable builtins mechanism entirely when 
>  > -findirect-dispatch is used?
>
> Yes.
>
>  > These builtins improve GCJ's performance significantly on some numeric 
>  > code (scimark, for example).
>
> So you don't use indirect dispatch, surely.
>   
To not use indirect dispatch would make the benchmark rather artificial 
- since most of the code we're running on libgcj these days uses the BC ABI.
>  > Wouldn't it be better to fix whatever problem is causing direct
>  > calls to be generated rather than disabling them completely?
>
> I don't understand your point -- this is the code that is causing
> direct calls to be made.  Built-in functions in gcc either generate
> direct calls or they get replaced by inline code.
>   

Surely it is a bug, rather than a feature of this code, that it is 
causing direct (non-BC) calls to Java functions to be made. Direct calls 
to gcc/libc internal functions or inlining code is another matter.

You could argue that it is not strictly "binary compatible" to inline, 
say, Math.min() - but realistically, the Math.* functions are well 
enough defined that they can always be safely inlined or converted to 
direct OS calls - since they are pure functions, that read only their 
arguments and do not depend on object layout and such.

Bryce

  parent reply	other threads:[~2006-03-06 16:02 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-01 18:29 Andrew Haley
2006-03-01 18:33 ` Andrew Pinski
2006-03-01 18:43   ` Andrew Haley
2006-03-01 22:36   ` Tom Tromey
2006-03-03 22:05 ` Bryce McKinlay
2006-03-04 10:41   ` Andrew Haley
2006-03-04 10:55     ` Andrew Haley
2006-03-06 18:49       ` Tom Tromey
2006-03-06 18:51         ` Andrew Haley
2006-03-06 16:02     ` Bryce McKinlay [this message]
2006-03-06 16:12       ` Andrew Haley
2006-03-06 19:03         ` Bryce McKinlay

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=440C5D06.8030905@redhat.com \
    --to=mckinlay@redhat.com \
    --cc=aph@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=java-patches@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).