Initial revision
This commit is contained in:
48
util/ceg/defaults/storage/C_bss_cst.c
Normal file
48
util/ceg/defaults/storage/C_bss_cst.c
Normal file
@@ -0,0 +1,48 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_bss_cst( n, w, i)
|
||||
arith n, w;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0 || w == BSS_INIT) {
|
||||
switchseg( SEGBSS);
|
||||
dump_label();
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
for ( i = 0; i < n/EM_WSIZE; i++)
|
||||
conEM_WSIZE( (CAST_WSIZE) w);
|
||||
}
|
||||
}
|
||||
49
util/ceg/defaults/storage/C_bss_dlb.c
Normal file
49
util/ceg/defaults/storage/C_bss_dlb.c
Normal file
@@ -0,0 +1,49 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_bss_dlb( n, l, offs, i)
|
||||
arith n, offs;
|
||||
label l;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0) {
|
||||
switchseg( SEGBSS);
|
||||
dump_label();
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
for ( i = 0; i < n/EM_PSIZE; i++)
|
||||
relocEM_PSIZE( extnd_dlb( l), offs, ABSOLUTE);
|
||||
}
|
||||
}
|
||||
49
util/ceg/defaults/storage/C_bss_dnam.c
Normal file
49
util/ceg/defaults/storage/C_bss_dnam.c
Normal file
@@ -0,0 +1,49 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_bss_dnam( n, s, offs, i)
|
||||
arith n, offs;
|
||||
char *s;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0) {
|
||||
switchseg( SEGBSS);
|
||||
dump_label();
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
for ( i = 0; i < n/EM_PSIZE; i++)
|
||||
relocEM_PSIZE( extnd_dnam( s), offs, ABSOLUTE);
|
||||
}
|
||||
}
|
||||
49
util/ceg/defaults/storage/C_bss_ilb.c
Normal file
49
util/ceg/defaults/storage/C_bss_ilb.c
Normal file
@@ -0,0 +1,49 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_bss_ilb( n, l, i)
|
||||
arith n;
|
||||
label l;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0) {
|
||||
switchseg( SEGBSS);
|
||||
dump_label();
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
for ( i = 0; i < n/EM_PSIZE; i++)
|
||||
relocEM_PSIZE( extnd_ilb( l), 0, ABSOLUTE);
|
||||
}
|
||||
}
|
||||
49
util/ceg/defaults/storage/C_bss_pnam.c
Normal file
49
util/ceg/defaults/storage/C_bss_pnam.c
Normal file
@@ -0,0 +1,49 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_bss_pnam( n, s, i)
|
||||
arith n;
|
||||
char *s;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0) {
|
||||
switchseg( SEGBSS);
|
||||
dump_label();
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
for ( i = 0; i < n/EM_PSIZE; i++)
|
||||
relocEM_PSIZE( extnd_name( s), 0, ABSOLUTE);
|
||||
}
|
||||
}
|
||||
39
util/ceg/defaults/storage/C_con_cst.c
Normal file
39
util/ceg/defaults/storage/C_con_cst.c
Normal file
@@ -0,0 +1,39 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
|
||||
C_con_cst( c)
|
||||
arith c;
|
||||
{
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
conEM_WSIZE( (CAST_WSIZE) c);
|
||||
}
|
||||
39
util/ceg/defaults/storage/C_con_dlb.c
Normal file
39
util/ceg/defaults/storage/C_con_dlb.c
Normal file
@@ -0,0 +1,39 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_con_dlb( g, o)
|
||||
label g;
|
||||
arith o;
|
||||
{
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
relocEM_PSIZE( extnd_dlb( g), o, ABSOLUTE);
|
||||
}
|
||||
39
util/ceg/defaults/storage/C_con_dnam.c
Normal file
39
util/ceg/defaults/storage/C_con_dnam.c
Normal file
@@ -0,0 +1,39 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_con_dnam( g, o)
|
||||
char *g;
|
||||
arith o;
|
||||
{
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
relocEM_PSIZE( extnd_name( g), o, ABSOLUTE);
|
||||
}
|
||||
38
util/ceg/defaults/storage/C_con_ilb.c
Normal file
38
util/ceg/defaults/storage/C_con_ilb.c
Normal file
@@ -0,0 +1,38 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_con_ilb( l)
|
||||
label l;
|
||||
{
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
relocEM_PSIZE( extnd_ilb( l), 0, ABSOLUTE);
|
||||
}
|
||||
38
util/ceg/defaults/storage/C_con_pnam.c
Normal file
38
util/ceg/defaults/storage/C_con_pnam.c
Normal file
@@ -0,0 +1,38 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_con_pnam( p)
|
||||
char *p;
|
||||
{
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
relocEM_PSIZE( extnd_name( p), 0, ABSOLUTE);
|
||||
}
|
||||
40
util/ceg/defaults/storage/C_con_scon.c
Normal file
40
util/ceg/defaults/storage/C_con_scon.c
Normal file
@@ -0,0 +1,40 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_con_scon( s, n)
|
||||
char *s;
|
||||
arith n;
|
||||
{
|
||||
switchseg( SEGCON);
|
||||
dump_label();
|
||||
|
||||
for ( ; n-- > 0;)
|
||||
con1( (ONE_BYTE) *s++);
|
||||
}
|
||||
50
util/ceg/defaults/storage/C_hol_cst.c
Normal file
50
util/ceg/defaults/storage/C_hol_cst.c
Normal file
@@ -0,0 +1,50 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_hol_cst( n, w, i)
|
||||
arith n, w;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0 || w == BSS_INIT) {
|
||||
switchseg( SEGBSS);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
for ( i = 0; i < n/EM_WSIZE; i++)
|
||||
conEM_WSIZE( (CAST_WSIZE) w);
|
||||
}
|
||||
}
|
||||
51
util/ceg/defaults/storage/C_hol_dlb.c
Normal file
51
util/ceg/defaults/storage/C_hol_dlb.c
Normal file
@@ -0,0 +1,51 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_hol_dlb( n, l, offs, i)
|
||||
arith n, offs;
|
||||
label l;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0) {
|
||||
switchseg( SEGBSS);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
for ( i = 0; i < n/EM_PSIZE; i++)
|
||||
relocEM_PSIZE( extnd_dlb( l), offs, ABSOLUTE);
|
||||
}
|
||||
}
|
||||
51
util/ceg/defaults/storage/C_hol_dnam.c
Normal file
51
util/ceg/defaults/storage/C_hol_dnam.c
Normal file
@@ -0,0 +1,51 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_hol_dnam( n, s, offs, i)
|
||||
arith n, offs;
|
||||
char *s;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0) {
|
||||
switchseg( SEGBSS);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
for ( i = 0; i < n/EM_PSIZE; i++)
|
||||
relocEM_PSIZE( extnd_dnam( s), offs, ABSOLUTE);
|
||||
}
|
||||
}
|
||||
51
util/ceg/defaults/storage/C_hol_ilb.c
Normal file
51
util/ceg/defaults/storage/C_hol_ilb.c
Normal file
@@ -0,0 +1,51 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_hol_ilb( n, l, i)
|
||||
arith n;
|
||||
label l;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0) {
|
||||
switchseg( SEGBSS);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
for ( i = 0; i < n/EM_PSIZE; i++)
|
||||
relocEM_PSIZE( extnd_ilb( l), 0, ABSOLUTE);
|
||||
}
|
||||
}
|
||||
51
util/ceg/defaults/storage/C_hol_pnam.c
Normal file
51
util/ceg/defaults/storage/C_hol_pnam.c
Normal file
@@ -0,0 +1,51 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_hol_pnam( n, s, i)
|
||||
arith n;
|
||||
char *s;
|
||||
int i;
|
||||
{
|
||||
if ( i == 0) {
|
||||
switchseg( SEGBSS);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
bss( n);
|
||||
}
|
||||
else {
|
||||
switchseg( SEGCON);
|
||||
align_word();
|
||||
symbol_definition( extnd_hol( ++holno));
|
||||
|
||||
for ( i = 0; i < n/EM_PSIZE; i++)
|
||||
relocEM_PSIZE( extnd_name( s), 0, ABSOLUTE);
|
||||
}
|
||||
}
|
||||
38
util/ceg/defaults/storage/C_rom_cst.c
Normal file
38
util/ceg/defaults/storage/C_rom_cst.c
Normal file
@@ -0,0 +1,38 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_rom_cst( c)
|
||||
arith c;
|
||||
{
|
||||
switchseg( SEGROM);
|
||||
dump_label();
|
||||
|
||||
romEM_WSIZE( (CAST_WSIZE) c);
|
||||
}
|
||||
39
util/ceg/defaults/storage/C_rom_dlb.c
Normal file
39
util/ceg/defaults/storage/C_rom_dlb.c
Normal file
@@ -0,0 +1,39 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_rom_dlb( g, o)
|
||||
label g;
|
||||
arith o;
|
||||
{
|
||||
switchseg( SEGROM);
|
||||
dump_label();
|
||||
|
||||
relocEM_PSIZE( extnd_dlb( g), o, ABSOLUTE);
|
||||
}
|
||||
39
util/ceg/defaults/storage/C_rom_dnam.c
Normal file
39
util/ceg/defaults/storage/C_rom_dnam.c
Normal file
@@ -0,0 +1,39 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_rom_dnam( g, o)
|
||||
char *g;
|
||||
arith o;
|
||||
{
|
||||
switchseg( SEGROM);
|
||||
dump_label();
|
||||
|
||||
relocEM_PSIZE( extnd_name( g), o, ABSOLUTE);
|
||||
}
|
||||
38
util/ceg/defaults/storage/C_rom_ilb.c
Normal file
38
util/ceg/defaults/storage/C_rom_ilb.c
Normal file
@@ -0,0 +1,38 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_rom_ilb( l)
|
||||
label l;
|
||||
{
|
||||
switchseg( SEGROM);
|
||||
dump_label();
|
||||
|
||||
relocEM_PSIZE( extnd_ilb( l), 0, ABSOLUTE);
|
||||
}
|
||||
38
util/ceg/defaults/storage/C_rom_pnam.c
Normal file
38
util/ceg/defaults/storage/C_rom_pnam.c
Normal file
@@ -0,0 +1,38 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_rom_pnam( p)
|
||||
char *p;
|
||||
{
|
||||
switchseg( SEGROM);
|
||||
dump_label();
|
||||
|
||||
relocEM_PSIZE( extnd_name( p), 0, ABSOLUTE);
|
||||
}
|
||||
40
util/ceg/defaults/storage/C_rom_scon.c
Normal file
40
util/ceg/defaults/storage/C_rom_scon.c
Normal file
@@ -0,0 +1,40 @@
|
||||
#include <em.h>
|
||||
#include "mach.h"
|
||||
#include "back.h"
|
||||
|
||||
#if EM_WSIZE == 1
|
||||
#define conEM_WSIZE con1
|
||||
#define romEM_WSIZE rom1
|
||||
#define CAST_WSIZE ONE_BYTE
|
||||
#endif
|
||||
#if EM_WSIZE == 2
|
||||
#define conEM_WSIZE con2
|
||||
#define romEM_WSIZE rom2
|
||||
#define CAST_WSIZE TWO_BYTES
|
||||
#endif
|
||||
#if EM_WSIZE == 4
|
||||
#define conEM_WSIZE con4
|
||||
#define romEM_WSIZE rom4
|
||||
#define CAST_WSIZE FOUR_BYTES
|
||||
#endif
|
||||
|
||||
#if EM_PSIZE == 1
|
||||
#define relocEM_PSIZE reloc1
|
||||
#endif
|
||||
#if EM_PSIZE == 2
|
||||
#define relocEM_PSIZE reloc2
|
||||
#endif
|
||||
#if EM_PSIZE == 4
|
||||
#define relocEM_PSIZE reloc4
|
||||
#endif
|
||||
|
||||
C_rom_scon( s, n)
|
||||
char *s;
|
||||
arith n;
|
||||
{
|
||||
switchseg( SEGROM);
|
||||
dump_label();
|
||||
|
||||
for ( ; n-- > 0;)
|
||||
rom1( (ONE_BYTE) *s++);
|
||||
}
|
||||
Reference in New Issue
Block a user