dotnet vs java vs go

各个语言版本

语言 版本
dotnet .NET Core SDK 3.1.101
Java openjdk 14 2020-03-17
go go1.14

regex-redux

Match DNA 8-mers and substitute magic patterns

dotnet vs java


dotnet 胜(与C++相差无几)

注意:dotnet使用了DllImport,所以速度非常快,这个应该不能算到dotnet头上,其它写法是比java慢的。

go vs java


java 胜

spectral-norm

Eigenvalue using the power method

dotnet vs java


dotnet 胜(与C++相差无几)

go vs java


go 胜(相差无几)

k-nucleotide

Hashtable update and k-nucleotide strings

dotnet vs java


dotnet 胜

go vs java


java 胜

fannkuch-redux

Indexed-access to tiny integer-sequence

dotnet vs java


dotnet 胜

go vs java


go胜

pidigits

Streaming arbitrary-precision arithmetic

dotnet vs java


dotnet 胜

go vs java


go胜

binary-trees

Allocate and deallocate many many binary trees

dotnet vs java


dotnet 胜

go vs java


java胜

fasta

Generate and write random DNA sequences

dotnet vs java


dotnet 胜

go vs java


go 胜

mandelbrot

Generate Mandelbrot set portable bitmap file

dotnet vs java


dotnet 胜

go vs java


go胜

n-body

Double-precision N-body simulation

dotnet vs java


dotnet胜

go vs java


go胜

reverse-complement

Read DNA sequences - write their reverse-complement

dotnet vs java


dotnet胜

go vs java


java胜

Web Framework Benchmarks

JSON serialization

排在前面分别是java,go,dotnet

Single query

排在前面分别是java,go,dotnet

Multiple queries

排在前面分别是java,go,dotnet

Fortunes

排在前面分别是go,java,dotnet

Data updates

排在前面分别是java,dotnet,go

Plaintext

排在前面分别是go,java,dotnet 几乎无相差

dotnet 官方出品aspnetcore 几乎能秒杀其它语言web框架,虽然java在前面,但不是固定的框架

总结

各个语言都有自己的优势,自己喜欢就好!

参考

  1. benchmarks game
  2. techempower
posted on 2020-03-21 21:00  kingreatwill  阅读(1145)  评论(0编辑  收藏  举报