Turns out that the documentation we relied on was bogus; SCPCD confirmed
this (from the Jaguar netlists) as well. Thanks to Bastian (42bs) for
the patch! :-)
//static PTR fixupPtr = { .tk = (fixupExpr + 1) }; // C99 \o/
static PTR fixupPtr = { (uint8_t *)(fixupExpr + 1) }; // meh, it works
//static PTR fixupPtr = { .tk = (fixupExpr + 1) }; // C99 \o/
static PTR fixupPtr = { (uint8_t *)(fixupExpr + 1) }; // meh, it works
//
// The main Object Processor assembler. Basically just calls the sub functions
// to generate the appropriate code.
//
// The main Object Processor assembler. Basically just calls the sub functions
// to generate the appropriate code.
return error("unknown OP opcode");
}
return error("unknown OP opcode");
}
static inline void GetSymbolUCFromTokenStream(char * s)
{
strcpy(s, string[tok[1]]);
static inline void GetSymbolUCFromTokenStream(char * s)
{
strcpy(s, string[tok[1]]);
static inline uint64_t CheckFlags(char * s)
{
GetSymbolUCFromTokenStream(s);
static inline uint64_t CheckFlags(char * s)
{
GetSymbolUCFromTokenStream(s);
//
// Define a bitmap object
// Form: bitmap <data>, <xloc>, <yloc>, <dwidth>, <iwidth>, <iheight>, <bpp>,
//
// Define a bitmap object
// Form: bitmap <data>, <xloc>, <yloc>, <dwidth>, <iwidth>, <iheight>, <bpp>,
//
// Define a scaled bitmap object
// Form: scbitmap <data>, <xloc>, <yloc>, <dwidth>, <iwidth>, <iheight>,
//
// Define a scaled bitmap object
// Form: scbitmap <data>, <xloc>, <yloc>, <dwidth>, <iwidth>, <iheight>,
-// Form: gpuobj <line #>, <userdata> (bits 14-63 of this object)
+// Form: gpuobj <userdata> (bits 3-63 of this object)
//
static int HandleGPUObject(void)
{
//
static int HandleGPUObject(void)
{
uint16_t eattr;
SYM * esym = 0;
uint16_t eattr;
SYM * esym = 0;
- if (expr(exprbuf, &eval, &eattr, &esym) != OK)
- return ERROR;
-
- if (!(eattr & DEFINED))
- return error("bad expression in y position");
-
- uint64_t ypos = eval;
-
- CHECK_COMMA;
-
if (expr(exprbuf, &eval, &eattr, &esym) != OK)
return ERROR;
if (expr(exprbuf, &eval, &eattr, &esym) != OK)
return ERROR;
- uint64_t p1 = 0x02 | ((ypos * 2) << 3) | (eval << 14);
+ uint64_t p1 = 0x02 | (eval << 3);
lastObjType = 2;
D_quad(p1);
lastObjType = 2;
D_quad(p1);
//
// Insert a branch object
// Form: branch VC <condition (<, =, >)> <line #>, <link addr>
//
// Insert a branch object
// Form: branch VC <condition (<, =, >)> <line #>, <link addr>
//
// Insert a stop object
// Form: stop
//
// Insert a stop object
// Form: stop
//
// Insert a phrase sized "NOP" in the object list (psuedo-op)
// Form: nop
//
// Insert a phrase sized "NOP" in the object list (psuedo-op)
// Form: nop
//
// Insert an unconditional jump in the object list (psuedo-op)
// Form: jump <link addr>
//
// Insert an unconditional jump in the object list (psuedo-op)
// Form: jump <link addr>
#define MAJOR 2 // Major version number
#define MINOR 2 // Minor version number
#define MAJOR 2 // Major version number
#define MINOR 2 // Minor version number
-#define PATCH 2 // Patch release number
+#define PATCH 3 // Patch release number