From 5d4e4f6cec3c8c2ad6bbbd016acf21cd8a19651c Mon Sep 17 00:00:00 2001 From: dmcoles Date: Mon, 8 Jul 2024 11:15:19 +0100 Subject: [PATCH] add module version 14 supoprt to showmodule & FindModule fix legacy compile mode so it doesnt include changes in module version 14 --- E-VO.S | 9 ++++++--- Technical_info.txt | 7 ++++--- tools/FindModule/FindModule.e | 17 +++++++++++++++-- tools/ShowModule/ShowModule.e | 17 +++++++++++++++-- 4 files changed, 40 insertions(+), 10 deletions(-) diff --git a/E-VO.S b/E-VO.S index 112708f..b7e9714 100644 --- a/E-VO.S +++ b/E-VO.S @@ -10092,8 +10092,8 @@ SRCFN: DC.L 0 EROBJLINE: DC.B 'WITH: %s',10,0 DC.B '$VER:' TITLE: DC.B 'E-VO',160,'E',160,'Compiler' - DC.B '/Assembler/Linker/PP',160,'v3.8.0',160 - DC.B '(28.06.2024)' + DC.B '/Assembler/Linker/PP',160,'v3.8.1-dev',160 + DC.B '(08.07.2024)' DC.B 10,'developing as "EC"',160 DC.B '''1991-97',160,'by Wouter van Oortmerssen',10 DC.B 'developing as "GEC"',160 @@ -11658,8 +11658,11 @@ SYMEND: MOVE.L A5,A1 ; A1=BACKUP A5 MOVE.L D0,A0 ; A0=GLOBINFO ADDQ.L #1,D1 + BTST #5,ICODEPREFS+3 ;LEGACY MODE + BNE.S .LEG MOVE.W 10(A4),(A5)+ ;save regoffs - BTST #2,5(A4) +.LEG + BTST #2,5(A4) BEQ.S .NNAME MOVE.L (A0),A3 ; ASCIIPTR MOVE.L A5,A2 diff --git a/Technical_info.txt b/Technical_info.txt index 3cf0114..3242fbe 100644 --- a/Technical_info.txt +++ b/Technical_info.txt @@ -783,15 +783,16 @@ OBJECT emodule ENDOBJECT 8 OBJECT globals - oldoffs (vers>=14) original regoffs value (-1 also signals end) - len:INT any #until len=-1 (*) + oldoffs:INT (vers>=14) original regoffs value (-1 also signals end) (***) + len:INT any #until len=-1 (*) (****) ascii[len]:ARRAY if len>0 codeoff[]:ARRAY OF off (vers>=10)?(LONG,opersize:INT):LONG NIL:LONG ENDOBJECT (*) also 0 for private globals - also $8000: next LONG is skipsize. real len follows (off=6) + (***) version>=14 also $8000: next LONG is skipsize. real len follows (off=6) + (****) version<14 also $8000: next LONG is skipsize. real len follows (off=6) 9 OBJECT modinfo skiplen:LONG diff --git a/tools/FindModule/FindModule.e b/tools/FindModule/FindModule.e index 5a3fd96..67aeaae 100644 --- a/tools/FindModule/FindModule.e +++ b/tools/FindModule/FindModule.e @@ -6,7 +6,10 @@ ENUM ABORT=0,ERR_OPEN,ERR_NOMEM,ERR_TOONEW,ERR_JOBID,ERR_TEMP ENUM JOB_DONE,JOB_CONST,JOB_OBJ,JOB_CODE,JOB_PROCS, JOB_SYS,JOB_LIB,JOB_RELOC,JOB_GLOBS,JOB_MODINFO,JOB_DEBUG,JOB_MACROS -CONST MODVERS=13, -> upto which version we understand , MODVER = 11 for Creative, MODVER=12 for Evo 3.5.0 +CONST MODVERS=14, -> upto which version we understand + -> MODVER = 11 for Creative, MODVER=12 for Evo 3.5.0 + -> MODVER=13 FOR Evo 3.6.0 + -> MODVER=14 FOR Evo 3.8.0 SKIPMARK=$FFFF8000 DEF caseSensitive=TRUE @@ -396,7 +399,12 @@ PROC search(mem,flen,filename:PTR TO CHAR) HANDLE CASE JOB_GLOBS c:=0; IF o[]=SKIPMARK THEN o:=o+6 - WHILE (len:=o[]++)>=0 + IF thisvers>=14 + val:=o[]++ + ELSE + val:=0 + ENDIF + WHILE (val<>-1) ANDALSO ((len:=o[]++)>=0) IF aborted THEN Raise(ABORT) IF len match:=searchCompare(o) @@ -406,6 +414,11 @@ PROC search(mem,flen,filename:PTR TO CHAR) HANDLE c++ ENDIF WHILE ^o++ DO IF thisvers>=10 THEN o++ + IF thisvers>=14 + val:=o[]++ + ELSE + val:=0 + ENDIF ENDWHILE CASE JOB_MODINFO o:=o+4 diff --git a/tools/ShowModule/ShowModule.e b/tools/ShowModule/ShowModule.e index 77b06ec..e0391b7 100644 --- a/tools/ShowModule/ShowModule.e +++ b/tools/ShowModule/ShowModule.e @@ -25,7 +25,10 @@ ENUM JOB_DONE,JOB_CONST,JOB_OBJ,JOB_CODE,JOB_PROCS, ENUM ER_NONE,ER_FILE,ER_MEM,ER_USAGE,ER_JOBID, ER_BREAK,ER_FILETYPE,ER_TOONEW -CONST MODVERS=13, -> upto which version we understand , MODVER = 11 for Creative, MODVER=12 for Evo 3.5.0 +CONST MODVERS=14, -> upto which version we understand + -> MODVER = 11 for Creative, MODVER=12 for Evo 3.5.0 + -> MODVER=13 FOR Evo 3.6.0 + -> MODVER=14 FOR Evo 3.8.0 SKIPMARK=$FFFF8000 DEF flen,o:PTR TO INT,mem,handle=NIL,file[250]:STRING,thisvers=0,cmode=FALSE,emode=FALSE @@ -358,7 +361,12 @@ PROC process() CASE JOB_GLOBS c:=0; f:=TRUE IF o[]=SKIPMARK THEN o:=o+6 - WHILE (len:=o[]++)>=0 + IF thisvers>=14 + val:=o[]++ + ELSE + val:=0 + ENDIF + WHILE (val<>-1) ANDALSO ((len:=o[]++)>=0) IF len IF f PutS('DEF ') @@ -372,6 +380,11 @@ PROC process() c++ ENDIF WHILE ^o++ DO IF thisvers>=10 THEN o++ + IF thisvers>=14 + val:=o[]++ + ELSE + val:=0 + ENDIF ENDWHILE IF f=FALSE THEN PutS('\n') IF c THEN PutF('/* \d private global variable(s) in this module */\n',c)