Commit 55198f01 authored by Robert Sprowson's avatar Robert Sprowson
Browse files

Make debug versions assemble again.

Entry macro renamed as SemEntry to avoid conflict with Hdr:Proc.
Other macro bit rot fixed up.
Tidy up switches.
DebugFx switch is the only one that doesn't work.
Non debug binary same as 3.41.

Version 3.42. Tagged as 'FileCore-3_42'
parent ad94a5c8
......@@ -11,13 +11,13 @@
GBLS Module_HelpVersion
GBLS Module_ComponentName
GBLS Module_ComponentPath
Module_MajorVersion SETS "3.41"
Module_Version SETA 341
Module_MajorVersion SETS "3.42"
Module_Version SETA 342
Module_MinorVersion SETS ""
Module_Date SETS "13 Sep 2011"
Module_ApplicationDate SETS "13-Sep-11"
Module_Date SETS "02 Oct 2011"
Module_ApplicationDate SETS "02-Oct-11"
Module_ComponentName SETS "FileCore"
Module_ComponentPath SETS "castle/RiscOS/Sources/FileSys/FileCore"
Module_FullVersion SETS "3.41"
Module_HelpVersion SETS "3.41 (13 Sep 2011)"
Module_FullVersion SETS "3.42"
Module_HelpVersion SETS "3.42 (02 Oct 2011)"
END
/* (3.41)
/* (3.42)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 3.41
#define Module_MajorVersion_CMHG 3.42
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 13 Sep 2011
#define Module_Date_CMHG 02 Oct 2011
#define Module_MajorVersion "3.41"
#define Module_Version 341
#define Module_MajorVersion "3.42"
#define Module_Version 342
#define Module_MinorVersion ""
#define Module_Date "13 Sep 2011"
#define Module_Date "02 Oct 2011"
#define Module_ApplicationDate "13-Sep-11"
#define Module_ApplicationDate "02-Oct-11"
#define Module_ComponentName "FileCore"
#define Module_ComponentPath "castle/RiscOS/Sources/FileSys/FileCore"
#define Module_FullVersion "3.41"
#define Module_HelpVersion "3.41 (13 Sep 2011)"
#define Module_LibraryVersionInfo "3:41"
#define Module_FullVersion "3.42"
#define Module_HelpVersion "3.42 (02 Oct 2011)"
#define Module_LibraryVersionInfo "3:42"
......@@ -17,9 +17,6 @@
TTL "Big directory support code"
[ BigDir
GBLL MBFix
MBFix SETL T
; ==========
; TestBigDir
; ==========
......@@ -1601,9 +1598,8 @@ GrowBigDir ROUT
; loop among Fcbs until we find that matches. if it does, then we
; then have to adjust it
[ MBFix
BL ReadIndDiscAdd
]
sbaddr r1, FirstFcb-FcbNext
B %FT02
01
......@@ -1612,11 +1608,7 @@ GrowBigDir ROUT
DREG r8, "File in chain:"
]
[ MBFix
CMP r8,lr
|
CMPS R8, r1
]
CMP r8, lr
BNE %FT02
[ DebugXg
DLINE "matches file we're interested in"
......@@ -1645,11 +1637,7 @@ GrowBigDir ROUT
; now if we found a matching Fcb, update its ind disc address
CMP R1, #-1
[ MBFix
STRNE R2, [R1, #FcbIndDiscAdd]
|
STREQ R2, [R1, #FcbIndDiscAdd]
]
BL UnlockMap ; unlock the map
B %BT10 ; and try going round the loop again
......@@ -1698,7 +1686,7 @@ GrowBigDir ROUT
; only need IndDiscAdd and Len to be valid in the dummy entry.
[ F
[ {FALSE}
ADD R7, R7, #262144 ; 64K allocation?
MOV R10, R7
|
......
......@@ -113,7 +113,7 @@ BC3 DCB "BC3",0
ALIGN
DoBackup ROUT
Entry Flag,Light ;leaves SB,LR stacked
SemEntry Flag,Light ;leaves SB,LR stacked
Push "R7-R11"
SUB sp, sp, #BackupWork
......@@ -754,7 +754,7 @@ BackupSectionsExhausted
; >>>>>
DoBye ROUT
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
BL DoOsFunShutDown ;(->R0,V)
BLVS FindErrBlock ;(R0->R0,V)
BL FileCoreExit
......@@ -772,7 +772,7 @@ CMC3 DCB "CMC3",0
ALIGN
DoCheckMap
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
Push "R7-R11"
TEQS R1, #0
BLEQ IdentifyCurrentDisc ;(->R0,R3,V) if disc param missing
......@@ -1102,7 +1102,7 @@ DoCheckMap
; >>>>>>>>>
DoCompact
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
Push "R7-R11"
TEQS R1, #0
MOV R1, R0
......@@ -1440,7 +1440,7 @@ DC1 DCB "DC1",0
ALIGN
DoDefect
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
Push "R7-R11"
MOV R1, R0
MOV R2, #MustBeDisc
......@@ -2393,7 +2393,7 @@ UpdateBadBlockList ROUT
; >>>>>>>>>>
DoDismount ROUT
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
Push "R0"
[ DebugL
DSTRING r0, "Dismount on "
......@@ -2684,7 +2684,7 @@ DismountDisc
; >>>>>>>
DoDrive ROUT
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
MOV R1, R0 ;string ptr
BL ParseAnyDrive ;(R1->R0,Z,C,V)
STRVCB R0, Drive
......@@ -2778,7 +2778,7 @@ FCK1 DCB "FCK1",0
ALIGN
DoFree ROUT
Entry Flag, Dormant ;leaves SB,LR stacked
SemEntry Flag, Dormant ;leaves SB,LR stacked
MOV r5, sp
......@@ -3127,7 +3127,7 @@ MC6 DCB "MC6",0
ALIGN
DoMap ROUT
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
Push "R7-R11"
[ BigDisc
SUB SP, SP, #40 ;string buffer
......@@ -3520,7 +3520,7 @@ VerBad
; >>>>>>>>
DoVerify ROUT
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
Push "R7-R11"
TEQS R1, #0
......@@ -3575,7 +3575,7 @@ DoVerify ROUT
BHS %FT40
; SBP: 06 Feb 1997: ***** Fix to prevent silly long transfers on large discs during *verify (-ve numbers problem!)
[ T
[ {TRUE}
MOV r9,r0
BL MapPtrToDiscAdd
SUB r4,r0,r2
......
......@@ -14,205 +14,157 @@
;
; >DebugOpts
; change log.
; 15 May 1997: SBP: Added change log. Added BigMaps flag.
TTL "Debugging options"
GBLL T
T SETL {TRUE}
GBLL F
F SETL {FALSE}
GBLL BigDisc ; Increased space efficiency
BigDisc SETL {TRUE}
GBLL test_version
test_version SETL {FALSE}
GBLL BigDisc
BigDisc SETL T
GBLL BigShare
BigShare SETL T
GBLL UseBigFlag
GBLL TwoGigFix
TwoGigFix SETL T
UseBigFlag SETL T
GBLL DriveStatus
GBLL BigShare ; Look at share size in disc record
BigShare SETL {TRUE}
GBLL ServicePolice
ServicePolice SETL T
GBLL UseBigFlag ; Look at big flag in disc record
UseBigFlag SETL {TRUE}
; for Big free space maps (allowing idlen to be more than 15):
GBLL TwoGigFix ; Clamp OS_Args at 2^31
TwoGigFix SETL {TRUE}
GBLL BigMaps
BigMaps SETL T
GBLL ServicePolice ; Fast despatch table for service calls
ServicePolice SETL {TRUE}
; for big directories
GBLL BigMaps ; Big free space maps (allowing idlen to be more than 15)
BigMaps SETL {TRUE}
GBLL BigDir
BigDir SETL T
GBLL BigDir ; Big directories
BigDir SETL {TRUE}
GBLL DynamicMaps
DynamicMaps SETL T
GBLL DynamicMaps ; Maps go in dynamic areas
DynamicMaps SETL {TRUE}
GBLL BinaryChop
BinaryChop SETL T
GBLL BinaryChop ; Faster search in big directories
BinaryChop SETL {TRUE}
GBLL WriteCacheDir
WriteCacheDir SETL F
GBLL WriteCacheDir ; Cached directories
WriteCacheDir SETL {FALSE}
; increased space efficiency
GBLL BigDirFix ; Get the size of big directories right
BigDirFix SETL {TRUE}
GBLL BigDirFix
BigDirFix SETL T
GBLL BigDirFullBackup
BigDirFullBackup SETL {FALSE}
GBLL BigDirFullBackup
BigDirFullBackup SETL F
GBLL DriveStatus ; Use MiscOp_DriveStatus
DriveStatus SETL {TRUE}
DriveStatus SETL T
GBLL FullAtts ;T for extended attributes for new format dirs
FullAtts SETL T
GBLL FullAtts ; Extended attributes for new format dirs
FullAtts SETL {TRUE}
GBLL NewErrors
NewErrors SETL T
GBLL NewErrors ; Errors can be in top bit set addresses
NewErrors SETL {TRUE}
GBLL ExtraSkew
ExtraSkew SETL T ;T for F/G formats to suit Iyonix better
GBLL ExtraSkew ; Extra skew in F/G format floppies to suit Tungsten better
ExtraSkew SETL {TRUE}
GBLL Dev
Dev SETL test_version
GBLL Dev ; Extra code to do postmortem when things go bang
Dev SETL {FALSE}
GBLL Debug
[ Dev
Debug SETL T
|
Debug SETL F
]
GBLL Debug ; Debugging printout
Debug SETL {FALSE} :LOR: Dev
GBLL ExceptionTrap
GBLL VduTrap
GBLL SpoolOff
GBLL IrqDebug
GBLL DebugSwitch
ExceptionTrap SETL Dev :LAND: {FALSE}
ExceptionTrap SETL Dev :LAND: {FALSE}
VduTrap SETL Dev :LAND: {FALSE}
SpoolOff SETL Dev :LAND: {TRUE}
IrqDebug SETL Dev :LAND: {TRUE}
DebugSwitch SETL Dev :LAND: {FALSE}
MACRO
$a switch $b
GBLL $a
[ Dev
[ Debug ;>>>F
$a SETL $b
|
$a SETL F
]
|
$a SETL F
]
$a SETL $b :LAND: Debug
MEND
Debug1 switch F ;communication with parent module
Debug2 switch F ;SWI call processing
Debug2D switch T ;DiscOp SWI call processing
Debug3 switch F ;disc accesses
Debug3L switch F ;low level discops into parent
Debug4 switch F ;disc and drive record operations
Debug5 switch F ;old free space map operations
Debug6 switch F ;pathname and directory operations
Debug6f switch F ; FindDiscByName
Debug7 switch F ;OsFile operations
Debug8 switch F ;File Level Disc Ops
Debug9 switch F ;Misc useful routines
DebugA switch F ;OsFun operations
DebugB switch F ;Random access files
DebugBA switch F ;OS_Args specifically
DebugBE switch F ;BPut/BGet entry
DebugBc switch F ;CloseAllByDisc
DebugBe switch F ;Ensure file size
DebugBv switch F ;Random access files verbose - details of PutBytes and GetBytes
DebugBs switch F ;Open file new map allocated size
DebugBt switch F ;Random access file I/O terse
DebugC switch F ;Directory cache
DebugD switch F ;Scatter buffer
DebugE switch F ;new free space map
DebugEa switch F ;new free space map random extension
DebugEx switch F ; verbose new free space map
DebugEs switch F ; debugging of SortDir use in NewClaimFree
DebugF switch F ;new free space map: auto compact
DebugFx switch F ;new free space map: check for this bug
DebugG switch F ;verbose file cache
DebugGu switch F ;UpdateProcess only
DebugGs switch F ; UpdateProcess scatter list ends only
DebugH switch F ;terse file cache
DebugI switch F ;terse FIQ claim/release
DebugJ switch F ;file cache consistency checks
DebugK switch F ;setting of Interlocks
DebugL switch F ; Mounting/Identifying/Dismounting/Verifying
DebugLi switch F ; Changes to DiscId information in disc records
DebugLm switch F ; matching disc agianst other records
DebugM switch F ; MultiFS extensions
DebugMt switch F ; MultiFS extensions (terse)
DebugN switch F ; Disc insertion / request for insertion thread
DebugO switch F ; MultiFS extensions - formatting SWIs
DebugP switch F ; Process activation/deactivation
DebugQ switch F ; *-commands
DebugR switch F ; reentrance
DebugU switch F ; UpCall
Debugb switch F ; break key action updates
DebugDR switch F ; check array bounds on drive and disc record ptr calculation
DebugDL switch F ; check for data lost problems with atapi
DebugX switch F ; debug long filenames
DebugXg switch F ; debug long filenames - growin dirs
DebugXm switch F ; debug long filenames - memory problems
DebugXb switch F ; debug long filenames - binary chop dir search
DebugXr switch F ; debug long filenames - rename
DebugXd switch F ; debug long filenames - directory names
DebugCW switch F ; debug write cacheing of dirs
GBLL ExceptionTrap
GBLL VduTrap
[ Dev
[ Debug
ExceptionTrap SETL F
|
ExceptionTrap SETL F
]
VduTrap SETL F ;RCM>>> was T
GBLL SpoolOff
SpoolOff SETL F ;T <=> disable spooling for debug messages
GBLL IrqDebug
IrqDebug SETL F
GBLL DebugSwitch
DebugSwitch SETL F
|
ExceptionTrap SETL F
VduTrap SETL F
]
GBLS GetAroundBleedingAAsmYetAgain
[ Debug
GetAroundBleedingAAsmYetAgain SETS " GET Hdr:Debug"
|
GetAroundBleedingAAsmYetAgain SETS "; No debug required"
]
$GetAroundBleedingAAsmYetAgain
; +++++++++++++++++++++++ For Tube work: ++++++++++++++++++++++++++++++++++++++
[ Debug
; Set to true for dubugging through the tube
Host_Debug SETL T
Debug_MaybeIRQ SETL T
]
GBLS Host_Inclusion
Host_Inclusion SETS "; No Host debug wanted"
[ Debug
[ Host_Debug
Host_Inclusion SETS " GET Hdr:HostFS"
]
]
$Host_Inclusion
Debug1 switch {FALSE} ; communication with parent module
Debug2 switch {FALSE} ; SWI call processing
Debug2D switch {FALSE} ; DiscOp SWI call processing
Debug3 switch {FALSE} ; disc accesses
Debug3L switch {FALSE} ; low level discops into parent
Debug4 switch {FALSE} ; disc and drive record operations
Debug5 switch {FALSE} ; old free space map operations
Debug6 switch {FALSE} ; pathname and directory operations
Debug6f switch {FALSE} ; FindDiscByName
Debug7 switch {FALSE} ; OsFile operations
Debug8 switch {FALSE} ; File Level Disc Ops
Debug9 switch {FALSE} ; Misc useful routines
DebugA switch {FALSE} ; OsFun operations
DebugB switch {FALSE} ; Random access files
DebugBA switch {FALSE} ; OS_Args specifically
DebugBE switch {FALSE} ; BPut/BGet entry
DebugBc switch {FALSE} ; CloseAllByDisc
DebugBe switch {FALSE} ; Ensure file size
DebugBv switch {FALSE} ; Random access files verbose - details of PutBytes and GetBytes
DebugBs switch {FALSE} ; Open file new map allocated size
DebugBt switch {FALSE} ; Random access file I/O terse
DebugC switch {FALSE} ; Directory cache
DebugD switch {FALSE} ; Scatter buffer
DebugE switch {FALSE} ; new free space map
DebugEa switch {FALSE} ; new free space map random extension
DebugEx switch {FALSE} ; verbose new free space map
DebugEs switch {FALSE} ; debugging of SortDir use in NewClaimFree
DebugF switch {FALSE} ; new free space map: auto compact
DebugFx switch {FALSE} ; new free space map: check for this bug [switch broken!]
DebugG switch {FALSE} ; verbose file cache
DebugGu switch {FALSE} ; UpdateProcess only
DebugGs switch {FALSE} ; UpdateProcess scatter list ends only
DebugH switch {FALSE} ; terse file cache
DebugI switch {FALSE} ; terse FIQ claim/release
DebugJ switch {FALSE} ; file cache consistency checks
DebugK switch {FALSE} ; setting of Interlocks
DebugL switch {TRUE} ; Mounting/Identifying/Dismounting/Verifying
DebugLi switch {FALSE} ; Changes to DiscId information in disc records
DebugLm switch {FALSE} ; matching disc agianst other records
DebugM switch {FALSE} ; MultiFS extensions
DebugMt switch {FALSE} ; MultiFS extensions (terse)
DebugN switch {FALSE} ; Disc insertion / request for insertion thread
DebugO switch {FALSE} ; MultiFS extensions - formatting SWIs
DebugP switch {FALSE} ; Process activation/deactivation
DebugQ switch {FALSE} ; *-commands
DebugR switch {FALSE} ; reentrance
DebugU switch {FALSE} ; UpCall
Debugb switch {FALSE} ; break key action updates
DebugDR switch {FALSE} ; check array bounds on drive and disc record ptr calculation
DebugDL switch {FALSE} ; check for data lost problems with atapi
DebugX switch {FALSE} ; debug long filenames
DebugXg switch {FALSE} ; debug long filenames - growin dirs
DebugXm switch {FALSE} ; debug long filenames - memory problems
DebugXb switch {FALSE} ; debug long filenames - binary chop dir search
DebugXr switch {FALSE} ; debug long filenames - rename
DebugXd switch {FALSE} ; debug long filenames - directory names
DebugCW switch {FALSE} ; debug write cacheing of dirs
GBLS NeedHdrDebug
GBLS NeedHdrProc
GBLS NeedHdrHostFS
[ Debug
NeedHdrProc SETS "GET Hdr:Proc"
NeedHdrDebug SETS "GET Hdr:Debug"
|
NeedHdrDebug SETS "; No"
NeedHdrProc SETS "; No"
]
[ :DEF: Host_Debug
Host_Debug SETL {FALSE}
Debug_MaybeIRQ SETL {FALSE}
NeedHdrHostFS SETS "GET Hdr:HostFS"
|
NeedHdrHostFS SETS "; No"
]
$NeedHdrProc
$NeedHdrDebug
$NeedHdrHostFS
END
......@@ -116,7 +116,7 @@ RandomAccessExtend * FirstUnknown_fsfile+4
ASSERT RandomAccessExtend <= fsfile_Load
; VDU workspace
[ T
[ {TRUE}
WindowWidth * &100
|
LeftColumn * 8
......
......@@ -73,7 +73,7 @@ ModFlags
SectorSize # 1 ;log2 sector size
SecsPerTrk # 1
Heads # 1 ;n-1 for old adfs floppy format
Density # 1 ;1/2/4 single double quad
Density # 1 ;0/1/2/3/4/8 hard/single/double/double+/quad/octal
;only those above & DiscsDrv & Disc Size needed for low level drivers
......
......@@ -127,9 +127,9 @@ Divide ROUT
BlockMove ROUT
[ Debug9
DLINE ,"source |dest |length - enter BlockMove"
DLINE R0,\\\\ " ",cc
DLINE R1, " ",cc
DLINE R2, " "
DREG R0, " ",cc
DREG R1, " ",cc
DREG R2, " "
]
Push "R0-R12,LR"
SavePSR LR
......@@ -366,9 +366,9 @@ ZeroRam ROUT
[ Debug9
mess ,"start |length - enter ZeroRam",NL
wrhex R0
wrhex R1
mess ,NL
DREG R0
DREG R1
DLINE " "
]
Push "R0-R12,LR"
......
......@@ -225,26 +225,26 @@ AddressException
ExceptionCommon
mess ,"R0 R1 R2 R3 R4 R5 R6 R7",NL
wrhex R0
wrhex R1
wrhex R2
wrhex R3
wrhex R4
wrhex R5
wrhex R6
wrhex R7
mess ,NL,"R8 R9 R10 R11 R12 R13 R14",NL
wrhex R8
wrhex R9
wrhex R10
wrhex R11
wrhex R12
DREG R0
DREG R1
DREG R2
DREG R3
DREG R4
DREG R5
DREG R6
DREG R7
mess ,"R8 R9 R10 R11 R12 R13 R14",NL
DREG R8
DREG R9
DREG R10
DREG R11
DREG R12
LDR LR, [R0,-R0]
wrhex LR
DREG LR
LDR LR, [R13,#14*4]
wrhex LR
DREG LR
wrhex R13
DREG R13
mess ,NL
Push "r0-r2"
......@@ -257,7 +257,7 @@ ExceptionCommon
LDREQ r2, =Legacy_IRQsema
LDR lr, [r2]
Pull "r0-r2"
wrhex LR
DREG LR
mess ,"IRQsema",NL
EHANG
BAL EHANG
......
......@@ -1830,11 +1830,10 @@ Mount
CLRV
; Defect list bad - reject it and fill in some values that'll work
[ T
[ {TRUE}
MOV lr, #&10000
ORR lr, lr, #&100
ORR lr, lr, #&09
; LDR lr, =&00010109 ; density=0, heads=1, sides=1, sectorsize=512
|
LDR lr, =&0001010a ; density=0, heads=1, sides=1, sectorsize=1024
]
......
......@@ -473,7 +473,7 @@ SanityCheckDirCache ROUT
Pull "r0-r12,pc"
]
[ F
[ {FALSE}
; ===========
; CacheDirBuf
......
......@@ -71,11 +71,11 @@ MoveData
Push "R0-R11,LR"
[ DebugD
mess ,"options |source |dest |length |offset - enter MoveData",NL
wrhex R0
wrhex R1
wrhex R2
wrhex R3
wrhex R4
DREG R0
DREG R1
DREG R2
DREG R3
DREG R4
mess ,NL
]
[ BigDisc
......@@ -156,11 +156,11 @@ MoveData
STMIB SP, {R7-R10}
[ DebugD
mess ,"source |dest |length |offset |result - leave MoveData",NL
wrhex R1
wrhex R2
wrhex R3
wrhex R4
wrhex R0,VS
DREG R1
DREG R2
DREG R3
DREG R4
DREG R0,VS
mess ,NL
]
STRVS R0, [SP]
......@@ -263,10 +263,10 @@ FindBuffer ROUT
Push "R0-R3,R4-R11,LR"
[ DebugD
mess ,"options |min buf |max buf |blk size - FindBuffer",NL
wrhex R0
wrhex R1
wrhex R2
wrhex R3
DREG R0
DREG R1
DREG R2
DREG R3
mess ,NL
]
BL ReturnBuffer ;return any chunks still claimed
......@@ -381,9 +381,9 @@ FindBuffer ROUT
BL SetVOnR0
[ DebugD
mess ,"options |buffer |length - leave FindBuffer",NL
wrhex R0
wrhex R1
wrhex R2
DREG R0
DREG R1
DREG R2
mess ,NL
]
Pull "R4-R11,PC"
......@@ -393,8 +393,8 @@ Sink
45 ;CLAIM CHUNK
[ DebugD
wrhex R10
wrhex R11
DREG R10
DREG R11
mess ,"Claim Chunk",NL
]
MOV R2,R11
......@@ -472,8 +472,8 @@ Sink
ADD R3, R3, #ScatterCopy-ScatterSource
ADD R3, R3, R8, LSL #3
[ DebugD
wrhex R1
wrhex R2
DREG R1
DREG R2
mess ,"add len",NL
]
STMIA R3, {R1,R2} ;save (address,length) pair
......@@ -526,8 +526,8 @@ ReturnBuffer ROUT
LDRB R1, [R0,R4]
[ DebugD
wrhex R1
wrhex R2
DREG R1
DREG R2
mess ,"return chunk",NL
]
......@@ -724,8 +724,8 @@ ReadTimeDate
ORR R7,R7,LR
ADDS SP,SP,#8 ; clear V
[ Debug9
wrhex R7
wrhex R8
DREG R7
DREG R8
mess ,"date stamp",NL
]
Pull "R0,R1,PC"
......@@ -957,36 +957,6 @@ FindErrBlock ROUT
RestPSR R3,,f
Pull "R1-R3,PC"
[ F
; =========
; HexString
; =========
; form hex string in RAM
; entry:
; R0 the number
; R1 # nibbles
; R2 ->dest
HexString ROUT
Push "R1-R2,LR"
SUB R1, R1, #1
MOV R1, R1, LSL #2
10
MOV LR, R0, LSR R1
AND LR, LR, #&F
CMPS LR, #10
ADDLO LR, LR, #"0"
ADDHS LR, LR, #"A"-10
STRB LR, [R2],#1
SUBS R1, R1, #4
BPL %BT10
Pull "R1-R2,PC"
]
; =====
; WrHex
; =====
......@@ -1018,7 +988,7 @@ WrHex ROUT
; exit if error V set, R0 result
[ F
[ {FALSE}
WrDec ROUT
Push "R0,R1,LR"
MOV R1,#10
......@@ -1235,7 +1205,7 @@ FileCoreExit ROUT
LDR LR, ptr_CannotReset
LDRB LR, [LR]
TEQS LR, #0
wrhex LR, NE
DREG LR, NE
mess NE, "CannotReset",NL
MOVNE PC, #0
01
......
......@@ -755,7 +755,7 @@ CheckMapsOK ROUT
[ BigMaps
TEQS R11,R9 ; if gap
BEQ %FT26
BL RdLenLinkBits ; not gap
BL RdLenLinkBits ; not gap
B %FT27
26 ; here if gap
......
......@@ -901,10 +901,10 @@ Stacked0a * 9*4
SavePSR R11
[ DebugF :LAND: {FALSE}
mess ,"MovesEnd.Source .Dest .Length >Addmove",NL
wrhex R3
wrhex R6
wrhex R7
wrhex R8
DREG R3
DREG R6
DREG R7
DREG R8
mess ,NL
]
CMPS R8,#0
......@@ -941,7 +941,7 @@ Stacked0a * 9*4
STMNEIA R2,{R9,R10,LR}
30
[ DebugF :LAND: {FALSE}
wrhex R3
DREG R3
mess ,"<AddMove",NL
]
RestPSR R11,,f
......@@ -959,8 +959,8 @@ Stacked0a * 9*4
CanMove ROUT
Push "R0,R2,R6-R9,R11,LR"
[ DebugF :LAND: {FALSE}
wrhex R2
wrhex R5
DREG R2
DREG R5
mess ,">CanMove",NL
]
MOV R11,R2
......@@ -1069,9 +1069,9 @@ Stacked2 * 3*4
SavePSR LR
Push "LR"
[ DebugF :LAND: {FALSE}
wrhex R1
wrhex R7
wrhex R9
DREG R1
DREG R7
DREG R9
mess ,">FillGap",NL
]
CMPS R1, #0
......@@ -1116,8 +1116,8 @@ Stacked2 * 3*4
MOVNE R3, LR
MOVNE R4, #NIL ;invalid gap
[ DebugF :LAND: {FALSE}
wrhex R1, NE
wrhex R3, NE
DREG R1, NE
DREG R3, NE
mess NE, "single exact fit",NL
]
BNE %FT20
......@@ -1179,9 +1179,9 @@ Stacked2 * 3*4
Pull "R1,R5,R8,R11"
[ DebugF :LAND: {FALSE}
wrhex R1
wrhex R3
wrhex R4
DREG R1
DREG R3
DREG R4
mess ,"double exact fit",NL
]
20
......@@ -1231,7 +1231,7 @@ Stacked2a * 4*4
Pull "R1,R5,R8,R11"
95
[ DebugF :LAND: {FALSE}
wrhex R5
DREG R5
mess ,"<FillGap",NL
]
Pull "R9"
......@@ -1254,10 +1254,10 @@ FindFrag ROUT
;exit if possible Z=0, LR->gap adjacent to frag, bit 31 set if post gap frag
Push "R1-R3,R5,R8,R9,R11,LR"
[ DebugF :LAND: {FALSE}
wrhex R0
wrhex R6
wrhex R7
wrhex R10
DREG R0
DREG R6
DREG R7
DREG R10
mess ,">FindFrag",NL
]
MOV R3, #0 ;init largest adjacent gap
......@@ -1317,8 +1317,8 @@ FindFrag ROUT
CMPS R3, #0
MOV LR ,R8
[ DebugF :LAND: {FALSE}
wrhex LR, NE
wrhex R3, NE
DREG LR, NE
DREG R3, NE
mess ,"<FindFrag",NL
]
Pull "R1-R3,R5,R8,R9,R11,PC"
......@@ -1387,9 +1387,9 @@ Stacked3 * 7*4
SUBHI R8, R5, R8
[ DebugF :LAND: {FALSE}
wrhex R9
wrhex R8
wrhex LR
DREG R9
DREG R8
DREG LR
mess ,"gap, pre run, post run",NL
]
......@@ -1413,10 +1413,10 @@ Stacked3 * 7*4
STREQ R0, [SP,#3*4]
STRNE R1, [SP,#3*4] ;overwite stacked R5 best fit
[ DebugF :LAND: {FALSE}
wrhex R0, EQ
wrhex R1, NE
wrhex LR
wrhex R8
DREG R0, EQ
DREG R1, NE
DREG LR
DREG R8
mess ,"move frag to join gaps",NL
]
B %BT10
......@@ -1435,7 +1435,7 @@ DefDoCompMoves
LDR R3, [SP,#MoveEndPtr]
ADD R9, SP, #CompMoves
[ F ;T = Simple, F = optimised
[ {FALSE} ;T = Simple, F = optimised
; ===========
; DoCompMoves
......@@ -1790,9 +1790,9 @@ DoCompMoves ROUT
DoCompMoves ROUT
Push "R0-R2,R4-R10,R11,LR"
[ DebugF :LAND: {FALSE}
wrhex R3
wrhex R9
wrhex R10
DREG R3
DREG R9
DREG R10
mess ,">DoCompMoves",NL
]
......@@ -1864,9 +1864,9 @@ DoCompMoves ROUT
MOV LR, LR, LSL R1 ;move length in bytes
ADD R2, R2, LR ;add to total move length
[ DebugF :LAND: {FALSE}
wrhex R0
wrhex R5
wrhex LR
DREG R0
DREG R5
DREG LR
mess ,"source dest len",NL
]
STMIA R4!,{R0,R5,LR}
......@@ -1949,9 +1949,9 @@ DoCompBufSize # 4
ORR NewSrc, SrcStart, R6 ; eek! eek! eek! and eek!
[ DebugF :LAND: {FALSE}
wrhex NewSrc
wrhex DestStart
wrhex R8
DREG NewSrc
DREG DestStart
DREG R8
mess ,"move to start new group",NL
]
STMDB Chosen!,{NewSrc,DestStart,R8}
......@@ -1975,17 +1975,17 @@ DoCompBufSize # 4
SUB R3, R3, Free
STR R3, [R0,#-12]!
[ DebugF :LAND: {FALSE}
wrhex R3
DREG R3
]
ADDEQ NewDest, DestStart, Free
ADDNE NewDest, DestStart, R1
STMIB R0, {NewDest,R6}
TEQNES R4, LR
[ DebugF :LAND: {FALSE}
wrhex R3, EQ
DREG R3, EQ
ADDNE LR, NewDest, Free
wrhex LR, NE
wrhex R6
DREG LR, NE
DREG R6
mess ,"start end group - split",NL
]
STR R0, GroupPtr
......@@ -2019,9 +2019,9 @@ DoCompBufSize # 4
BHS %FT24
LDMIA First!, {NewSrc,NewDest,NewLen}
[ DebugF :LAND: {FALSE}
wrhex NewSrc
wrhex NewDest
wrhex NewLen
DREG NewSrc
DREG NewDest
DREG NewLen
mess ,"move considering for group",NL
]
CMPS NewLen, Free
......@@ -2086,10 +2086,10 @@ DoCompBufSize # 4
ADD R0, R0, R1
CMPS LR, R0
[ DebugF :LAND: {FALSE}
wrhex NewSrc,LE
wrhex NewDest,LE
wrhex NewLen,LE
wrhex LR,LE
DREG NewSrc,LE
DREG NewDest,LE
DREG NewLen,LE
DREG LR,LE
mess LE,"better move to add to group",NL
]
STMLEIA SP,{NewSrc,NewDest,NewLen,First,LR}
......@@ -2134,9 +2134,9 @@ DoCompBufSize # 4
LDRB R0, GroupNum
ORR R0, R0, NewSrc
[ DebugF :LAND: {FALSE}
wrhex R0
wrhex NewDest
wrhex NewLen
DREG R0
DREG NewDest
DREG NewLen
mess ,"add move to group",NL
]
STMDB Chosen!,{R0,NewDest,NewLen}
......@@ -2148,11 +2148,11 @@ DoCompBufSize # 4
LDR R0, GroupPtr
LDRB LR, GroupNum
[ DebugF :LAND: {FALSE}
wrhex SrcStart
wrhex SrcEnd
wrhex DestStart
wrhex DestEnd
wrhex LR
DREG SrcStart
DREG SrcEnd
DREG DestStart
DREG DestEnd
DREG LR
mess ,"group completed ",NL
]
STMDB R0!,{SrcStart,DestEnd,LR}
......@@ -2280,7 +2280,7 @@ DoCompBufSize # 4
40
LDRB R0, [R4],#MoveEntry
[ DebugF :LAND: {FALSE}
wrhex R0
DREG R0
mess ,"GROUP",NL
]
MOV R0, R0, LSL #24
......@@ -2292,9 +2292,9 @@ DoCompBufSize # 4
TEQS R0, R3, LSL #24
BNE %BT42
[ DebugF :LAND: {FALSE}
wrhex R3,
wrhex R5
wrhex R7
DREG R3,
DREG R5
DREG R7
mess ,"move",NL
]
Push "R1"
......@@ -2469,8 +2469,8 @@ DoCompBufSize # 4
95
STRVS R0, [SP]
[ DebugF :LAND: {FALSE}
wrhex R0, VS
wrhex R3
DREG R0, VS
DREG R3
mess ,"<DoCompMoves",NL
]
Pull "R0-R2,R4-R11,PC"
......
......@@ -70,7 +70,7 @@ BeforeAlterFsMap
TST LR, #DiscNotFileCore
CMPNE R7, #-1 ; Only reject if AlterFsMap
MOVNE R0, #DiscNotFileCoreErr
[ T ; is this the cause of our problems?
[ {TRUE} ; is this the cause of our problems?
BEQ %FT01
BL SetVOnR0
B %FT99
......@@ -1129,10 +1129,10 @@ InitReadOldFs
MOV R10,R9
LDRB R11,[R9,#FreeEnd]
[ Debug5
wrhex R3
wrhex R9
wrhex R10
wrhex R11
DREG R3
DREG R9
DREG R10
DREG R11
mess ,"InitReadOldFs",NL
]
MOV PC,LR ; Flags preserved
......@@ -1161,9 +1161,9 @@ InitReadOldFs
NextOldFs
Push "R0,LR"
[ Debug5
wrhex R3
wrhex R10
wrhex R11
DREG R3
DREG R10
DREG R11
mess ,"enter NextOldFs",NL
]
TEQS R11,#0
......@@ -1177,8 +1177,8 @@ NextOldFs
ADDNE R10,R10,#3
SUBNE R11,R11,#3
[ Debug5
wrhex R7, NE
wrhex R8, NE
DREG R7, NE
DREG R8, NE
mess NE, "Next free space",NL
mess EQ, "No more free spaces",NL
]
......@@ -1233,8 +1233,8 @@ RemoveOldFsEntry
WriteOldFsEntry
[ Debug5
wrhex R7
wrhex R8
DREG R7
DREG R8
mess ,"Write old free space",NL
]
Push "R0,R1,LR"
......@@ -1352,7 +1352,7 @@ WriteFsMapThenMaybeDir ROUT
InvalidateFsMap
Push "R3,LR"
[ Debug5
wrhex R3
DREG R3
mess ,InvalidateFsMap,NL
]
BL DiscAddToRec ;(R3->LR)
......
......@@ -16,9 +16,6 @@
TTL "Filename and Directory operations"
GBLL FixTruncateOnBigDiscs
FixTruncateOnBigDiscs SETL T
; Name restriction bits
NotBit7Chars bit 0 ;unlike others this does not generate error but sets C
......@@ -1445,9 +1442,9 @@ BigLexEqv
LexEqv
[ Debug6 :LAND: {FALSE}
mess ,"wild name mask - enter LexEqv",NL
wrhex R1
wrhex R4
wrhex R5
DREG R1
DREG R4
DREG R5
]
Push "R0,R1,R4,R6-R11,LR"
......
......@@ -67,13 +67,13 @@ OsFileEntry
BEQ %FT10
TEQ r0, #fsfile_ReadInfo
BEQ %FT15
Entry Flag,Dormant ;leaves SB,LR stacked
SemEntry Flag,Dormant ;leaves SB,LR stacked
B %FT20
10
Entry Flag ;leaves SB,LR stacked
SemEntry Flag ;leaves SB,LR stacked
B %FT20
15
Entry Flag,Light ;leaves SB,LR stacked
SemEntry Flag,Light ;leaves SB,LR stacked
20
MOV R6,R0
BL MyOsFile
......
......@@ -56,13 +56,13 @@ OsFunEntry
BEQ %FT15
TEQ r0, #fsfunc_ReadFreeSpace
BEQ %FT10
Entry Flag, Dormant ;leaves R12,LR stacked
SemEntry Flag, Dormant ;leaves R12,LR stacked
B %FT20
10
Entry Flag ;leaves R12,LR stacked
SemEntry Flag ;leaves R12,LR stacked
B %FT20
15
Entry Flag,Light ;leaves R12,LR stacked
SemEntry Flag,Light ;leaves R12,LR stacked
20
CMPS R0, #FirstUnknown_fsfunc
MOV LR, PC
......@@ -305,8 +305,6 @@ PutSpace
; R11 as R9 (init fields left ctr)
ScreenFormat ROUT
[ T
Push "R0-R1,LR" ;calculate screen width
MOV R0, #WindowWidth
MOV R1, #-1
......@@ -329,32 +327,6 @@ ScreenFormat ROUT
MOV R11,R9
Pull "R0-R1,PC"
|
Push "R0-R3,LR" ;calculate screen width
MOV R0, #OsbyteReadVdu
MOV R1, #RightColumn
BL OnlyXOS_Byte ;(R0-R2->R0-R2,V) assume no errors
ADD R3, R1, #1
MOV R1, #LeftColumn
BL OnlyXOS_Byte ;(R0-R2->R0-R2,V)
SUBS R0, R3, R1
LDR R1, [SP]
BL Divide ;how many fields fit ? (R0,R1->R0,R1)
TEQS R0, #0
MOVEQ R9, #1
MOVNE R9, R0
MOV R0, R1 ;redistribute spare columns
MOV R1, R9
BL Divide ;(R0,R1->R0,R1)
MOV R10,R0
MOV R11,R9
Pull "R0-R3,PC"
]
; =========
; NextField
; =========
......
......@@ -108,7 +108,7 @@ CheckProcessBlks ROUT
; R0 -> error block
OpenFileEntry ROUT
Entry Flag,Dormant ;leaves R12,LR stacked
SemEntry Flag,Dormant ;leaves R12,LR stacked
BL MyOpenFile ;(R0-R3->R0-R4,LR)
MOVVC R0, LR ;device number
BLVS FindErrBlock ; (R0->R0,V)
......@@ -225,10 +225,10 @@ MyOpenFile ROUT
ORRNE R10, R10, #FcbDiscImage
[ DebugK
mess ,"DiscAddr|Winnies |R10 - MyOpenFile",NL
wrhex R3
wrhex LR
wrhex R10
mess ,NL
DREG R3
DREG LR
DREG R10
DLINE " "
]
[ DebugB
......@@ -474,8 +474,8 @@ MyOpenFile ROUT
LDRB R6, Interlocks
[ DebugK
mess ,"MyOpenFile(1) Interlocks="
wrhex R6
mess ,NL
DREG R6
DLINE " "
]
TSTS R6, #NoOpenFloppy ;IF first open file
TSTNES R6, #NoOpenWinnie
......@@ -520,8 +520,8 @@ MyOpenFile ROUT
STRB R6, Interlocks
[ DebugK
mess ,"MyOpenFile(2) sets Interlocks to "
wrhex R6
mess ,NL
DREG R6
DLINE " "
]
85
TSTS R10,#WriteBit
......@@ -641,7 +641,7 @@ UnlockUnidentifyableDisc ROUT
; R1 corrupt
CloseFileEntry ROUT
Entry Flag ;allow reentrance, leaves R12,LR stacked
SemEntry Flag ;allow reentrance, leaves R12,LR stacked
BL MyCloseFile ;(R1->R0)
BLVS FindErrBlock ;(R0->R0,V)
BL FileCoreExit
......@@ -750,7 +750,7 @@ MyCloseFile ROUT
10
]
[ F
[ {FALSE}
;AND RETURN FILE BUFFERS TO DIR CACHE
sbaddr R0, FileBufsStart
......@@ -1309,7 +1309,7 @@ CloseAllByDisc ROUT
; >>>>>>>>>>>
OsArgsEntry ROUT
Entry Flag ;allow reentrance, leaves R12,LR stacked
SemEntry Flag ;allow reentrance, leaves R12,LR stacked
[ DebugB
DREG R0, "OsArgsEntry(",cc
DREG R1, ",",cc
......@@ -1667,7 +1667,7 @@ WriteZeroes ROUT
Push "R1-R9,LR"
10
MOV R3,R8
[ T
[ {TRUE}
BL ReadAllocSize
15 ; SBP: fix to make this work when Bytes per map bit very large - reduces chunk
; size if too large
......
......@@ -35,7 +35,7 @@
; R0 -> error block
GetBytesEntry ROUT
Entry Flag ;allow reentrance, leaves R12,LR stacked
SemEntry Flag ;allow reentrance, leaves R12,LR stacked
[ DebugB :LOR: DebugBE
DLINE "handle ,start ,length ,file ptr >GetBytesEntry"
DREG R1,,cc
......@@ -53,7 +53,7 @@ GetBytesEntry ROUT
BL HandleCheck ;(R1->R0,R1,LR,V)
BVS %FT00
[ F
[ {FALSE}
; If don't want read ahead enable this
; Set if FcbDiscImage
......@@ -484,7 +484,7 @@ ReadBuffersWork # 0
[ BigDisc
SUB R2, FileOff, #1
[ T
[ {TRUE}
LDR LR, [Fcb, #FcbIndDiscAdd]
MOV LR, LR, LSR #29
DiscRecPtr LR,LR
......@@ -514,7 +514,7 @@ ReadBuffersWork # 0
SUBS R0, R2, R1
MOVMI R0, #0
]
[ F
[ {FALSE}
BIC R0, R0, #&3FC ;force to 1K boundary for add buffer
]
CMPS R0, R3
......@@ -569,7 +569,7 @@ ReadBuffersWork # 0
BL ExtendDown ;(R0,R1,R3,FileOff->R1,FileOff)
35
[ BigDisc
[ T
[ {TRUE}
LDR LR, [Fcb, #FcbIndDiscAdd]
MOV LR, LR, LSR #29
DiscRecPtr LR,LR
......@@ -600,7 +600,7 @@ ReadBuffersWork # 0
LDRNE LR, [SP,#4+ReadCylLength]
ADDNE R1, R1, LR
]
[ F
[ {FALSE}
BIC R1, R1, #&3FC ;force to 1K boundary for add buffer
]
MOV R0, #MonotonicChain*2
......@@ -731,7 +731,7 @@ ReadBuffersWork # 0
; again, we have to round to a cylinder
STR R1, [SP,#SeqReadAheadLimit]
[ T
[ {TRUE}
LDR LR, [Fcb, #FcbIndDiscAdd]
MOV LR, LR, LSR #29
DiscRecPtr LR,LR
......@@ -773,7 +773,7 @@ ReadBuffersWork # 0
CMPS LR, FragEnd
MOVGT LR, FragEnd
]
[ F
[ {FALSE}
BIC LR, LR, #&3FC ;force to 1K boundary for add buffer
]
STR LR, [SP,#TrkReadAheadLimit]
......@@ -1178,7 +1178,7 @@ GetPutCommon ROUT
; R0 -> error block
PutBytesEntry ROUT
Entry Flag ;allow reentrance, leaves SB,LR stacked
SemEntry Flag ;allow reentrance, leaves SB,LR stacked
[ Debug3L
DLINE "P",cc
]
......@@ -1922,7 +1922,7 @@ Flush ROUT
]
BLNE ClaimFiq
[ F
[ {FALSE}
;empty all buffers not involved in read ahead or write behind
LDR R2, = EmptyBuf * &01010101
]
......@@ -1935,7 +1935,7 @@ Flush ROUT
TEQS LR, #ReadAheadChain
TEQNES LR, #WriteBehindChain
[ F
[ {FALSE}
BLNE UpdateBufState ;(R2,BufPtr)
]
BNE %BT55
......@@ -2152,7 +2152,7 @@ BackgroundFileCacheOp
[ DebugG
DREG R5, "Fileoff : "
]
[ T
[ {TRUE}
LDR R10, [Fcb, #FcbIndDiscAdd]
MOV R10, R10, LSR #29
DiscRecPtr R10,R10
......@@ -2278,7 +2278,7 @@ BackgroundOps ROUT
00
WritePSRc SVC_mode, R5,,LR ;ensure IRQs enabled, old PSR into LR
Push "lr"
[ F ;FOR DEBUGGING
[ {FALSE} ;FOR DEBUGGING
; Return if IRQsema set
LDR LR, ptr_IRQsema
LDR LR, [LR]
......@@ -2302,7 +2302,7 @@ BackgroundOps ROUT
TSTS R1, #FileCacheLock
BLEQ UpdateProcess ;(R0)
[ F ;FOR DEBUGGING
[ {FALSE} ;FOR DEBUGGING
LDR LR, ptr_IRQsema
LDR LR, [LR]
TEQS LR, #0
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment