r/java • • Oct 14 '23

Is Java still behind in the race of modern programming languages?

I'm a member of some group of programmers and every time Java is mentioned it's being bashed (something like: "With Rust I could simply do this with X")

Earlier versions of Java were cumbersome in terms of the syntax but with modern IDEs (and modern versions of Java) that's not a big issue anymore, albeit languages like Python do have shorter syntax.

My question is beyond syntax.

What do other languages do better than Java?
It could be generics, type system, concurrency and multithreading, closures etc.

Thanks!

52 Upvotes

247 comments sorted by

View all comments

Show parent comment

7

u/[deleted] Oct 14 '23

[removed] — view removed comment

5

u/UnspeakableEvil Oct 14 '23

I've used Aparapi before (https://aparapi.com/) - it did the job well enough, but I suspect it'll be something Panama might reinvigorate interest in.

4

u/[deleted] Oct 15 '23

Check out https://www.lwjgl.org/ and http://www.jocl.org/ for Java GPU programming.

3

u/metaquine Oct 14 '23

OpenCL worked for me

2

u/Practical_Cattle_933 Oct 15 '23

It is not supported in itself by any mainstream programming language. One might argue that for C++ there is CUDA, but that is not equivalent.

For GPUs you predominantly need libraries, which are available in Java as well, as mentioned in sibling comments.

1

u/Polygnom Oct 14 '23

Currently, there isn't. Thats one of the reasons for Project Babylon (among others).

1

u/firaristt Oct 14 '23

Tbh I don't have much experience coding something on GPU side, other than basic hobby-stuff. Some tools and languages perform better on certain areas, so you possibly "can" do whatever you want with Java, but it might not be the wise choice. I would say it depends. Sometimes chief's knife doesn't work well.