Teacup possible patch January 01, 2013 09:57PM |
Registered: 11 years ago Posts: 11 |
Re: Teacup possible patch January 02, 2013 07:12AM |
Registered: 13 years ago Posts: 7,616 |
Generation 7 Electronics | Teacup Firmware | RepRap DIY |
Re: Teacup possible patch January 02, 2013 09:28AM |
Registered: 13 years ago Posts: 7,616 |
Generation 7 Electronics | Teacup Firmware | RepRap DIY |
Re: Teacup possible patch January 02, 2013 05:44PM |
Registered: 11 years ago Posts: 11 |
Re: Teacup possible patch January 02, 2013 11:12PM |
Registered: 11 years ago Posts: 11 |
./Top_Vertex_X_logo_optional.gcode A-Z 81662 0-9 368578 * 141505 : 62.29 % ./Y_Rod_Clasp_4_off.gcode ........ A-Z 25929 0-9 114685 * 44585 : 61.93 % ./Lower_Vertex_Upper.gcode ....... A-Z 287576 0-9 1321574 * 500702 : 62.64 % ./Z_Motor_Mount_2_off.gcode ...... A-Z 256141 0-9 1179896 * 445627 : 62.70 % ./LowerVertex_cupcake.gcode ...... A-Z 58261 0-9 264303 * 101076 : 62.39 % ./Y_Idler_Mount.gcode ............ A-Z 65405 0-9 291736 * 113460 : 61.99 % ./Y_Rod_Setting_Jig.gcode ........ A-Z 29689 0-9 132666 * 51093 : 62.15 % ./Top_Vertex_X_4_off.gcode ....... A-Z 42949 0-9 194872 * 74292 : 62.44 % ./Top_Rod_Jig_70mm.gcode ......... A-Z 67342 0-9 308888 * 116759 : 62.66 % ./Lower_Vertex_Middle_4_off.gcode A-Z 86394 0-9 397807 * 149739 : 62.75 % ./Z_rod_clasp_4_off.gcode ........ A-Z 35614 0-9 158416 * 61427 : 62.01 % ./Y_Rod_Mount_2_off.gcode ........ A-Z 115330 0-9 525199 * 200108 : 62.48 % ./Top_Vertex_Y_2_off.gcode ....... A-Z 43333 0-9 196092 * 74945 : 62.38 % ./LowerVertex_4_off.gcode ........ A-Z 50195 0-9 226696 * 86943 : 62.31 % ./Z_Rod_Lower_Mount_2_off.gcode .. A-Z 243787 0-9 1097486 * 424358 : 62.16 % ./Lower_Vertex_Lower.gcode ....... A-Z 412148 0-9 1905730 * 718436 : 62.76 %character counts; 0-9 vs everything else.
Re: Teacup possible patch January 03, 2013 05:28AM |
Registered: 13 years ago Posts: 7,616 |
Quote
the DEBUG if statements are still tested even when #define DEBUG is not in the config.
Generation 7 Electronics | Teacup Firmware | RepRap DIY |
Re: Teacup possible patch January 03, 2013 09:42AM |
Registered: 13 years ago Posts: 7,616 |
Quote
Done the original way it consumes 8 bytes per reference and 10 bytes for the function.
With the SPEED/inline method 12 bytes per reference.
Generation 7 Electronics | Teacup Firmware | RepRap DIY |
Re: Teacup possible patch January 03, 2013 03:26PM |
Registered: 11 years ago Posts: 11 |
case 'G': next_target.G = read_digit.mantissa; #ifdef DEBUG if (DEBUG_ECHO && (debug_flags & DEBUG_ECHO)) serwrite_uint8(next_target.G); #endif break; case 'M': next_target.M = read_digit.mantissa; #ifdef DEBUG if (DEBUG_ECHO && (debug_flags & DEBUG_ECHO)) serwrite_uint8(next_target.M); #endif break;
case 'G': next_target.G = read_digit.mantissa; 758: 80 91 66 01 lds r24, 0x0166 75c: 80 93 40 01 sts 0x0140, r24 760: c4 c0 rjmp .+392 ; 0x8ea if (DEBUG_ECHO && (debug_flags & DEBUG_ECHO)) serwrite_uint8(next_target.G); #endif break; case 'M': next_target.M = read_digit.mantissa; 762: 80 91 66 01 lds r24, 0x0166 766: 80 93 41 01 sts 0x0141, r24 76a: bf c0 rjmp .+382 ; 0x8ea ... 8e6: 60 93 64 01 sts 0x0164, r22 serwrite_uint8(next_target.checksum_read); #endif break; } // reset for next field last_field = 0; 8ea: 10 92 3c 01 sts 0x013C, r1 read_digit.sign = read_digit.mantissa = read_digit.exponent = 0; 8ee: 10 92 66 01 sts 0x0166, r1 8f2: 10 92 67 01 sts 0x0167, r1 8f6: 10 92 68 01 sts 0x0168, r1 8fa: 10 92 69 01 sts 0x0169, r1 8fe: 10 92 6a 01 sts 0x016A, r1 } }G/M jumps to 0x8ea, which is after the switch statement.
case 'G': next_target.G = read_digit.mantissa; 8c4: 60 91 66 01 lds r22, 0x0166 8c8: 60 93 40 01 sts 0x0140, r22 8cc: 1a c1 rjmp .+564 ; 0xb02 if (DEBUG_ECHO && (debug_flags & DEBUG_ECHO)) serwrite_uint8(next_target.G); #endif break; case 'M': next_target.M = read_digit.mantissa; 8ce: 60 91 66 01 lds r22, 0x0166 8d2: 60 93 41 01 sts 0x0141, r22 8d6: 15 c1 rjmp .+554 ; 0xb02 ... afe: 60 93 64 01 sts 0x0164, r22 #ifdef DEBUG if (DEBUG_ECHO && (debug_flags & DEBUG_ECHO)) b02: 80 91 e7 03 lds r24, 0x03E7 b06: 87 ff sbrs r24, 7 b08: 05 c0 rjmp .+10 ; 0xb14 serwrite_uint8(next_target.checksum_read); b0a: 70 e0 ldi r23, 0x00 ; 0 b0c: 80 e0 ldi r24, 0x00 ; 0 b0e: 90 e0 ldi r25, 0x00 ; 0 b10: 0e 94 d7 1e call 0x3dae ; 0x3dae #endif break; } // reset for next field last_field = 0; b14: 10 92 3c 01 sts 0x013C, r1 read_digit.sign = read_digit.mantissa = read_digit.exponent = 0; b18: 10 92 66 01 sts 0x0166, r1 b1c: 10 92 67 01 sts 0x0167, r1 b20: 10 92 68 01 sts 0x0168, r1 b24: 10 92 69 01 sts 0x0169, r1 b28: 10 92 6a 01 sts 0x016A, r1 } }G/M jumps to 0xb02, which is a consolidated "if (DEBUG_ECHO && (debug_flags & DEBUG_ECHO))" test, followed by another jump 0xb14, after the switch. at the very least it is two extra cycles and a jump, 4 clock cycles maybe.
case 'G': next_target.G = read_digit.mantissa; 8c4: 60 91 66 01 lds r22, 0x0166 8c8: 60 93 40 01 sts 0x0140, r22 8cc: 1a c1 rjmp .+564 ; 0xb02 if (DEBUG_ECHO && (debug_flags & DEBUG_ECHO)) serwrite_uint8(next_target.G); break; case 'M': next_target.M = read_digit.mantissa; 8ce: 60 91 66 01 lds r22, 0x0166 8d2: 60 93 41 01 sts 0x0141, r22 8d6: 15 c1 rjmp .+554 ; 0xb02 ... afe: 60 93 64 01 sts 0x0164, r22 #ifdef DEBUG if (DEBUG_ECHO && (debug_flags & DEBUG_ECHO)) b02: 80 91 e7 03 lds r24, 0x03E7 b06: 87 ff sbrs r24, 7 b08: 05 c0 rjmp .+10 ; 0xb14 serwrite_uint8(next_target.checksum_read); b0a: 70 e0 ldi r23, 0x00 ; 0 b0c: 80 e0 ldi r24, 0x00 ; 0 b0e: 90 e0 ldi r25, 0x00 ; 0 b10: 0e 94 d7 1e call 0x3dae ; 0x3dae #endif break; } // reset for next field last_field = 0; b14: 10 92 3c 01 sts 0x013C, r1 read_digit.sign = read_digit.mantissa = read_digit.exponent = 0; b18: 10 92 66 01 sts 0x0166, r1 b1c: 10 92 67 01 sts 0x0167, r1 b20: 10 92 68 01 sts 0x0168, r1 b24: 10 92 69 01 sts 0x0169, r1 b28: 10 92 6a 01 sts 0x016A, r1 } }
Re: Teacup possible patch January 04, 2013 06:58AM |
Registered: 13 years ago Posts: 7,616 |
Generation 7 Electronics | Teacup Firmware | RepRap DIY |
Re: Teacup possible patch January 04, 2013 10:54AM |
Registered: 11 years ago Posts: 11 |
Re: Teacup possible patch January 04, 2013 02:40PM |
Registered: 11 years ago Posts: 11 |
Re: Teacup possible patch January 05, 2013 08:37AM |
Registered: 13 years ago Posts: 7,616 |
Quote
I [...] added a small M254 command to track how many times the movebuffer becomes completely empty and for how long ( pin change / scope ).
Generation 7 Electronics | Teacup Firmware | RepRap DIY |
Re: Teacup possible patch January 17, 2013 01:39AM |
Registered: 12 years ago Posts: 160 |