3 Jul 19:25
[PIC] : hitech compiler - deliberately generating poor code in free version?
From: Mike Harrison <mike <at> whitewing.co.uk>
Subject: [PIC] : hitech compiler - deliberately generating poor code in free version?
Newsgroups: gmane.comp.hardware.microcontrollers.pic
Date: 2009-07-03 17:26:42 GMT
Subject: [PIC] : hitech compiler - deliberately generating poor code in free version?
Newsgroups: gmane.comp.hardware.microcontrollers.pic
Date: 2009-07-03 17:26:42 GMT
(posted before but forgot tag....) WTF is going on with the Hi-Tech compiler that ships with MPLAB.... A few samples below (all vars are global chars)., target 16F818 Can anyone think of any explanation for such poor code generation other than deliberately making it slow to make their paid-for compiler look better ? It can't be doing Microchip any favours shipping such a poor performing compiler with MPLAB as it makes their chips look slow and inefficient. 365: irrxsum1+=irbyte1; 115 087A MOVF 0x7a, W 116 00C3 MOVWF 0x43 117 0843 MOVF 0x43, W 118 07F4 ADDWF 0x74, F Should be 2 instructions 366: ircnt1=0; 119 1003 BCF 0x3, 0 11A 3000 MOVLW 0 11B 1803 BTFSC 0x3, 0 11C 3001 MOVLW 0x1 11D 00FB MOVWF 0x7b This is especially bizarre - should be 1 CLRF instruction 349: irtmr1+=bittime2; // bittime2 is a constant 0DF 300E MOVLW 0xe(Continue reading)
RSS Feed