Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5

Optimization and You

#6
(September 25th, 2019 at 12:25 AM)Darth-Apple Wrote: Nice post, +rep. Thank you for sharing!

I wish that people would spend more time attempting to properly optimize applications. Interpreted languages (especially "slower" languages, such as Python) are becoming increasingly common. Java is relatively decent as far as performance is concerned. C is obviously great. C#, an interpreted language, is gaining some traction over classic C and C++, and overall, people care so much more about cross platform options than they do about efficient, high performance options.

It's to be expected. 15 years ago, when the best anyone had was a Pentium 3 or a Pentium 4, before gigabytes of RAM and multi-core processors, people had no real choice but to make sure their applications were highly optimized. As a result, if the application had any sort of demanding system requirements, you would pretty much have to do it in Java or C. Python wasn't going to cut it.

Nowadays, this is much less of a focus, as you mentioned. For example, Mac OS is now integrating a new cross platform toolkit and a set of libraries to allow developers to easily port iOS applications to Mac OS (coming with the new version of the OS next month). Much of the groundwork on a lot of this had already been completed for Mac OS Mojave, which is out now. Several iOS apps (such as Stocks, News, and Reminders) were ported to the desktop as a part of the release. These apps, despite launching very quickly on the iPhone, are very slow to launch on a presumably more powerful MacBook. (Although some of the newest iPhones have a total smoke show of a CPU built in. Apple truly undersold these things.

So many additional libraries have to be dynamically loaded that launching times can easily extend into the several seconds range. These were the kinds of launch times you would expect from a pre Core-2-duo CPU (e.g. Pentium 4, etc.). After 10-15 years, we haven't made a whole world of progress in terms of end-user performance (though we've definitely made strides in the right direction). Instead, all of this extra computational power is used in helping the developer.

In the end, I don't think this will be changing. Developers seem to work for other developers, and not so much for the user. If the development can be done more easily, or be ported to more devices, the incentives for developers to work on projects is greater. And as a result, the ecosystem of developers is larger, more diverse, and more qualified. We end up with more applications that have more features, and are ported to more devices. But the end-user ultimately has to pay the price in the performance gains that they would otherwise see.

Funny you mention MacOS/iOS, because you're absolutely right considering the porting mobile to desktop stuff.

Apple devs are probably the biggest sluts for optimization, actually, since everything is standardized. Each iPhone (assuming the same model) will always have the same specifications. Same battery, same CPU, same chipsets, etc. And because it's standardized, Apple can also write iOS with those specific parts in mind.

No extra drivers. No extra unused kernel modules (note that iOS and MacOS are heavily based on BSD). No extra runtimes because Swift (and ObjC before it) both compile natively. There's very little overhead, and Apple can make it work because they don't need to worry about any extra variables and they can focus on making their software work near perfectly for the hardware they choose for each model.

Of course, there is some overhead, since the same firmware file can be installed on any (supported) hardware, so backwards compatibility is probably those few extra millimeters which are more or less negligible.

I really do hope the toolkit makes some waves. I personally don't own any Apple products (a little too expensive for the dumpster-diver in me) but I have been debating getting a Macbook Pro or something for an incredibly long time. But I can only imagine that performance is gonna skyrocket and we can say that we've truly moved into the mobile era.

And with it comes learning RISC-V and ARM64 assembly.
Put me out of my misery, x86 is hard enough (although I'd only really be learning an ISA and maybe a few specifics like endianness or whatever, so I guess it's somewhat portable.)



Otherwise, yeah. It's a bit depressing to see Node.JS take up 500mb for a simple bot that prints Hello World a few times to stdout.

I especially wish that JS devs started to care more about performance. I mean, to some degree they do, but their 'solutions' are just quick and dirty hacks that somehow make their way upstream into releases for Node, jQuery, or the default ECMAScript-based browser sandboxes. No actual attempts at improving the dumpster fire. I would probably use it on the regular if it was a little better, since I do actually enjoy working with it for simple web projects, but I can't stand the overhead it produces with the runtime.

And don't get me started on the electron framework. It literally takes me hours to even compile it. That's traumatized me enough.

At least Ruby and Perl devs seem to care about optimization. I'm not sure where Python is headed since Rossum left.



(September 24th, 2019 at 10:53 PM)SpookyZalost Wrote: I took a Visual Basic class after dropping out of high school before getting my GED but no... I meant BASIC as in the language used significantly in the 1970's, 80's, and early 90's on home computers considering many came with a basic programmer, assembler, and interpreter.

Yeah, lmao. You know how horrible it is. VB is another dumpster fire. I can't fathom the fact that people actually use it for anything.

I can only imagine that's what BASIC is still used for, legacy systems. Since most of the companies that I briefly mentioned in the last post above do specialize in security/contracting, I can imagine they work with lots of legacy military systems or something along those lines.
Reply


Messages In This Thread
Optimization and You - by Lain - September 24th, 2019 at 3:50 AM
RE: Optimization and You - by SpookyZalost - September 24th, 2019 at 4:03 AM
RE: Optimization and You - by Lain - September 24th, 2019 at 4:16 AM
RE: Optimization and You - by SpookyZalost - September 24th, 2019 at 10:53 PM
RE: Optimization and You - by Darth-Apple - September 25th, 2019 at 12:25 AM
RE: Optimization and You - by Lain - September 25th, 2019 at 12:56 AM
RE: Optimization and You - by SpookyZalost - September 25th, 2019 at 5:46 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Project Euler and Software Optimization (Problem 4 & Palindromes) Darth-Apple 4 3,573 February 12th, 2020 at 7:06 PM
Last Post: Darth-Apple



Users browsing this thread: 1 Guest(s)

Dark/Light Theme Selector

Contact Us | Makestation | Return to Top | Lite (Archive) Mode | RSS Syndication 
Proudly powered by MyBB 1.8, © 2002-2024
Forum design by Makestation Team © 2013-2024