Bug 192 - Weird opcode in the output listing
Summary: Weird opcode in the output listing
Status: RESOLVED INVALID
Alias: None
Product: RMAC
Classification: Unclassified
Component: Core (show other bugs)
Version: unspecified
Hardware: PC Windows
: Normal major
Assignee: Shamus Hammons
URL:
Depends on:
Blocks:
 
Reported: 2022-02-03 09:32 CST by djipi.mari
Modified: 2022-04-17 00:45 CDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description djipi.mari 2022-02-03 09:32:16 CST
The -l option used to create an output listing can generate weird opcode (xxxx).

Such as on 68000
21  00000004  41F9xxxxxxxx           		lea     gpu_code1,a0
32  0000003A  43F9xxxxxxxx           		lea     _end_code3,a1

With .dsp, the following output is generated
17  00000014  xxxx                   		jr	mi, DSP_LSP_routine_interruption_I2S_pas_fin_de_sample_channel3
46  0000003C  xxxx                   		jr	eq, DSP_LSP_routine_interruption_I2S_pas_nouveau_long_word3

The symbols used are in the same source file but located below/after the code using the symbols.
Comment 1 ggn 2022-02-05 07:38:52 CST
Hello,

Unless I didn't understand what you're describing, this is normal. From the manual (http://rmac.is-slick.com/manual/manual/#things-you-should-be-aware-of)

In listings, the object code for forward references is not shown. Instead, lower- case "xx"s are displayed for each undefined byte, as in the following example:

60xx      1: bra.s.2  ;forward branch
xxxxxxxx     dc.l .2  ;forward reference
60FE     .2: bra.s.2  ;backward reference

-------------------------

So if the symbols you're trying to reference are defined after the line is printed to the listing, the assembler still has no visibility, thus you get xx characters.

Hope this clears things a bit. If you have some small use case that demonstrates the opposite, feel free to attach it here. Otherwise we can close this one.
Comment 2 djipi.mari 2022-02-05 15:10:30 CST
Yes, I remember now Rmac does an one pass.

Regarding the usage, I have ported an old Atari tool named JWARN.
"Atari Jaguar wait states warning generator" for the dsp and gpu only.
It originally uses the GASM output listing format and I did a modification to handle the Rmac one.

In this particular case, I guess to have a partial opcode for the dsp/gpu is not possible. So, I will add a check error in JWARN to prevent wrong report.