I also notice there is assembly language at video_gen.cpp.
asm volatile (
//save PORTB
"IN r16,%[port]\n\t"
"ANDI r16,0xFD\n\t"
".macro output\n\t"
"BLD r16,0\n\t" //output pin of the port here pinB0
"OUT %[port],r16\n" //and on the last line of asm
".endm\n"
".macro pixeldelay\n\t" // delay time for setting pixel width
"NOP\n\t" // one can be removed for smaller
"NOP\n\t" // pixels dont forget to remove the
"NOP\n\t" // nop at the start of byteshift
".endm\n"
".macro byteshift\n\t"
"NOP\n\t"
"BST tmp_reg,7\n\t"
"output\n\t"
"pixeldelay\n\t"
"BST tmp_reg,6\n\t"
"output\n\t"
"pixeldelay\n\t"
"BST tmp_reg,5\n\t"
"output\n\t"
"pixeldelay\n\t"
"BST tmp_reg,4\n\t"
"output\n\t"
"pixeldelay\n\t"
"BST tmp_reg,3\n\t"
"output\n\t"
"pixeldelay\n\t"
"BST tmp_reg,2\n\t"
"output\n\t"
"pixeldelay\n\t"
"BST tmp_reg,1\n\t"
"output\n\t"
"pixeldelay\n\t"
"BST tmp_reg,0\n\t"
"output\n"
".endm\n\t"
//output thingy
"LD tmp_reg,X+\n\t" //1
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //2
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //3
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //4
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //5
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //6
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //7
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //8
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //9
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //10
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //11
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //12
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //13
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //14
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //15
"byteshift\n\t"
"LD tmp_reg,X+\n\t" //16
"byteshift\n"
"EndLine_%=:\n\t"
"CBI %[port],0\n\t"
// assembly variable IO:
:
: [port] "i" (_SFR_IO_ADDR(PORTB)),
"x" (screenptr)
: "r16" // try to remove this clobber later...
);
renderLine+=16;