473,883 Members | 1,596 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

benchmarks? java vs .net

The shootout site has benchmarks comparing different languages. It
includes C# Mono vs Java but not C# .NET vs Java. So I went through
all the benchmark on the site ...

http://kingrazi.blogspot.com/2008/05...enchmarks.html

Just to keep the post on topic for my friends at comp.lang.c++, how do
I play default windows sounds with C++?

Jun 27 '08
358 13276
Arne Vajhøj wrote:
IOW, there are arguments for both approaches. The GC one has the big
advantage that one big cause of errors, all errors regarding memory
use, are more or less completely eliminated. But I doubt I would
call speed one of the main factors to choose a GC.

Actually GC speed is very good.

The problem people complain over is the non deterministic
aspect of it.
People also complained about messaging and the non-linear aspect of it
when they moved from DOS to Windows. I guess, to many, this is a
similar issue, i.e. they sense a loss of control. <g>
--
Rudy Velthuis http://rvelthuis.de

"We don't make mistakes, we just have happy little accidents."
-- Bob Ross, "The Joy of Painting"
Jun 27 '08 #301
Arne Vajhøj wrote:
Jon Harrop wrote:
>Razii wrote:
>>On Wed, 04 Jun 2008 20:34:59 +0100, Jon Harrop <jo*@ffconsulta ncy.com>
wrote:
You are still timing Cygwin's implementation of Unix pipes which has
nothing to do with anything.
I am still waiting for you to verify and demonstrate it has any
effect.

Your inexplicably anomalous results already proved that.

For anyone with just a minimum of understanding of logic: not.
My Cygwin-free results are up to 4x faster than Razii's Cygwin-burdened
results. How else do you explain that?

--
Dr Jon D Harrop, Flying Frog Consultancy
http://www.ffconsultancy.com/products/?u
Jun 27 '08 #302
Arne Vajhøj wrote:
Or why do you think the Cygwin stuff can explain the difference in the two
tests?
According to Razii, Cygwin is the only significant difference between our
setups. From my results, we know Razii's results for .NET are up to 4x
slower than they should be. Therefore, Cygwin is the only logical
explanation.

--
Dr Jon D Harrop, Flying Frog Consultancy
http://www.ffconsultancy.com/products/?u
Jun 27 '08 #303
Arne Vajhøj wrote:
Razii wrote:
>On Sat, 07 Jun 2008 19:35:08 +0100, Jon Harrop <jo*@ffconsulta ncy.com>
wrote:
>>>The shootout doesn't use 3 gig max memory.
How do you know that?

They list the options they use. Besides, the computer they are using,
Pentium 4, has only 512 MB ram.

Xmx is a reliable max on memory usage.
The Java program with the 512Mb limit actually uses 800Mb here.

--
Dr Jon D Harrop, Flying Frog Consultancy
http://www.ffconsultancy.com/products/?u
Jun 27 '08 #304
Arne Vajhøj wrote:
Jon Harrop wrote:
>You are ignoring all of the overheads of a GC, like thread
synchronizatio n, stack walking and limitations placed upon the code
generator required to keep the GC happy.

I would expect non-GC solutions to need more thread synchronization
than GC because it will need it many more times.
That is just more unfounded speculation.

--
Dr Jon D Harrop, Flying Frog Consultancy
http://www.ffconsultancy.com/products/?u
Jun 27 '08 #305
On Mon, 09 Jun 2008 14:17:13 +0100, Jon Harrop <jo*@ffconsulta ncy.com>
wrote:
>Firstly, your tweak did not break the program for other (previously valid)
inputs as Razii's does.
Have some decency and don't lie. My tweak doesn't break the program
for any previously valid input. You are whining since you can't tweak
..NET which is pathetically twice slower.

So here what we have now:

regexdna (.NET slower)
binarytrees (.NET twice slower).
recursive (.NET slower).

Only in partialsums .NET is twice fast but that speed comes at the
cost that results for sin and cos are inconsistent on different
hardware. In other words, .NET is not portable. Almost everything
else, .NET is slower.
Jun 27 '08 #306
On Mon, 9 Jun 2008 06:44:26 -0700 (PDT), "Jon Skeet [C# MVP]"
<sk***@pobox.co mwrote:
>But the point is that it didn't fail for n=20, which is the test in
question.
Even with n=16, GC runs with my tweak of -Xms512m etc. Harpo is lying.
He now has zero credibility.
Jun 27 '08 #307
On Jun 9, 4:49 pm, Razii <pyukj...@gmail .comwrote:

<snip>
So here what we have now:

regexdna (.NET slower)
binarytrees (.NET twice slower).
recursive (.NET slower).
I haven't looked at regexdna or recursive yet, but for binarytrees I
didn't see .NET being twice as slow. With both sets of tweaks, .NET
was about 50% slower than Java on my box, and by your own stats (15s
vs 25s) it's only ~66% slower. Exaggerating the figures undermines
your point rather than improving it. (The 15s vs 25s was in message
<gd************ *************** *****@4ax.com>. )

Now, on how *applicable* these benchmarks are to real world
performance, I'm entirely with Jon Harrop: they may be somewhat
interesting in and of themselves, but they're not good predictors of
what real applications will do. For real world applications, you can
rarely get a massive improvement by tweaking the garbage collector,
for instance - partly because real world applications tend to execute
a far wider range of code. Benchmarks are naturally myopic.

As I've said before in this thread (I think) performance isn't
generally a good reason to choose between Java and .NET. There are far
more important criteria.

Jon
Jun 27 '08 #308
On Mon, 9 Jun 2008 09:09:12 -0700 (PDT), "Jon Skeet [C# MVP]"
<sk***@pobox.co mwrote:
>I haven't looked at regexdna or recursive yet, but for binarytrees I
didn't see .NET being twice as slow. With both sets of tweaks, .NET
was about 50% slower than Java on my box, and by your own stats (15s
vs 25s) it's only ~66% slower. Exaggerating the figures undermines
your point rather than improving it. (The 15s vs 25s was in message
<gd*********** *************** ******@4ax.com> .)
In your message, you said with -server it was ~15s vs ~28s. That's 2
second short of twice slower.

As for recursive, .NET is 1.5 times slower:

http://shootout.alioth.debian.org/gp...ng=javaxx&id=0
http://shootout.alioth.debian.org/gp...ng=csharp&id=0
Regexdna. .NET is about 25% slower:
http://shootout.alioth.debian.org/gp...ng=javaxx&id=4

http://shootout.alioth.debian.org/gp...ng=csharp&id=0
The input file for regexdna is generated with FASTA benchmark

http://shootout.alioth.debian.org/gp...ng=javaxx&id=2

use n = 500,000 with Fasta benchmark, and the output would be the
input-file for regexdna.


Jun 27 '08 #309
On Mon, 9 Jun 2008 09:09:12 -0700 (PDT), "Jon Skeet [C# MVP]"
<sk***@pobox.co mwrote:
>Now, on how *applicable* these benchmarks are to real world
performance
The benchmark shows that Java's GC is easier to tune for given
situation. Many options are available to tune GC

http://java.sun.com/javase/technolog.../vmoptions.jsp

Jun 27 '08 #310

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

80
3572
by: tech | last post by:
Hi, i have the following problem In file1.h namespace A { class Bar { void foo();
318
11198
by: King Raz | last post by:
The shootout site has benchmarks comparing different languages. It includes C# Mono vs Java but not C# .NET vs Java. So I went through all the benchmark on the site ... http://kingrazi.blogspot.com/2008/05/shootout-c-net-vs-java-benchmarks.html Just to keep the post on topic for my friends at comp.lang.c++, how do I play default windows sounds with C++?
0
9936
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9791
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
11137
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10845
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9571
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
7123
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5797
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4609
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
3231
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.