Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
07/21/09 05:42
Read: times


 
#167640 - One has to be prepared.
Responding to: ???'s previous message
David Prentice said:
Richard Erlacher said:


It means attention to detail at the lowest level, and that's where the process often breaks down.

The reason I repeat, time and again, that one who can't program a task in ASM can't program it, is that ASM forces the programmer to concern him/herself with the lowest-level details. One who's learned to do it in ASM recognizes those low-level details and ensures that they're properly dealt-with before considering his work complete. It's easy to overlook lowest-level details when the language allows you to do that.

RE



I have been vaguely following this thread, and come to various conclusions:

1. RE has not used Keil C. (personally, I have only ever tried the evaluation)
2. RE has not written a full application in C of any flavour. Even the comments about SDCC do not ring quite true.
3. RE is an excellent ASM programmer of 8051 and probably several other obsolete micros.
4. RE has not ever "seriously" used a PIC, AVR, ARM, Renesas, ...

Now, that's not quite the case. I've written a few pretty serious app's, a number of simulators and a couple of assemblers, linkers, and loaders, but that was back in the days when Turbo C was new. Prior to that, I used Turbo Pascal, when it was new. I've also written a few pretty neat simulators in Prolog with pieces in 'C'. All that was on the PC, and back in the mid-late '80's. I've only done a little 805x (Maybe 500k lines) programming, in ASM, since most (>90%) of my programming was on other micros, before Windows and much of it before the PC. I have fiddled with the PIC, disliked the AVR from the get-go, and haven't had to program the ARM because I had a software team. My role with ARM stuff has been mostly hardware and as project manager. Is Renesas a microcontroller? I thought it was a software house. I did look at their compiler at one time.

Different architectures and platforms suit different applications. However fond one may be of one micro, it does not mean that it is always the ideal solution. Of course one's preference is to use the familiar platform if at all practical.

I've painstakingly avoided the Intel processors after the 8048 because of Intel's fondness for making signals that should have been negative-going, the other way around, e.g. RESET, NMI, IRQ, etc. Having those signals referenced to a variable supply during power-on always seemed silly to me. My work has been mainly with Zilog, and Motorola architectures, with a few others thrown in, but mostly Motorola (now Freescale). I did use TI DSP's some of the time. There's practical reason for my antipathy toward Intel's parts, though.

I see no problem with mentioning HLL's or other micros. It may well be that the sheer topic invites an elegant 8051 solution.

A clearly thought out design is far more important than a messy ASM code.

You can't assume that just because it's ASM, it's messy, nor can you assume that just because it's HLL, it well-structured and well organized.

And those cell-phones with a limited market life evolve into the next generation.

That's exactly why they're never going to improve. If only they'd fix the %$#@! things ...

Code re-use becomes essential as systems get bigger. Einstein would struggle with porting or maintaining systems of that size in ASM.

I've seldom had an 805x app much larger than 5k lines, aside from table space, though some of those have had difficulty fitting in 32kB. Once you've bought the extra code space, you might as well use it.

David.


I've been preaching some of this stuff, not so much the 'C' vs ASM argument, but the "understand your processor and hardware, and system requirements, before writing code" stuff. It's just simple preparation.

RE



List of 140 messages in thread
TopicAuthorDate
"C gives 2K of binary for just a few source lines". Discuss.            01/01/70 00:00      
   What's there to discuss?            01/01/70 00:00      
      Just use macros creatively            01/01/70 00:00      
         It doesn't take a genius ot make things worse            01/01/70 00:00      
   C timing loops...            01/01/70 00:00      
      tsk, tsk...            01/01/70 00:00      
         Hard to make simple "hello world" applications            01/01/70 00:00      
         Yes, I Do            01/01/70 00:00      
   and that's exactly the problem            01/01/70 00:00      
      Generalisations            01/01/70 00:00      
      So stop blaming the tools!            01/01/70 00:00      
         C intentionally designed to support "clever" developers            01/01/70 00:00      
         It's not the tools ... It's the folks who choose them!            01/01/70 00:00      
            So don't keep blaming the tools, then!            01/01/70 00:00      
               I've repeatedly said ...            01/01/70 00:00      
                  where is the qualifier?            01/01/70 00:00      
                     ISTM that some things simply won't work in 'C'            01/01/70 00:00      
                        Of course that is true            01/01/70 00:00      
                        exactly!!!            01/01/70 00:00      
                           The reverse            01/01/70 00:00      
                  But you have also repeatedly said            01/01/70 00:00      
                     another misnomer            01/01/70 00:00      
                        misnomer            01/01/70 00:00      
                           It's not entirely separate ... but it is an eval-issue            01/01/70 00:00      
                     That's a KEIL-specific limitation. it IS a KEIL problem            01/01/70 00:00      
                        It is a universal problem for all software makers            01/01/70 00:00      
                           last I evaluated ...            01/01/70 00:00      
                              4K Limited            01/01/70 00:00      
                                 One coud try SDCC, too            01/01/70 00:00      
                           Yes, this IS a problem for them            01/01/70 00:00      
                              30 days            01/01/70 00:00      
                                 locked tools            01/01/70 00:00      
                                    RE: locked tools            01/01/70 00:00      
      And ????            01/01/70 00:00      
         Do they need to use hammers for a few year before they can u            01/01/70 00:00      
            Good Idea vs The Real World            01/01/70 00:00      
               In the real world...            01/01/70 00:00      
                  get job in airline.            01/01/70 00:00      
                     Read the mail trail!            01/01/70 00:00      
      re: .. and that's exactly the problem            01/01/70 00:00      
         Does it work ?            01/01/70 00:00      
            there is another reason            01/01/70 00:00      
               little bits of asm            01/01/70 00:00      
                  Not just fast            01/01/70 00:00      
            If you were the manager ...            01/01/70 00:00      
               What's the collective noun for False Assumptions?            01/01/70 00:00      
                  Going with that            01/01/70 00:00      
                     It's a tradeoff ... Isn't it?            01/01/70 00:00      
                        More generalisations            01/01/70 00:00      
         It's already been "rolled"            01/01/70 00:00      
            If that was Only True            01/01/70 00:00      
         Not so fast ...            01/01/70 00:00      
            preaching to the choir            01/01/70 00:00      
            that whooshing sound ..            01/01/70 00:00      
            Off on the wrong track again...            01/01/70 00:00      
               Who cares which library?            01/01/70 00:00      
                  Talking out of both sides of the mouth            01/01/70 00:00      
                     I just come to think of it and ...            01/01/70 00:00      
                     You've got to pay closer attention, Erik!            01/01/70 00:00      
                        the pot calling the kettle black.            01/01/70 00:00      
      In the real world            01/01/70 00:00      
         So, it's your position that cost doesn't matter?            01/01/70 00:00      
            Complexity - not size - affects development time/cost            01/01/70 00:00      
            .            01/01/70 00:00      
   Getting the Least Out of Your C Compiler            01/01/70 00:00      
      An excellent article            01/01/70 00:00      
   It is Programmers Decision            01/01/70 00:00      
      Not so trivial to decide            01/01/70 00:00      
         The problem isn't with 'C' vs ASM ...            01/01/70 00:00      
            How many 'C'-coders would be willing?            01/01/70 00:00      
               Not the worst examples, but the preponderance, Andy            01/01/70 00:00      
            Much use of fixed-point in C code            01/01/70 00:00      
               It's not what they're taught to consider            01/01/70 00:00      
                  I don't know about everyone else            01/01/70 00:00      
                     Now wait a minute ...            01/01/70 00:00      
                        Lots of people can't program...            01/01/70 00:00      
                           What are you advocating, Per?            01/01/70 00:00      
                              Oh, Come On Now...            01/01/70 00:00      
                                 I have to admit ...            01/01/70 00:00      
                                    TTM and product lifetime            01/01/70 00:00      
                                       That's very true ... sadly ... but ...            01/01/70 00:00      
                                 if you really did do this you would come away a convert            01/01/70 00:00      
                                    C++ and 8051 are not a really good match            01/01/70 00:00      
                                       In general            01/01/70 00:00      
                                       C++            01/01/70 00:00      
                              C++            01/01/70 00:00      
                              oh, how 'crappy' they would be            01/01/70 00:00      
                                 Don't be so sure ...            01/01/70 00:00      
                                    irrelevant to C or asm,            01/01/70 00:00      
                                       Nobody has questioned your competence            01/01/70 00:00      
                                          you missed the point            01/01/70 00:00      
                                             Don't you think design style has something to with that?            01/01/70 00:00      
                                                you must be off your rocker            01/01/70 00:00      
                                          Don't confuse the tool with the user            01/01/70 00:00      
                  What evidence?            01/01/70 00:00      
                     Maybe not so ridiculous ...            01/01/70 00:00      
                        A + B != C            01/01/70 00:00      
                           Fine, but what are you advocating?            01/01/70 00:00      
                              ass-u-me            01/01/70 00:00      
                                 There are things they can do ... but should they?            01/01/70 00:00      
                                    If you want 8051 user, push for efficient 8051 developers            01/01/70 00:00      
                     few to none            01/01/70 00:00      
                  this has NOTHING o do with C            01/01/70 00:00      
                     I don't think so much PC either - just beginner accidents            01/01/70 00:00      
                        That may be one of the reasons we disagree ...            01/01/70 00:00      
                           Not a short-story            01/01/70 00:00      
                              which reminds me            01/01/70 00:00      
                           It is worth exploring C properly            01/01/70 00:00      
                              One has to be prepared.            01/01/70 00:00      
                                 You can't assume that just because it's ASM, it's messy            01/01/70 00:00      
                                 So your experience is >20 years out of date?            01/01/70 00:00      
                                    Not exactly            01/01/70 00:00      
                                 Just try some modern tools.            01/01/70 00:00      
                                    It's not quite like that ...            01/01/70 00:00      
                                       Project management            01/01/70 00:00      
                                          I have to make a distinction            01/01/70 00:00      
                                             non-sequitur            01/01/70 00:00      
                                                Hardly!            01/01/70 00:00      
                                             Out of interest            01/01/70 00:00      
                                                My bad! Sorry!            01/01/70 00:00      
                                       Negative reset too            01/01/70 00:00      
                                          Yes, there are a few.            01/01/70 00:00      
                              thoughts on this ...            01/01/70 00:00      
   Real Programmers don't write assembler            01/01/70 00:00      
      Ouch            01/01/70 00:00      
      What, hexadecimal?!            01/01/70 00:00      
         Hex            01/01/70 00:00      
            That's how a lot of us started out ...            01/01/70 00:00      
               And then life stood still            01/01/70 00:00      
                  Is it 23 May 2005 already?            01/01/70 00:00      
                     Not exactly            01/01/70 00:00      
                         8kB of object code            01/01/70 00:00      
                           If you'd had the experience ...            01/01/70 00:00      
                              You can use a monitor or ICE or whatever            01/01/70 00:00      
                              nostalgia is a great thing thing            01/01/70 00:00      
   C gives 2k....            01/01/70 00:00      
      Intel APP Builder            01/01/70 00:00      
         Intel AppBuilder and similar            01/01/70 00:00      
            Going off-topic            01/01/70 00:00      
               The are also MCUs with 1K            01/01/70 00:00      

Back to Subject List