CW HCS08 SE 5.0 linker bug?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

CW HCS08 SE 5.0 linker bug?

2,584 次查看
mikehuslig
Contributor I
I have an assembler only HCS08GB60 project with 18 *.asm files.  I set the .prm file so that, I believe, the Smart linking is turned off.
 
One of the files near the middle of the link order is having problems.  Everything assembles and links without generating error messages.  However, inspection of the generated binary from this file, either in the .abs.s19 file or in the debugger, shows that the JSR instructions have incorrect destination addresses.  The other linked files don't seem to have a problem and I don't see anything different in the structure of the different .asm files.
 
Anyone see something like this before?
 
Is there a way to generate a complete ".abs.lst" file that has all the files linked?
 
Mike
 
标签 (1)
标记 (1)
0 项奖励
回复
3 回复数

1,207 次查看
mikehuslig
Contributor I
As another followup, Freescale confirmed the bug was in the Macro assembler.  They gave me a workaround by using XDEFs for my local addresses that were not being generated properly.  (I found that LDHX #local_address were also affected).  I asked what was different in this file that might be causing the problem.  They said they would forward my question to the appropriate people, but have yet to get a response.
 
Mike
 
0 项奖励
回复

1,207 次查看
CrasyCat
Specialist III

Hello

You can disassemble a full absolute file in the following way:
  - Click with the right mouse button in the .mpc window
  - Select "Add Files"
  - Add the generated .abs file to your project
  - Click with the right mouse button on the .abs file name in the .mcp window
  - Select disassemble. A new window will be opened containing the
     disassembly code for the absolute file.

Make sure to remove the .abs file from the project before next rebuild.
Around why you get wrong jump address, I cannot tell.

I would suggest you to submit a service request to our support team through our web interface.

CrasyCat

1,207 次查看
mikehuslig
Contributor I

Thanks for the tip on generating the complete listing.  It clearly shows the incorrect addresses.

As a follow-up, I downloaded 5.1 onto another computer, but it generates the same errors.

I found that the JSRs with incorrect addresses were supposed to go to addresses in the same file (local address), but the incorrect addresses were also labeled addresses in the same file.  One JSR to a local address was correct and all JSRs to external addresses were correct.

Mike

 

0 项奖励
回复