in the below code mov A,80h does not work correctly.There seems to be 0FFh in 80h but mov A,80h makes A=0;
MOV P0,#00H ; P0=0 MOV P1,#01H ; P1=1 PLOOP1: ; CALL DELAY PLOOP2: MOV A,P1 CJNE A,#0,PLOOP2 PLOOP3: MOV A,P1 CJNE A,#1,PLOOP3 MOV A,80H MOV A,0A0H MOV A,0A1H MOV A,0A2H MOV A,0A3H MOV A,P0 CPL A MOV P0,A JMP PLOOP1
"...therefore I think it is a compiler bug..."
What compiler are you talking about?
You've got some (rather poorly written) assembler and you're describing what a simulator is reporting.