Thanks for the reply, I am still learning about arduino, but as these macros below are used by 'pinMode' and stuff, does this not mean the use EEPROM?
They use Flash (section of memory where code is stored).
Also those arrays I posted above use the PROGMEM keyword.
PROGMEM tells the linker to place the declaration exclusively in Flash.
The digitalWriteFast looks great, in fact it was a really great read. I need to test it and see how much runtime code is generated to do its final port manipulation.
One machine instruction if the pin and value are constants and the port is in "low" memory. I think it's three (six if interrupts are disabled) machine instructions if the port is in "high" memory (only applicable to the 1280 family). If pin is a variable the "old" function is used. I have no idea how it handles a variable value.
Teensyduino has a variation that really squeezes the best possible speed out of the functions.
My plans will hopefully shave a few more instructions off into compile time. But it may have already knocked these ideas on their head.
I wish you the best of luck! I'm a big fan of tweaking the core.