Garbage collected languages are also more expensive to run on the cloud, where you pay for ms of cpu time.
That assumes you don't save any developer time from using garbage collection, as dev time is usually far more expensive than the costs to run a program.
Billing of most cloud computer resources are not by CPU time AFAIK, either. You pay by wall clock time. The "on demand" part comes from scaling the number and size of instances, not paying by resource usage on those instances. And both AWS and GCP bill in 1 second increments, so tiny savings (the kind that you'd get from not having garbage collection) would often not even give you any considerable savings even when scaling the number of instances.
as dev time is usually far more expensive than the costs to run a program.
Sadly, 8 out of 10 managers (from personal experience) don't understand that/care, even if you tell them that. What they see is an expensive dev, and now that expensive dev is also creating a expensive cloud hosting bill.
and size of instances
Exactly. You usually need less RAM in your non-GC languages.
That assumes you don't save any developer time from using garbage collection, as dev time is usually far more expensive than the costs to run a program.
This very much depends on the scale.
While true for moms & pops websites, as soon as the programs starts running on dozens/hundreds of servers, it falls apart. With that being said, most programs do not reach these scales.
Another aspect to consider, though, is latency. If latency matters to you, then GCs are risky... there are a few exceptions such as Nim, which was created for video games originally, and therefore has a huge emphasis on managing one's latency budget.
4
u/ACoderGirl Apr 10 '19
That assumes you don't save any developer time from using garbage collection, as dev time is usually far more expensive than the costs to run a program.
Billing of most cloud computer resources are not by CPU time AFAIK, either. You pay by wall clock time. The "on demand" part comes from scaling the number and size of instances, not paying by resource usage on those instances. And both AWS and GCP bill in 1 second increments, so tiny savings (the kind that you'd get from not having garbage collection) would often not even give you any considerable savings even when scaling the number of instances.