cross - compile with mips4Kc instructions

Oct 22, 2005 2 Replies

Hi all,



I am working on Mips32 -4Kc processor. when i cross-compile the C-code on linux using "mipsel-linux-gcc" toolchain and observe the listing (assembly) , it is not using the features of the Mips32 -4Kc instructions, but using only MIPS-I ISA instruction set.



I even used "-Wa,-mips2 -Wa,-mips32 -Wa,-march=4Kc " option as: mipsel-linux-gcc -S -Wa,-mips2 -Wa,-mips32 -Wa,-march=4Kc main.c



But i want to get my C-code get cross-compiled with all features of the Mips32 -4Kc instructions (like CLZ, CLO, MOVN, MOVZ, MADD MSUB ) for better performance.



Can this be done??



bye Raju



Try -march=4kc (i.e. without the -Wa part).

Steve.

You'll have to brush up on what the individual GCC options mean. Those flags you listed are all telling the compiler driver to tell the

*assembler* to use those special instruction. That is rather unlikely to achieve anything in the compiler proper. -march=mips4000 or something like that would be closer to home. See 'info gcc invoking submodel mips'.
Hans-Bernhard Broeker (broeker@physik.rwth-aachen.de) Even if all the snow were burnt, ashes would remain.

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required