Heater
Posts: 8101
Joined: Tue Jul 17, 2012 3:02 pm

Re: is software harder than hardware? :)

Sat Oct 07, 2017 1:18 pm

Ha, yes.

Hardware is hard, software is harder, wetware is impossible to deal with!

berrymix
Posts: 13
Joined: Thu May 25, 2017 2:03 am
Location: Florida

Re: is software harder than hardware? :)

Mon Oct 09, 2017 6:04 am

It depends on the type of project that you have, and on which one are you more familiarize. But hey there's always the internet to consult for an answer. So as this community.

Heater
Posts: 8101
Joined: Tue Jul 17, 2012 3:02 pm

Re: is software harder than hardware? :)

Mon Oct 09, 2017 1:30 pm

I'm not sure the internet will ever give a definitive answer as to which is harder.

One way to find out is to try for oneself. Get a cheap FPGA development board. Like so http://www.latticestore.com/searchresul ... fault.aspx

And start designing your own logic in a hardware description language like Verilog. There are tons of tutorials around the net.

Or you could even just try Verilog using a simulator like Icarus Verilog http://iverilog.icarus.com/

I just started exploring all this kind of thing this year. It's lots of fun.

A big project would be filling up the much bigger Altera or Xilinx devices with your own design. Not easy.

When you are up to speed with that, try finding out how to get your design manufactured as an actual IC....

ShiftPlusOne
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 4736
Joined: Fri Jul 29, 2011 5:36 pm
Location: The unfashionable end of the western spiral arm of the Galaxy

Re: is software harder than hardware? :)

Mon Oct 09, 2017 2:36 pm

Large software projects need constant bug fixes, any patches which haven't been applied upstream need to be ported to each new release (which sometimes means a complete re-write of the new features), security patches need to be applied and depending on how close to head of tree you are, new bugs are added all the time.

With hardware, once it's released, it's done. All hardware problems which are discovered after that point become software problems.

drgeoff
Posts: 7443
Joined: Wed Jan 25, 2012 6:39 pm

Re: is software harder than hardware? :)

Mon Oct 09, 2017 6:06 pm

Computer hardware is only small part of hardware electronics.

Heater
Posts: 8101
Joined: Tue Jul 17, 2012 3:02 pm

Re: is software harder than hardware? :)

Mon Oct 09, 2017 6:49 pm

ShiftPlusOne,

Not so fast there. You are right that often the software guys have to work around hardware bugs. For example:

Back in the day we found that with the new Intel 286 processor, in protected mode, a multiply by an immediate constant, that happened to be negative, always gave an incorrect result.

The work around of course is that compilers and such never used that instruction with that addressing mode.

And of course most of the world was using the 286 in real mode to run MS-DOS so it was not an issue.

When we queried Intel about this we got a 200 hundred page document back, under NDA, detailing all the bugs in the 286. Sure enough our bug was there.

Presumably over time with new chip releases that bug got fixed. But last I heard the errata for the latest Intel chips is still huge. Growing with the complexity of the device.

So I could rephrase what you said as:

Large hardware projects need constant bug fixes, ... new bugs are added all the time.

Perhaps one way to judge how hard a large hardware project is vs a large software project is to count the billions of dollars Intel has spent to get us to the processors we have to day vs the billions of dollars MS has spent to get us an OS that runs on it.

bensimmo
Posts: 1912
Joined: Sun Dec 28, 2014 3:02 pm
Location: East Yorkshire

Re: is software harder than hardware? :)

Mon Oct 09, 2017 7:23 pm

ShiftPlusOne wrote:
Mon Oct 09, 2017 2:36 pm
Large software projects need constant bug fixes, any patches which haven't been applied upstream need to be ported to each new release (which sometimes means a complete re-write of the new features), security patches need to be applied and depending on how close to head of tree you are, new bugs are added all the time.

With hardware, once it's released, it's done. All hardware problems which are discovered after that point become software problems.
Or fixed and improved in the next itteretions of the hardware. Somehow they want it to go faster while using less space and less energy, they need to design new physical processes. That's not so easy, takes plenty of people and research to get to that point.
Sticking bits and bobs on a board is not just part of 'hardware' building.



As a side -----
I can write print "hello" in basic easily and have it do it, I might be completely ignoring the research, background coding and work that goes in to allowing me to do that and the nice hardware people who made it easy for the coders to let that happen.

Ask Nvidia or AMD which is easier, making the GPU's or writing the software to get the best out of them.
I bet both teams would argue, yet their complimentary.

jahboater
Posts: 1933
Joined: Wed Feb 04, 2015 6:38 pm

Re: is software harder than hardware? :)

Mon Oct 09, 2017 7:24 pm

ARM CPU's have bugs too .......

Code: Select all

-mfix-cortex-a53-835769
-mno-fix-cortex-a53-835769
  Enable or disable the workaround for the ARM Cortex-A53 erratum number 835769.  This
  involves inserting a NOP instruction between memory instructions and 64-bit integer
  multiply-accumulate instructions.

-mfix-cortex-a53-843419
-mno-fix-cortex-a53-843419
  Enable or disable the workaround for the ARM Cortex-A53 erratum number 843419.  This
  erratum workaround is made at link time and this will only pass the corresponding flag
  to the linker.
GCC options (I don't think either of these affect the Pi in 32-bit mode).

Heater
Posts: 8101
Joined: Tue Jul 17, 2012 3:02 pm

Re: is software harder than hardware? :)

Mon Oct 09, 2017 7:46 pm

Recently I heard the list of bugs in ARM processors was 37 pages long.

So where are we?

Four decades of hardware and software development since the invention of the microprocessor and neither of them work correctly?

So which is harder?

jahboater
Posts: 1933
Joined: Wed Feb 04, 2015 6:38 pm

Re: is software harder than hardware? :)

Mon Oct 09, 2017 9:07 pm

Heater wrote:
Mon Oct 09, 2017 7:46 pm
So which is harder?
My vote goes for software. As I said in an earlier post: hardware has physical limits, whereas software is limited only by human ability to manage its complexity.

jahboater
Posts: 1933
Joined: Wed Feb 04, 2015 6:38 pm

Re: is software harder than hardware? :)

Mon Oct 09, 2017 9:16 pm

Heater wrote:
Mon Oct 09, 2017 7:46 pm
Recently I heard the list of bugs in ARM processors was 37 pages long.
I think there could be a lot more bugs than that in a large piece of software.

The old assembler written mainframe operating systems were terrible.
OS360 never had less than 5000 known bugs at any time during its life.

W. H. Heydt
Posts: 7617
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

Re: is software harder than hardware? :)

Mon Oct 09, 2017 10:02 pm

Heater wrote:
Mon Oct 09, 2017 7:46 pm
Recently I heard the list of bugs in ARM processors was 37 pages long.
One (in)famous release of OS/360 was said to have 10,000 *significant* software faults in it. I doubt you could get the list into a mere 37 pages.

Heater
Posts: 8101
Joined: Tue Jul 17, 2012 3:02 pm

Re: is software harder than hardware? :)

Mon Oct 09, 2017 10:14 pm

No, no. The world does not care what level of abstraction you work at. Reality rules.

If your program is too big to fit in memory then it does not work.

If your program is so slow it's users have got bored and gone home. Or tomorrows weather forecast is ready next week. It does not work.

And what about those bug counts, hardware vs software? What do they mean? Perhaps fixing a hardware issue is a thousand times harder than fixing a software bug.

mlepage
Posts: 89
Joined: Tue Jun 12, 2012 1:58 am

Re: is software harder than hardware? :)

Mon Oct 09, 2017 10:31 pm

The only other thing I want to say is it's easy to try a bit of hardware or software and feel it's "easy".

Do a bit of soldering, read a data sheet, hook something up to an Arduino, and it's easy.

Write a Hello World, respond to a web request, put an entry in a database, and it's easy.

This of course completely overlooks the fact that simple hardware is nothing like complex hardware, and simple software is nothing like complex software.

Complex hardware is hard. And complex software is hard.

maikodocty25
Posts: 4
Joined: Tue Oct 24, 2017 1:58 pm

Re: is software harder than hardware? :)

Fri Nov 03, 2017 3:50 am

Hardware is much more complex than software. Software is run by the system so you need to do it online or in the comoputer but hardware is much more technical cause your doing it actual. In information technology, hardware is the physical aspect of computers, telecommunications, and other devices. The term arose as a way to distinguish the "box" and the electronic circuitry and components of a computer from the program you put in it to make it do things. The program came to be known as the software. and for software Software is a general term for the various kinds of programs used to operate computers and related devices. like this article https://www.lintechtt.com/blog/ all of the devices are ghardwares and monitored and run by a sioftware.

User avatar
joan
Posts: 12816
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: is software harder than hardware? :)

Fri Nov 03, 2017 7:16 am

Software is probably at least two orders of magnitude harder than hardware.

How many bugs does a modern chip have compared to a program of similar size?

Heater
Posts: 8101
Joined: Tue Jul 17, 2012 3:02 pm

Re: is software harder than hardware? :)

Fri Nov 03, 2017 7:51 am

joan
Software is probably at least two orders of magnitude harder than hardware. ....How many bugs does a modern chip have compared to a program of similar size?
It's kind of hard to compare.

Take a modern processor like an Intel x86. It is no doubt designed in a hardware description language like Verilog of VHDL. Which is code that looks like a regular software programming language. There are probably hundreds of thousands of lines of that HDL. There are, by all accounts, thousands of known bugs in it. Of course we will never get to see that HDL and the errata is only available to a select few under non-disclosure agreement.

I did once see the errata from Intel on their much small 286 processors when that was new. Let's just say it was a thick heavy document...

Looking at an example of such high level description language we might conclude that writing the code for some functionality in an HDL is not much harder than writing the C/C++ for the same functionality. See my example here:
viewtopic.php?f=62&t=194629#p1219379

The kicker is that its much easier and cheaper for a software author to push out a new update for his software than it is for a chip vendor to recall millions of buggy chips and replace them. Such recalls have cost Intel billions in the past.

As a result hardware vendors tend to put an order of magnitude more effort into testing their creations than software vendors.

User avatar
Gavinmc42
Posts: 1552
Joined: Wed Aug 28, 2013 3:31 am

Re: is software harder than hardware? :)

Fri Nov 03, 2017 8:53 am

One (in)famous release of OS/360 was said to have 10,000 *significant* software faults in it
Interesting, did not know that, yet real Software Engineering started with the 360, which had a huge 8MB of memory.
Watts Humphrey- Software Quality and the other big software processes came from around this period.

Time to make simple cpu's which has simple instructions, simple coding, self repairing, carbon based, just lots of them?
Call them neurons? Stick them in a mobile shell that self replicates ;)

Interesting that GPUs now have more cpu grunt than GP cpu's.
100-1000's of GPU core verses 8-16 GP cpu's.
The old RISC verses CISC war?
Are CISC's still around only because old software still has to run?

I am an old hardware guy, these ARMv8 things are too complex for me these days :oops:
I might, just might be able to understand only the AArch64 bit. I don't need backwards compatible stuff on new projects.
But lots of code runs on ARMv6/7, no need for 64bit support, it is too hard for the software guys to learn and support both :lol:

The errata on 8 bitters used to be a few lines/pages at the back of the complete datasheet.
Are the 12 QPU's with 48 ALU's much more complex? who knows? Undocumented :roll:
Mind you, I had trouble getting my head around the Prop1's 8 x 32bit cores and am only here because the Prop2 is late.

Can we go back to 4bit cores and program in BCD?
Hey Quantum 4 bit cores, solve everything at once :ugeek:
I'm dancing on Rainbows.
Raspberries are not Apples or Oranges

Heater
Posts: 8101
Joined: Tue Jul 17, 2012 3:02 pm

Re: is software harder than hardware? :)

Fri Nov 03, 2017 6:46 pm

Gavinmc42,

Mind you, I had trouble getting my head around the Prop1's 8 x 32bit cores and am only here because the Prop2 is late.
You might be in the wrong place.

The Pi cannot do many things can be done by a Propeller with ease.

I too am frustrated over the delays in the P2. So much so that I have basically given up and turned to FPGA's to do what I expected to do with a P2 years ago. Especially now that FPGA's from Lattice can be had on ten dollar boards.

Perhaps I'll look into the P2 when it arrives but it is possible my momentum is taking me elsewhere.

Edit: Oh wait. With respect this thread's title, what I just said above implies I'm moving from software effort on the Propeller MCU to hardware effort on FPGA. Turns out the transition from software to hardware design is not so hard. Especially now that we have SpinalHDL.

Return to “Off topic discussion”

Who is online

Users browsing this forum: No registered users and 5 guests