Texas Instruments TMS320 DSP Computer Hardware User Manual


 
www.ti.com
5.4.3RegisterConventions
5.4.4StatusRegisters
TMS320C54xxRulesandGuidelines
ThissectiondescribestherulesandguidelinesthatapplytotheuseoftheTMS320C54xxon-chip
registers.Asdescribedabove,thereareseveraldifferentregistertypes.Notethatanyregisterthatisnot
describedheremustnotbeaccessedbyanalgorithm;e.g.,BSCR,IFR,IMR,andperipheralcontroland
statusregisters.
Thetablebelowdescribesalloftheregistersthatmaybeaccessedbyanalgorithm
RegisterUseType
AR0,AR2-AR5CcompilerexpressionregistersScratch(local)
AR7CcompilerframepointerPreserve(local)
AR1,AR6CcompilerregistervariablesPreserve(local)
AL,AH,AGReturnvaluefromCfunction,firstparametertofunctionScratch(local)
BL,BH,BGCcompilerexpressionregistersScratch(local)
BKCircular-buffersizeregisterScratch(local)
BRCBlockrepeatcounterScratch(local)
IFR,IMRInterruptflagandmaskregisterRead-only(global)
PMSTProcessormoderegisterPreserve
RSA,REABlockrepeatstartandendregisterScratch(local)
SPStackpointerPreserve(local)
ST0,ST1StatusregistersPreserve
TMultiplyandshiftoperandScratch(local)
TRNViterbitransitionregisterScratch(local)
XPCExtendedProgramCounterScratch(local)
TheC54xxcontainsthreestatusregisters:ST0,ST1,andPMST.Eachstatusregisterisfurtherdivided
intoseveraldistinctfields.Althougheachfieldisoftenthoughtofasaseparateregister,itisnotpossible
toaccessthesefieldsindividually.Inordertosetonefield,itisnecessarytosetallfieldsinthesame
statusregister.Therefore,itisnecessarytotreatthestatusregisterswithspecialcare.Forexample,ifany
fieldofastatusregisterisoftypePreserve,theentireregistermustbetreatedasaPreserveregister.
ST0FieldNameUseType
ARPAuxiliaryregisterpointerInit(local)
CCarrybitScratch(local)
DPDatapagepointerScratch(local)
OVAOverflowflagforaccumulatorAScratch(local)
OVBOverflowflagforaccumulatorBScratch(local)
TCTest/ControlflagScratch(local)
TheST1registerisoftypeInit.
ST1FieldNameUseType
ASMAccumulatorshiftmodeScratch(local)
BRAFBlockrepeatactivebitPreserve(local)
C16Dual16-bitmathbitInit(local)
CMPTCompatibilitymodebitInit(local)
CPLCompilermodebitInit(local)
FRCTFractionalmodebitInit(local)
HMHoldmodebitPreserve(local)
SPRU352GJune2005RevisedFebruary2007DSP-SpecificGuidelines51
SubmitDocumentationFeedback