News for hackers. Stuff that matters.
Re:Apple Silicon M1: A Developer's Perspective by lumost on Saturday November 28, 2020 @01:06PM (#25239203)
IDEs such as IntelliJ can easily consume 8GB of memory on a moderately sized project of 100k loc. If one has to open multiple such projects or work on a very large project in the million loc scope then you’ll run out of 16 GB really fast.

Folks working with data intensive applications often need to trade off writing code to page data in and out of memory during development with larger dev boxes.

Re:Apple Silicon M1: A Developer's Perspective by Jtsummers on Saturday November 28, 2020 @01:43PM (#25239516)
100k LOC would be, let's be generous, about 8 million characters (80/line average, which is high). 8GB of RAM for 8MB of input seems excessive to me. What's going on with that IDE that it needs so much for something so small? Even if that were 8 million distinct tokens/symbols in the input, that's still 1KB/token of memory consumed.
Re:Apple Silicon M1: A Developer's Perspective by CapsAdmin on Saturday November 28, 2020 @01:57PM (#25239613)
I would assume code analysis.

8gb still sounds a bit excessive but given how long java stack traces can be maybe it's not so strange.

Re:Apple Silicon M1: A Developer's Perspective by aledalgrande on Saturday November 28, 2020 @07:14PM (#25241763)
Except that is only what an IDE does at the very minimum. An IDE loads plugins, provides intellisense, documentation, potentially loads documentation of all the libraries, watches files, displays Git status, parses your code for syntax highlighting etc. etc.

You're not opening a TXT file with 100K lines in it.

Re:Apple Silicon M1: A Developer's Perspective by z3t4 on Saturday November 28, 2020 @03:14PM (#25240155)
For every key stroke a new immutable string is created with the content of the file/state. Plus data structure for AST/static analysis of every file in the project including dependencies. Plus another copy of the file for rendering with syntax highlight. One would think all this copying of data is very inefficient, but computers are good at moving data around. The most costly is rendering the glyphs.
Re:Apple Silicon M1: A Developer's Perspective by wulfklaue on Sunday November 29, 2020 @09:17PM (#25250114)
> IDEs such as IntelliJ can easily consume 8GB of memory

Sound more like a Jetbrain ( IntelliJ company ) problem. Used to develop on PHPstorm ( another Jetbrain ) product ( same software in the background ) and the slow startup's, 2GB+ memory eating for relative small projects, crashes way too much, expensive as hell for what it does ( especially with the license change years ago ) ...

Eventually switched to Visual Studio Code and while people whine how Electron is memory inefficient, its like 1/6 the memory usage of PHPstorm, with only a few features missing.

Even on a 32GB PC system, i barely use 16GB ( and WSL2 is eating up a lot with a lot of docker images. And its not really docker, just Linux cache eating up memory ). Not a issue on a Mac that does not need a VM like layer.

Its about priorities sometimes. If people keep upgrading their memory, developers/companies simply push the responsibility to the clients and do not bother with spending time on optimizing.

If people start leaving software product on the way side for being just horrible inefficient messes, then maybe a bit of focus will come back to actually optimizing products! You will see Jetbrain change tune, when VSC etc keep eating its market share.

Re:Apple Silicon M1: A Developer's Perspective by fayten on Saturday November 28, 2020 @06:18PM (#25241419)
I have worked on a large 10 year old Spring application with well over 300k loc for 3 years. I don't recall Intelij ever exceeding 3gb of ram. Intelij reminded snappy on my Macbook Pro 2015 with 16gb of ram and an i7.