BoostC tiny Wiki

From OpenCircuits
Revision as of 07:55, 12 January 2009 by Russ hensel (talk | contribs)
Jump to navigation Jump to search

Introduction

This is the very beginning of a Wiki for BoostC. Its organization will probably change a lot in the near future ( if we can get the free labor required ). It may move to the SourceBoost site if they want to host it. Since BoostC is proprietary it may be inappropriate for it to grow too big here unless we can find some explicit support for it. For now here it is.


Tips/Tricks/Gotchas

Watch out for set-bit!

The function set-bit() is almost right, but it should be set_bit(). This and similar errors are subtraction, and the result is error messages ( how about a sample ) that are not very helpful.

Rebuild It

Sometimes I have been able to get rid of odd errors by forcing a rebuild by erasing all but the project file and the .c and .h files. The manual suggests that Ctrl+F7 or Ctrl+build command do pretty much the same thing.

Subroutine signatures

Often we have several versions of a subroutine with different signatures ( set and type of call arguments ) Try to check that you are calling the version you want. Casting may help.


Standard C Issues

Links

Optimization

As a general rule it has been observed that many programmers spend too much time on optimization and that often the compiler can do a better job than the programmer. Often readability of the code suffers for "optimizations" that do not really optimize anything. That said, it is worthwhile to optimize the algorithm. C does not know the purpose of the code, the programmer should, the compiler can only optimize the code in doing what you said, not what you want.

Questions:

Optimizations that Seem Not to Work