??? 06/23/09 00:04 Read: times |
#166373 - If you can not code it in ASM ... Responding to: ???'s previous message |
... then you probably can not code it at all. I agree that it really doesn't matter whether you code in 'C' or Pascal, or BASIC, or whatever ... If you don't know how to code your task in ASM, then you most probably will fail in any HLL.
I do believe that, before using any HLL compiler, one should have a good idea of what will be produced by the compiler for a given HLL construct. Clearly, one should use ASM to construct modules that deal directly with hardware features in most cases, though there are undoubtedly cases where HLL will "do." As experience with a given compiler grows, the ability to make decisions about such matters increases as well. However, unless one knows enough about the embedded environment, and, above all, the specifics of the local hardware, one certainly can't expect to be able to write useable code in a High Level Language. An exception might be in the case wherein the occasional module is written in 'C' and incorporated into a program written primarily in ASM. In a module, the task of which is to compute a value to be written to a variable that's used by another module, whether generated in HLL or ASM, it really doesn't matter how it was generated. However, once one has to deal with tasks that "talk" directly to hardware features, or tasks, the consumed time or code space of which matters, HLL is not so good a prospect. The compiler can generate ASM output, and a programmer can look at that output and subsequently modify it, or not, link it, and incorporate it into his code body. Once it's in ASM, it's unimportant how it got there. RE |