Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #3857

Re: JNA performance

From Jim Janney <jjanney@shell.xmission.com>
Newsgroups comp.lang.java.programmer
Subject Re: JNA performance
Date 2011-05-09 08:54 -0600
Organization As little as possible
Message-ID <2psjsnncv6.fsf@shell.xmission.com> (permalink)
References <tqmdnUiqqro_tlvQnZ2dnUVZ_tmdnZ2d@westnet.com.au>

Show all headers | View raw


"Qu0ll" <Qu0llSixFour@gmail.com> writes:

> I am about to do some Java programming involving native libraries so
> can anyone comment on their experiences with the performance of JNA?
> I note the following (somewhat concerning) statement from the JNA
> website:
>
> "While some attention is paid to performance, correctness and ease of
> use take priority."
>
> I guess there's little point in using it if it sucks performance-wise
> even if it is "easy to use"!  I have never used JNI either but it
> looks not so "easy to use" (i.e. requires some C programming).

I haven't tried JNA -- it either didn't exist or I didn't know about it
when I needed it -- but it looks attractive.  I would start with JNA and
then decide what to do if performance turns out to be a problem.

JNI depends very much on the size of your project.  If you're only
calling a few functions it isn't too bad, but there's a lot of
boilerplate code needed, which is easy to get wrong and hard to read.
For larger projects SWIG does a decent job of generating code
automatically.

-- 
Jim Janney

Back to comp.lang.java.programmer | Previous | NextPrevious in thread | Find similar


Thread

JNA performance "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-08 15:35 +1000
  Re: JNA performance Knute Johnson <nospam@knutejohnson.com> - 2011-05-07 22:48 -0700
    Re: JNA performance "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-08 16:03 +1000
      Re: JNA performance Knute Johnson <nospam@knutejohnson.com> - 2011-05-08 09:54 -0700
    Re: JNA performance Steve Sobol <sjsobol@JustThe.net> - 2011-05-08 13:26 -0700
      Re: JNA performance "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-09 08:44 +1000
        Re: JNA performance Jeff Higgins <jeff@invalid.invalid> - 2011-05-08 21:17 -0400
        Re: JNA performance Jeff Higgins <jeff@invalid.invalid> - 2011-05-08 21:20 -0400
          Re: JNA performance Jeff Higgins <jeff@invalid.invalid> - 2011-05-08 21:24 -0400
            Re: JNA performance "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-09 13:39 +1000
              Re: JNA performance Steve Sobol <sjsobol@JustThe.net> - 2011-05-08 21:54 -0700
                Re: JNA performance "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-09 15:47 +1000
                Re: JNA performance Steve Sobol <sjsobol@JustThe.net> - 2011-05-08 23:26 -0700
                Re: JNA performance "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-09 17:07 +1000
                Re: JNA performance Steve Sobol <sjsobol@JustThe.net> - 2011-05-10 12:44 -0700
        Re: JNA performance Tom Anderson <twic@urchin.earth.li> - 2011-05-09 18:21 +0100
          Re: JNA performance Steve Sobol <sjsobol@JustThe.net> - 2011-05-09 13:05 -0700
            Re: JNA performance Tom Anderson <twic@urchin.earth.li> - 2011-05-09 21:09 +0100
              Re: JNA performance Steve Sobol <sjsobol@JustThe.net> - 2011-05-09 17:58 -0700
  Re: JNA performance Roedy Green <see_website@mindprod.com.invalid> - 2011-05-07 23:25 -0700
    Re: JNA performance "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-08 16:32 +1000
    Re: JNA performance Steve Sobol <sjsobol@JustThe.net> - 2011-05-08 13:27 -0700
  Re: JNA performance Lew <noone@lewscanon.com> - 2011-05-08 07:58 -0400
    Re: JNA performance Roedy Green <see_website@mindprod.com.invalid> - 2011-05-08 19:17 -0700
      Re: JNA performance Lew <noone@lewscanon.com> - 2011-05-09 08:36 -0400
        Re: JNA performance Roedy Green <see_website@mindprod.com.invalid> - 2011-05-09 06:34 -0700
          Re: JNA performance Lew <noone@lewscanon.com> - 2011-05-09 09:57 -0400
  O/T: Tag lines, or sigs (Was: JNA performance) Lew <noone@lewscanon.com> - 2011-05-08 08:02 -0400
    Re: O/T: Tag lines, or sigs (Was: JNA performance) Arved Sandstrom <asandstrom3minus1@eastlink.ca> - 2011-05-08 11:24 -0300
      Re: O/T: Tag lines, or sigs (Was: JNA performance) Lew <noone@lewscanon.com> - 2011-05-08 12:35 -0400
        Re: O/T: Tag lines, or sigs (Was: JNA performance) Knute Johnson <nospam@knutejohnson.com> - 2011-05-08 09:54 -0700
      Re: Tag lines, or sigs (Was: JNA performance) "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-09 03:37 +1000
      Re: O/T: Tag lines, or sigs (Was: JNA performance) Lawrence D'Oliveiro <ldo@geek-central.gen.new_zealand> - 2011-05-09 15:50 +1200
        Re: O/T: Tag lines, or sigs (Was: JNA performance) Lew <noone@lewscanon.com> - 2011-05-09 08:36 -0400
    Re: O/T: Tag lines, or sigs (Was: JNA performance) "Qu0ll" <Qu0llSixFour@gmail.com> - 2011-05-09 03:37 +1000
      Re: O/T: Tag lines, or sigs (Was: JNA performance) Daniele Futtorovic <da.futt.news@laposte-dot-net.invalid> - 2011-05-08 19:55 +0200
        Re: O/T: Tag lines, or sigs (Was: JNA performance) Martin Gregorie <martin@address-in-sig.invalid> - 2011-05-08 19:30 +0000
          Re: O/T: Tag lines, or sigs (Was: JNA performance) Steve Sobol <sjsobol@JustThe.net> - 2011-05-08 13:28 -0700
  Re: JNA performance Jim Janney <jjanney@shell.xmission.com> - 2011-05-09 08:54 -0600

csiph-web