This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

inline code generation vs libs


Hello,

I am working with the m68hc11 / m68hc12 gcc port for a school project. I have noticed that the vast majority of 32 bit operations (this is a 16 bit architecture) are implemented inline, via define_insn / define_expand / define_split instead of being implemented as libcalls.

How much does GCC actually benefit from this implementation? I am aware that providing patterns with a wide range of alternatives might help the compiler, especially in such a register-starved architecture. But considering that the simplest 32 bit left shift consists of the 7 byte sequence: asld xgdx rolb rola xgdx makes me wonder whether a library based implementation would have been better.

Or is this simply a question of trading off -Os performance for -O3 performance?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]