electronics forum

Rules | Recent posts | topic RSS | Search | Register  | Log in

Possible MPLAB - PICC (HI-TECH) compiling bugs


Post new topic  Reply to topic    EDAboard.com Forum Index -> Microcontrollers -> Possible MPLAB - PICC (HI-TECH) compiling bugs
Author Message
gusman13



Joined: 15 Dec 2008
Posts: 1


Post04 Nov 2009 15:46   

Possible MPLAB - PICC (HI-TECH) compiling bugs


Compiler: HI-TECH PICC v9.60PL5 (PRO, Lite) & PICC v9.70PL0 (PRO,Lite)
MPLAB 8.40, 8.30
MPLAB HI-TECH Plug-In v1.35

Situations
------------
1) Defining two or more assembly instructions asm("instruction") in #define resulting in wrong code.

Code:

#include <htc.h>
#define nop() asm("nop")
#define testnop() { nop(); nop(); nop();}
#define testnop1() nop(); nop(); nop()

void main(void)
{
      /* Routine 1*/
      /* Routine 2*/
      testnop();
      /* Routine 3*/
      /* Routine 4*/
      /* Routine 5*/
}


The result assembly code is unexpected....

Code:

...
...
call routine2
NOP
call routine3
NOP
call routine4
NOP
...
...


It places 3 nops but one nop before every other command or call...
Strange thing is that in HI-TIDE v3.15PL2 there is no problem. 3 NOP in the right place.

2) Wrong bit assignment of 'c', 'z' etc in Status register
3) Yesterday I wrote a program and somehow in asm("---") generated btfsc for btfss and vice-versa... I can't recall the situation so I can not reproduce the error...
Back to top
Google
AdSense
Google Adsense




Post04 Nov 2009 15:46   

Ads




Back to top
Arabic versionBulgarian versionCatalan versionCzech versionDanish versionGerman versionGreek versionEnglish versionSpanish versionFinnish versionFrench versionHindi versionCroatian versionIndonesian versionItalian versionHebrew versionJapanese versionKorean versionLithuanian versionLatvian versionDutch versionNorwegian versionPolish versionPortuguese versionRomanian versionRussian versionSlovak versionSlovenian versionSerbian versionSwedish versionTagalog versionUkrainian versionVietnamese versionChinese version
Post new topic  Reply to topic    EDAboard.com Forum Index -> Microcontrollers -> Possible MPLAB - PICC (HI-TECH) compiling bugs
Page 1 of 1 All times are GMT + 1 Hour
Similar topics:
Hi-Tech C PICC 7.87 with MPLAB 6.x / 7.x (2)
PICC + MPLAB + ICD2 is it possible??? (5)
How to integrate PICC compiler in MPLAB 7.x? (2)
Proteus+Hi Tech PICC combination (10)
HI-TECH PICC PIC C18 (2)
programming with (hi-tech)picc (3)
about Hi-Tech PicC-lite (6)
hi tech picc 18 compiler version 8.20 (2)
Delay routines for HI-TECH PICC ? (2)
Hi-Tech PICC and Proteus VSM (2)


Abuse || Administrator || Moderators || Support us || sitemap
topic RSS