Win a copy of Micro Frontends in Action this week in the Server-Side JavaScript and NodeJS forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Trade offs

 
Ranch Hand
Posts: 106
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Author,

I know from the other discussion thread you have tried approach some serious stuff in a lighter way.

Having said that,on a serious note ,what would you say as what determines performance?is it  data structures, algorithms,
Computer architecture, hardware?

Thanks
 
Author
Posts: 18
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It is all of the above: data structures, algorithms, hardware, etc.  Moreover getting good performance for an algorithm is understanding each of these aspects and how they interact. It is the combination of these parts. You can drastically slow down a good algorithm by using the wrong data structure.  Or your data structure can be inefficient with respect to the way the hardware access data. To get the best performance you have to choose these parts to work together.
 
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think that hardware mostly determines performance, and software written to take advantage of hardware the hardware capacity can be much more efficient that otherwise. OTOH, it's difficult (impossible) to write general software intended to run on a variety of platforms. The question is, do we develop efficient software that is highly coupled to the hardware architecture, or do we design software with a purposeful ignorance of the hardware?
 
Marshal
Posts: 70353
283
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You appear to have come late to this discussion. I am sure most people would disagree; the software determines the use made of the hardware and therefore has much more effect on performance than you suggested. It is often the parts of the software you don't see, e.g. optimising compilers, which have the greatest effect.
The nice thing about a virtual machine is that it permits us to write software which will run on different platforms with only slight changes.
 
Marshal
Posts: 25835
69
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Damon McNeill wrote:I think that hardware mostly determines performance, and software written to take advantage of hardware the hardware capacity can be much more efficient that otherwise. OTOH, it's difficult (impossible) to write general software intended to run on a variety of platforms. The question is, do we develop efficient software that is highly coupled to the hardware architecture, or do we design software with a purposeful ignorance of the hardware?



In my life as a programmer I generally designed software with a very vague understanding of the hardware it would be run on. In the early days we only had small amounts of memory to work with (e.g. 64K) so it was necessary to program in a style which used basically no working memory. Later we had larger amounts of memory so we could write more complex programs. Then we started to use Java, and we could write general software which was indeed intended to run on a variety of platforms, and did.

I think the vast majority of programmers have little or no idea about the hardware architecture on which their programs run. I read recently that modern Intel chips have six levels of caching to process code. And the chips are designed so that when they come to a branch statement, which apparently is slow, they just continue executing both sides of the if-else until the result of the branch is known, at which time they discard the data from the wrong branch and continue on the right branch. This sort of thing is all very well but it doesn't affect how I write code. I just interpret all of that to mean that the chips are designed to be as fast as possible no matter what code they are given.
 
Ranch Hand
Posts: 437
Oracle Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Satya,

satya sundar wrote:
Having said that,on a serious note ,what would you say as what determines performance?is it  data structures, algorithms,
Computer architecture, hardware?



Added to these, Wetware, UX factor plays important roles on performance.


 
Campbell Ritchie
Marshal
Posts: 70353
283
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I agree that pouring my coffee into my computer adversely affects its performance. Oh, that isn't what wetware means

Please always explain abbreviations like UX. I think that may not so much affect performance by the computer as whether anybody uses your app at all.
 
You learn how to close your eyes and tell yourself "this just isn't really happening to me." Tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
reply
    Bookmark Topic Watch Topic
  • New Topic