gplink-1.5.0 #1285 (Nov 6 2016) Copyright (c) 1998-2016 gputils project Listing File Generated: 11/07/2016 02:36:48 AM Address Value Disassembly Source ------- ----- ----------- ------ ;-------------------------------------------------------- ; File Created by SDCC : free open source ANSI-C Compiler ; Version 3.6.0 #9615 (Linux) ;-------------------------------------------------------- ; PIC port for the 14-bit core ;-------------------------------------------------------- ; .file "bug01.c" list p=16f1718 radix dec include "p16f1718.inc" LIST ;========================================================================== ; Build date : Aug 13 2015 ; MPASM PIC16F1718 processor include ; ; (c) Copyright 1999-2015 Microchip Technology, All rights reserved ;========================================================================== NOLIST ;-------------------------------------------------------- ; external declarations ;-------------------------------------------------------- extern _LATA extern _LATB extern __sdcc_gsinit_startup ;-------------------------------------------------------- ; global declarations ;-------------------------------------------------------- global _main global PSAVE global SSAVE global WSAVE global STK12 global STK11 global STK10 global STK09 global STK08 global STK07 global STK06 global STK05 global STK04 global STK03 global STK02 global STK01 global STK00 sharebank udata_ovr 0x0070 PSAVE res 1 SSAVE res 1 WSAVE res 1 STK12 res 1 STK11 res 1 STK10 res 1 STK09 res 1 STK08 res 1 STK07 res 1 STK06 res 1 STK05 res 1 STK04 res 1 STK03 res 1 STK02 res 1 STK01 res 1 STK00 res 1 ;-------------------------------------------------------- ; global definitions ;-------------------------------------------------------- ;-------------------------------------------------------- ; absolute symbol definitions ;-------------------------------------------------------- ;-------------------------------------------------------- ; compiler-defined variables ;-------------------------------------------------------- ;-------------------------------------------------------- ; initialized data ;-------------------------------------------------------- ID_bug01_0 idata _cond db 0x00 ID_bug01_1 idata 0x0220 _at0x220 db 0x00 ID_bug01_2 idata 0x0221 _at0x221 db 0xff ;-------------------------------------------------------- ; overlayable items in internal ram ;-------------------------------------------------------- ; udata_ovr ;-------------------------------------------------------- ; reset vector ;-------------------------------------------------------- STARTUP code 0x0000 000000 0000 nop nop 000001 3180 movlp 0x00 pagesel __sdcc_gsinit_startup 000002 2803 goto 0x0003 goto __sdcc_gsinit_startup ;-------------------------------------------------------- ; code ;-------------------------------------------------------- code_bug01 code ;*** ; pBlock Stats: dbName = M ;*** ;has an exit ;; Starting pCode block S_bug01__main code _main: ; 2 exit points _00112_DS_: ; .line 31; "bug01.c" if (at0x220) { 0000b2 0024 movlb 0x04 BANKSEL _at0x220 0000b3 0820 movf 0x20, 0x0 MOVF (_at0x220 + 0),W 0000b4 0421 iorwf 0x21, 0x0 IORWF (_at0x220 + 1),W 0000b5 1903 btfsc 0x03, 0x2 BTFSC STATUS,2 0000b6 28bb goto 0x00bb GOTO _00106_DS_ ; .line 32; "bug01.c" LATA = 0x11; 0000b7 3011 movlw 0x11 MOVLW 0x11 0000b8 0022 movlb 0x02 BANKSEL _LATA 0000b9 008c movwf 0x0c MOVWF _LATA 0000ba 28be goto 0x00be GOTO _00107_DS_ _00106_DS_: ; .line 34; "bug01.c" LATA = 0x22; 0000bb 3022 movlw 0x22 MOVLW 0x22 0000bc 0022 movlb 0x02 BANKSEL _LATA 0000bd 008c movwf 0x0c MOVWF _LATA _00107_DS_: ; .line 37; "bug01.c" if (cond) { 0000be 3000 movlw 0x00 MOVLW 0x00 0000bf 0039 movlb 0x19 BANKSEL _cond 0000c0 042c iorwf 0x2c, 0x0 IORWF _cond,W 0000c1 1903 btfsc 0x03, 0x2 BTFSC STATUS,2 0000c2 28c7 goto 0x00c7 GOTO _00109_DS_ ; .line 38; "bug01.c" LATB = 0x33; 0000c3 3033 movlw 0x33 MOVLW 0x33 0000c4 0022 movlb 0x02 BANKSEL _LATB 0000c5 008d movwf 0x0d MOVWF _LATB 0000c6 28b2 goto 0x00b2 GOTO _00112_DS_ _00109_DS_: ; .line 40; "bug01.c" LATB = 0x44; 0000c7 3044 movlw 0x44 MOVLW 0x44 0000c8 0022 movlb 0x02 BANKSEL _LATB 0000c9 008d movwf 0x0d MOVWF _LATB 0000ca 28b2 goto 0x00b2 GOTO _00112_DS_ 0000cb 0008 return RETURN ; exit point of _main ; code size estimation: ; 20+ 6 = 26 instructions ( 64 byte) end LIST ;========================================================================== ; Build date : Aug 13 2015 ; MPASM PIC16F1934 processor include ; ; (c) Copyright 1999-2015 Microchip Technology, All rights reserved ;========================================================================== NOLIST LIST ;========================================================================== ; Build date : Aug 13 2015 ; MPASM PIC16F1718 processor include ; ; (c) Copyright 1999-2015 Microchip Technology, All rights reserved ;========================================================================== NOLIST