[En-Nut-Discussion] Code Optimization - Followup

Moritz Struebe morty at gmx.net
Mon Mar 3 12:44:09 CET 2008


Replacing the EEPROM_WRITE macro does not make too much sense, of course.
You might want to replace it, though:
#define EEPROM_WRITE(addr, src)  EEPROMWriteBytes(addr, (char*)&src, 
sizeof(src))

Cheers
Morty


Moritz Struebe schrieb:
> I'd also suggest changing functions like EEPROM_WRITE into "extern 
> inline" or "static inline" (probably "extern inline" is more 
> reasonable). This makes the code more easy to debug using O0, gives 
> you better compiler warnings and has no disadvantage as soon as you 
> use O1.




More information about the En-Nut-Discussion mailing list