🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by taylor Wed, 10 May 1989 23:05
gas (ns32k) doesn't recognize label(pc)
#1598
Author: taylor
Date: Wed, 10 May 1989 23:05
24 lines
1056 bytes
[I mailed this on Sunday, but it doesn't seem to have made it out.  My
apologies if this is a repeat. -- David]

When compiled for the ns32k, gas doesn't recognize an operand of
`some_label(pc)' as meaning that it should access the label via
pc-relative memory space addressing.  Instead it ignores the `(pc)' and
assembles the operand using absolute addressing.

The fix is easy.  In ns32k.c, in the function `addr_mode', add the lines:

        if (!strncmp(&str[strl-4],"(pc",3)) {
	  mode=27;
	}

right after the lines that read:

        if (!strncmp(&str[strl-4],"(sb",3)) {
	  mode=26;
	}

David
--
David Taylor
taylor@think.com, ...!think!taylor
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads