Go to the first, previous, next, last section, table of contents.

Compiling on Hitachi H8/300 targets

The Hitachi H8/300 target family toolchain controls variances in code generation directly from the command line.

When you run GCC, you can use command-line options to choose whether to take advantage of the extra Hitachi H8/300 machine instructions, and whether to generate code for hardware or software floating point.

Using C++ for the Hitachi H8/300

This special release includes support for the C++ language. This support may in certain circumstances add up to 5K to the size of your executables.

The new C++ support involves new startup code that runs C++ initializers before `main()' is invoked. If you have a replacement for the file `crt0.o' (or if you call `main()' yourself) you must call `_main()' before calling `main()'.

You may need to run these C++ initializers even if you do not write in C++ yourself. This could happen, for instance, if you are linking against a third-party library which itself was written in C++. You may not be able to tell that it was written in C++ because you are calling it with C entry points prototyped in a C header file. Without these initializers, functions written in C++ may malfunction.

If you are not using any third-party libraries, or are otherwise certain that you will not require any C++ constructors you may suppress them by adding the following definition to your program:

  int __main() {}


Go to the first, previous, next, last section, table of contents.