This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

LPP that works

Is there anyone but me that would benifit from a utility to combine C and assembly? I have found that LPP almost never works. According to this tread there are others that have also encountered problems http://www.keil.com/forum/docs/thread729.asp

I know it can be done because we use another compiler for the HC16 and it works flawlessly.

Here is an example. Note that absolute addresses have even been inserted. My guess is that they are using their equivalent to an OMF file to generate this.

19330                   	_TPA_allowed:
19331                   	
19333 47692 T 340C      		pshm	y,x
19334 47694 T 274F      		tsx	
19335 47696 T           		.set	OFST=2
19336                   	
19338                   	; 2131     BOOLEAN allowed = FALSE;
19339 47696 T 0501      		clr	OFST-1,x
19340 47698 T           	; 2132  
19341                   	; 2133     if ( TPA_faults == TPA_NO_FAULTS )
19342                   	
19344 47698 T F50C      		ldk	#.__data__
19345 4769A T 27FA      		tbek	
19346 4769C T 17F536B2  		ldab	L34_TPA_faults
19347 476A0 T B600      		bne	L17101
19348 476A2 T           	; 2134     {  allowed = TRUE;
19349                   	
19351 476A2 T F501      		ldab	#1
19352 476A4 T CA01      		stab	OFST-1,x
19353 476A6 T           	L17101:		; line 2136, offset 19
19354                   	; 2135     }
19355                   	; 2136     return(allowed);
19356                   	
19358 476A6 T C501      		ldab	OFST-1,x
19359 476A8 T 3705      		clra	
19360 476AA T           	
19362 476AA T 3518      		pulm	y,x
19363 476AC T 27F7      		rts	
19364 476AE T           	; 2137  }
Maybe if we cry hard enough Keil will make this a priority. ;-)

-Walt

Parents
  • As the originator of the thread you cited, I would certainly find a proper Source+Assembler listing useful.

    The debugger does give a source+assembler listing, but the trouble is that it can't be printed, and you can't go to a specific line and say, "show me the source+assembler"

    Using the SRC directive has been suggested, but I have heard it said that this disables (most) optimisations - so it wouldn't necessarily be representative.

    Apparently, the LX51 Linker (for the 8051 tools) can produce a disassembly listing of the absolute object - I haven't tried this yet, so I don't know if it's any good!

    "Maybe if we cry hard enough Keil will make this a priority"

    I think we'd have to cry very hard indeed :-(

    However, I do think that uVision still has a number of deficiencies which still warrant a higher priority than this.
    I've got a little list...

Reply
  • As the originator of the thread you cited, I would certainly find a proper Source+Assembler listing useful.

    The debugger does give a source+assembler listing, but the trouble is that it can't be printed, and you can't go to a specific line and say, "show me the source+assembler"

    Using the SRC directive has been suggested, but I have heard it said that this disables (most) optimisations - so it wouldn't necessarily be representative.

    Apparently, the LX51 Linker (for the 8051 tools) can produce a disassembly listing of the absolute object - I haven't tried this yet, so I don't know if it's any good!

    "Maybe if we cry hard enough Keil will make this a priority"

    I think we'd have to cry very hard indeed :-(

    However, I do think that uVision still has a number of deficiencies which still warrant a higher priority than this.
    I've got a little list...

Children