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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
02/15/18 00:43
Read: times


 
#190839 - Assembly vs. Keil
Responding to: ???'s previous message
Once I had to optimize an 8051 project (mostly for execution time, also for space, at less priority). I started with the Keil C compiler disassembly output.

It wasn't very hard to beat the compiler, and Keil said the same in their documentation (roughly that they didn't know what the end application would be and they couldn't produce assembly output optimized better than end application engineers could do). What I remember is that there was a lot of switching in and out of registers unnecessarily. Maybe they strang together a bunch of library macros to generate their output.

This was around 2001, though; They've probably gotten a lot better. I've used Keil more recently for ARM, but I didn't need to optimize the output so I probably didn't look at it too hard.

As far as this particular question, I can picture some other advantages. Assembly could be easier to review for critical systems, as long as you've got people who can read it. If you're only reviewing high-level source you're essentially trusting the compiler output (at least as far as review is concerned).

Re Razman's original question: there is a Tutorial link on the left button bar, with various useful information including a 16-bit math tutorial for the 8051. The FAQ links and pages appear to be broken (the FAQ frame is empty in both Firefox and Chrome, and a wget on it returns a 404 error). But the individual FAQ pages are still there. You can google "http://www.8052.com FAQ" and get useful hits.

List of 16 messages in thread
TopicAuthorDate
Arithmetic operation with signed number & fractional number            01/01/70 00:00      
   Fractional Arithmetic            01/01/70 00:00      
      agree            01/01/70 00:00      
   Why Assembler?            01/01/70 00:00      
      Hard to do better.            01/01/70 00:00      
         Assembly vs. Keil            01/01/70 00:00      
            assembly vs C            01/01/70 00:00      
               Re: assembly vs C            01/01/70 00:00      
                  In the good old days...            01/01/70 00:00      
                     in the new days            01/01/70 00:00      
   Hi Razman, here are some links            01/01/70 00:00      
      Code samples            01/01/70 00:00      
         Oops - 8052.com code library is broken            01/01/70 00:00      
      A bit late            01/01/70 00:00      
         threads autolocking at approx. 2 months            01/01/70 00:00      
            threads autolocking            01/01/70 00:00      

Back to Subject List