	comment	®
;cmp -> tst if immediate 0
;check for code without label after rts, bra, jmp etc.

***	MACRO68 OPTIMIZER BRAIN FILE SOURCE 	***

*** PLEASE SEE THE END OF THIS FILE FOR CHANGE NOTES

*** Macro68                  Copyright ©1990, 1991 DigiSoft
*** macro68.library          Copyright ©1990, 1991 DigiSoft
*** macro68ao.library        Copyright ©1991 DigiSoft
*** macro68cp.library        Copyright ©1991 DigiSoft
*** macro68io.library        Copyright ©1991 DigiSoft
*** macro68op.library        Copyright ©1991 DigiSoft
*** macro68custom            Copyright ©1990, 1991 DigiSoft
*** macro68custom.asm        Copyright ©1990, 1991 DigiSoft
*** macro68custom.mac        Copyright ©1990, 1991 DigiSoft
*** digisoftSupport.library  Copyright ©1988, 1989, 1990, 1991 DigiSoft
*** optim68brain             Copyright ©1991 DigiSoft
*** optim68brain.asm         Copyright ©1991 DigiSoft
***
*** DigiSoft
***  12 Dinmore St.  Moorooka 4105  Brisbane, QLD  Australia
***       Phone  ISD (61-7) 277-3255  STD (07) 277-3255


*** THIS file is extensively commented - PLEASE read all comments fully.

**	Tabstops : 8



*	The source for this file is supplied to purchasers of Macro68
*	under the following conditions:
*
*	1) None of the code in this file is to be altered in any way
*	   except as specified.
*	2) The executable and the source for it may NOT be distributed in
*	   any manner whatsoever.
*	3) DigiSoft will at all times retain the copyright to this code.

* "nullDispControlStruct:" is the only structure that ignores an optimization.
	Personally, if I put a null displacment on an address register I want
it there in the source code for readability purposes.  Macro68 will optimize
it for me if null displacement optimization is not turned off.  If you would
like to be notified about null displacement addressing then change the symbol
"ignoreLine" argument to the "Action" macro in the "nullDispControlStruct" to
the symbol "reportLine".


**	IMPORTANT NOTE :-
***		Change the paths for "objfile" & "maclib" to suit your
***		needs before assembling.
®

	exeobj
	objfile	mac:optim68brain

	if1
	printx	\N\C5;32m*** Don't forget to copy ram:optim68brain to mac: or libs: ***\C0;31m\N
	endc

********** INCLUDES

	ifeq	(__m68/1000)-3	;if version 3
		incpath	includes:,work:project/macro68
		macfile	optim68.inc
		maclib	optim68brain.mac
	else
	printx	\N\C5;32m*** You'll need at least Version 3.142 of Macro68 to assemble this file. ***\C0;31m\N
	FAIL	Wrong version of Macro68
;*;		macfile	work:project/macro68/optim68.inc
;*;		macfile	work:project/macro68/optim68brain.inc
	endc

********** EQUATES

	ifd	targetIsFiles		;define this symbol unless assembling rexx version
xxxxExport	equ	fileExport
	else
xxxxExport	equ	rexxExport
	endc

; The following equates are the values used for remembering
; Any value from 1 to 65535 may be used, but all values should be different

btst7Last	equ	1
btst15Last	equ	2
btst31Last	equ	3
bsrLast		equ	4
jsrLast		equ	5
moveLast	equ	6
flagsLast	equ	7

; The following are just a few more equates that make remembering easier

remIndex1	equ	1	;I use this for remembering info about the last line
remIndex2	equ	2
remIndex3	equ	3
remIndex4	equ	4
remIndex5	equ	5
remIndex6	equ	6
remIndex7	equ	7
remIndex8	equ	8
remIndex9	equ	9
remIndex10	equ	10	;I use this for remembering ops that set flags

oneLineAgo	equ	1
twoLineAgo	equ	2
threeLineAgo	equ	3
fourLineAgo	equ	4
fiveLineAgo	equ	5
sixLineAgo	equ	6
sevenLineAgo	equ	7
eightLineAgo	equ	8
nineLineAgo	equ	9
tenLineAgo	equ	10
elevenLineAgo	equ	11
twelveLineAgo	equ	12


*******************************************************************************
***=========================================================================***
*******************************************************************************


***   ALTER NOTHING IN THIS LONGWORD TABLE   ***


		moveq		#-1,d0
		rts

	dl	BrainVersion

	dl	replaceMessageStub_File
	dl	replaceMessageStub_Screen
	dl	removeMessageStub_File
	dl	removeMessageStub_Screen

	dl	unrefLabelControlStruct
	dl	unrefRegisterControlStruct

	dl	0				;abcdOpcode_OptimList
	dl	add.bOpcode_OptimList
	dl	add.lOpcode_OptimList
	dl	add.wOpcode_OptimList
	dl	addOpcode_OptimList
	dl	adda.lOpcode_OptimList
	dl	adda.wOpcode_OptimList
	dl	addaOpcode_OptimList
	dl	addi.bOpcode_OptimList
	dl	addi.lOpcode_OptimList
	dl	addi.wOpcode_OptimList
	dl	addiOpcode_OptimList
	dl	0				;addq.bOpcode_OptimList
	dl	0				;addq.lOpcode_OptimList
	dl	0				;addq.wOpcode_OptimList
	dl	0				;addqOpcode_OptimList
	dl	0				;addx.bOpcode_OptimList
	dl	0				;addx.lOpcode_OptimList
	dl	0				;addx.wOpcode_OptimList
	dl	0				;addxOpcode_OptimList
	dl	and.bOpcode_OptimList
	dl	and.lOpcode_OptimList
	dl	and.wOpcode_OptimList
	dl	andOpcode_OptimList
	dl	andi.bOpcode_OptimList
	dl	andi.lOpcode_OptimList
	dl	andi.wOpcode_OptimList
	dl	andiOpcode_OptimList
	dl	asl.bOpcode_OptimList
	dl	asl.lOpcode_OptimList
	dl	asl.wOpcode_OptimList
	dl	aslOpcode_OptimList
	dl	asr.bOpcode_OptimList
	dl	0				;asr.lOpcode_OptimList
	dl	0				;asr.wOpcode_OptimList
	dl	0				;asrOpcode_OptimList
	dl	0				;bcc.bOpcode_OptimList
	dl	0				;bcc.lOpcode_OptimList
	dl	0				;bcc.wOpcode_OptimList
	dl	0				;bccOpcode_OptimList
	dl	0				;bchg.bOpcode_OptimList
	dl	0				;bchg.lOpcode_OptimList
	dl	0				;bchgOpcode_OptimList
	dl	0				;bclr.bOpcode_OptimList
	dl	0				;bclr.lOpcode_OptimList
	dl	0				;bclrOpcode_OptimList
	dl	0				;bcs.bOpcode_OptimList
	dl	0				;bcs.lOpcode_OptimList
	dl	0				;bcs.wOpcode_OptimList
	dl	0				;bcsOpcode_OptimList
	dl	beq.bOpcode_OptimList
	dl	beq.lOpcode_OptimList
	dl	beq.wOpcode_OptimList
	dl	beqOpcode_OptimList
	dl	0				;bfchgOpcode_OptimList
	dl	0				;bfclrOpcode_OptimList
	dl	0				;bfextsOpcode_OptimList
	dl	0				;bfextuOpcode_OptimList
	dl	0				;bfffoOpcode_OptimList
	dl	0				;bfinsOpcode_OptimList
	dl	0				;bfsetOpcode_OptimList
	dl	0				;bftstOpcode_OptimList
	dl	0				;bge.bOpcode_OptimList
	dl	0				;bge.lOpcode_OptimList
	dl	0				;bge.wOpcode_OptimList
	dl	0				;bgeOpcode_OptimList
	dl	0				;bgt.bOpcode_OptimList
	dl	0				;bgt.lOpcode_OptimList
	dl	0				;bgt.wOpcode_OptimList
	dl	0				;bgtOpcode_OptimList
	dl	0				;bhi.bOpcode_OptimList
	dl	0				;bhi.lOpcode_OptimList
	dl	0				;bhi.wOpcode_OptimList
	dl	0				;bhiOpcode_OptimList
	dl	0				;bkptOpcode_OptimList
	dl	0				;ble.bOpcode_OptimList
	dl	0				;ble.lOpcode_OptimList
	dl	0				;ble.wOpcode_OptimList
	dl	0				;bleOpcode_OptimList
	dl	0				;bls.bOpcode_OptimList
	dl	0				;bls.lOpcode_OptimList
	dl	0				;bls.wOpcode_OptimList
	dl	0				;blsOpcode_OptimList
	dl	0				;blt.bOpcode_OptimList
	dl	0				;blt.lOpcode_OptimList
	dl	0				;blt.wOpcode_OptimList
	dl	0				;bltOpcode_OptimList
	dl	0				;bmi.bOpcode_OptimList
	dl	0				;bmi.lOpcode_OptimList
	dl	0				;bmi.wOpcode_OptimList
	dl	0				;bmiOpcode_OptimList
	dl	bne.bOpcode_OptimList
	dl	bne.lOpcode_OptimList
	dl	bne.wOpcode_OptimList
	dl	bneOpcode_OptimList
	dl	0				;bpl.bOpcode_OptimList
	dl	0				;bpl.lOpcode_OptimList
	dl	0				;bpl.wOpcode_OptimList
	dl	0				;bplOpcode_OptimList
	dl	0				;bra.bOpcode_OptimList
	dl	0				;bra.lOpcode_OptimList
	dl	0				;bra.wOpcode_OptimList
	dl	0				;braOpcode_OptimList
	dl	0				;bset.bOpcode_OptimList
	dl	0				;bset.lOpcode_OptimList
	dl	0				;bsetOpcode_OptimList
	dl	bsr.bOpcode_OptimList
	dl	bsr.lOpcode_OptimList
	dl	bsr.wOpcode_OptimList
	dl	bsrOpcode_OptimList
	dl	btst.bOpcode_OptimList
	dl	btst.lOpcode_OptimList
	dl	btstOpcode_OptimList
	dl	0				;bvc.bOpcode_OptimList
	dl	0				;bvc.lOpcode_OptimList
	dl	0				;bvc.wOpcode_OptimList
	dl	0				;bvcOpcode_OptimList
	dl	0				;bvs.bOpcode_OptimList
	dl	0				;bvs.lOpcode_OptimList
	dl	0				;bvs.wOpcode_OptimList
	dl	0				;bvsOpcode_OptimList
	dl	0				;callmOpcode_OptimList
	dl	0				;cas.bOpcode_OptimList
	dl	0				;cas.lOpcode_OptimList
	dl	0				;cas.wOpcode_OptimList
	dl	0				;cas2.lOpcode_OptimList
	dl	0				;cas2.wOpcode_OptimList
	dl	0				;cas2Opcode_OptimList
	dl	0				;casOpcode_OptimList
	dl	0				;cendOpcode_OptimList
	dl	0				;chk.lOpcode_OptimList
	dl	0				;chk.wOpcode_OptimList
	dl	0				;chk2.bOpcode_OptimList
	dl	0				;chk2.lOpcode_OptimList
	dl	0				;chk2.wOpcode_OptimList
	dl	0				;chk2Opcode_OptimList
	dl	0				;chkOpcode_OptimList
	dl	0				;cinvaOpcode_OptimList
	dl	0				;cinvlOpcode_OptimList
	dl	0				;cinvpOpcode_OptimList
	dl	0				;clr.bOpcode_OptimList
	dl	clr.lOpcode_OptimList
	dl	0				;clr.wOpcode_OptimList
	dl	0				;clrOpcode_OptimList
	dl	0				;cmoveOpcode_OptimList
	dl	0				;cmp.bOpcode_OptimList
	dl	0				;cmp.lOpcode_OptimList
	dl	0				;cmp.wOpcode_OptimList
	dl	0				;cmp2.bOpcode_OptimList
	dl	0				;cmp2.lOpcode_OptimList
	dl	0				;cmp2.wOpcode_OptimList
	dl	0				;cmp2Opcode_OptimList
	dl	0				;cmpOpcode_OptimList
	dl	0				;cmpa.lOpcode_OptimList
	dl	0				;cmpa.wOpcode_OptimList
	dl	0				;cmpaOpcode_OptimList
	dl	0				;cmpi.bOpcode_OptimList
	dl	0				;cmpi.lOpcode_OptimList
	dl	0				;cmpi.wOpcode_OptimList
	dl	0				;cmpiOpcode_OptimList
	dl	0				;cmpm.bOpcode_OptimList
	dl	0				;cmpm.lOpcode_OptimList
	dl	0				;cmpm.wOpcode_OptimList
	dl	0				;cmpmOpcode_OptimList
	dl	0				;cpushaOpcode_OptimList
	dl	0				;cpushlOpcode_OptimList
	dl	0				;cpushpOpcode_OptimList
	dl	0				;cskipOpcode_OptimList
	dl	0				;cwaitOpcode_OptimList
	dl	0				;dbccOpcode_OptimList
	dl	0				;dbcsOpcode_OptimList
	dl	0				;dbeqOpcode_OptimList
	dl	0				;dbfOpcode_OptimList
	dl	0				;dbgeOpcode_OptimList
	dl	0				;dbgtOpcode_OptimList
	dl	0				;dbhiOpcode_OptimList
	dl	0				;dbleOpcode_OptimList
	dl	0				;dblsOpcode_OptimList
	dl	0				;dbltOpcode_OptimList
	dl	0				;dbmiOpcode_OptimList
	dl	0				;dbneOpcode_OptimList
	dl	0				;dbplOpcode_OptimList
	dl	0				;dbtOpcode_OptimList
	dl	0				;dbvcOpcode_OptimList
	dl	0				;dbvsOpcode_OptimList
	dl	0				;divs.lOpcode_OptimList
	dl	0				;divs.wOpcode_OptimList
	dl	0				;divsOpcode_OptimList
	dl	0				;divsl.lOpcode_OptimList
	dl	0				;divu.lOpcode_OptimList
	dl	divu.wOpcode_OptimList
	dl	divuOpcode_OptimList
	dl	0				;divul.lOpcode_OptimList
	dl	0				;eor.bOpcode_OptimList
	dl	0				;eor.lOpcode_OptimList
	dl	0				;eor.wOpcode_OptimList
	dl	0				;eorOpcode_OptimList
	dl	0				;eori.bOpcode_OptimList
	dl	0				;eori.lOpcode_OptimList
	dl	0				;eori.wOpcode_OptimList
	dl	0				;eoriOpcode_OptimList
	dl	0				;exgOpcode_OptimList
	dl	0				;ext.lOpcode_OptimList
	dl	0				;ext.wOpcode_OptimList
	dl	0				;extOpcode_OptimList
	dl	0				;extb.lOpcode_OptimList
	dl	0				;extbOpcode_OptimList
	dl	0				;fabs.bOpcode_OptimList
	dl	0				;fabs.dOpcode_OptimList
	dl	0				;fabs.lOpcode_OptimList
	dl	0				;fabs.pOpcode_OptimList
	dl	0				;fabs.sOpcode_OptimList
	dl	0				;fabs.wOpcode_OptimList
	dl	0				;fabs.xOpcode_OptimList
	dl	0				;facos.bOpcode_OptimList
	dl	0				;facos.dOpcode_OptimList
	dl	0				;facos.lOpcode_OptimList
	dl	0				;facos.pOpcode_OptimList
	dl	0				;facos.sOpcode_OptimList
	dl	0				;facos.wOpcode_OptimList
	dl	0				;facos.xOpcode_OptimList
	dl	0				;fadd.bOpcode_OptimList
	dl	0				;fadd.dOpcode_OptimList
	dl	0				;fadd.lOpcode_OptimList
	dl	0				;fadd.pOpcode_OptimList
	dl	0				;fadd.sOpcode_OptimList
	dl	0				;fadd.wOpcode_OptimList
	dl	0				;fadd.xOpcode_OptimList
	dl	0				;fasin.bOpcode_OptimList
	dl	0				;fasin.dOpcode_OptimList
	dl	0				;fasin.lOpcode_OptimList
	dl	0				;fasin.pOpcode_OptimList
	dl	0				;fasin.sOpcode_OptimList
	dl	0				;fasin.wOpcode_OptimList
	dl	0				;fasin.xOpcode_OptimList
	dl	0				;fatan.bOpcode_OptimList
	dl	0				;fatan.dOpcode_OptimList
	dl	0				;fatan.lOpcode_OptimList
	dl	0				;fatan.pOpcode_OptimList
	dl	0				;fatan.sOpcode_OptimList
	dl	0				;fatan.wOpcode_OptimList
	dl	0				;fatan.xOpcode_OptimList
	dl	0				;fatanh.bOpcode_OptimList
	dl	0				;fatanh.dOpcode_OptimList
	dl	0				;fatanh.lOpcode_OptimList
	dl	0				;fatanh.pOpcode_OptimList
	dl	0				;fatanh.sOpcode_OptimList
	dl	0				;fatanh.wOpcode_OptimList
	dl	0				;fatanh.xOpcode_OptimList
	dl	0				;fbeq.lOpcode_OptimList
	dl	0				;fbeq.wOpcode_OptimList
	dl	0				;fbeqOpcode_OptimList
	dl	0				;fbf.lOpcode_OptimList
	dl	0				;fbf.wOpcode_OptimList
	dl	0				;fbfOpcode_OptimList
	dl	0				;fbge.lOpcode_OptimList
	dl	0				;fbge.wOpcode_OptimList
	dl	0				;fbgeOpcode_OptimList
	dl	0				;fbgl.lOpcode_OptimList
	dl	0				;fbgl.wOpcode_OptimList
	dl	0				;fbglOpcode_OptimList
	dl	0				;fbgle.lOpcode_OptimList
	dl	0				;fbgle.wOpcode_OptimList
	dl	0				;fbgleOpcode_OptimList
	dl	0				;fbgt.lOpcode_OptimList
	dl	0				;fbgt.wOpcode_OptimList
	dl	0				;fbgtOpcode_OptimList
	dl	0				;fble.lOpcode_OptimList
	dl	0				;fble.wOpcode_OptimList
	dl	0				;fbleOpcode_OptimList
	dl	0				;fblt.lOpcode_OptimList
	dl	0				;fblt.wOpcode_OptimList
	dl	0				;fbltOpcode_OptimList
	dl	0				;fbne.lOpcode_OptimList
	dl	0				;fbne.wOpcode_OptimList
	dl	0				;fbneOpcode_OptimList
	dl	0				;fbnge.lOpcode_OptimList
	dl	0				;fbnge.wOpcode_OptimList
	dl	0				;fbngeOpcode_OptimList
	dl	0				;fbngl.lOpcode_OptimList
	dl	0				;fbngl.wOpcode_OptimList
	dl	0				;fbnglOpcode_OptimList
	dl	0				;fbngle.lOpcode_OptimList
	dl	0				;fbngle.wOpcode_OptimList
	dl	0				;fbngleOpcode_OptimList
	dl	0				;fbngt.lOpcode_OptimList
	dl	0				;fbngt.wOpcode_OptimList
	dl	0				;fbngtOpcode_OptimList
	dl	0				;fbnle.lOpcode_OptimList
	dl	0				;fbnle.wOpcode_OptimList
	dl	0				;fbnleOpcode_OptimList
	dl	0				;fbnlt.lOpcode_OptimList
	dl	0				;fbnlt.wOpcode_OptimList
	dl	0				;fbnltOpcode_OptimList
	dl	0				;fboge.lOpcode_OptimList
	dl	0				;fboge.wOpcode_OptimList
	dl	0				;fbogeOpcode_OptimList
	dl	0				;fbogl.lOpcode_OptimList
	dl	0				;fbogl.wOpcode_OptimList
	dl	0				;fboglOpcode_OptimList
	dl	0				;fbogt.lOpcode_OptimList
	dl	0				;fbogt.wOpcode_OptimList
	dl	0				;fbogtOpcode_OptimList
	dl	0				;fbole.lOpcode_OptimList
	dl	0				;fbole.wOpcode_OptimList
	dl	0				;fboleOpcode_OptimList
	dl	0				;fbolt.lOpcode_OptimList
	dl	0				;fbolt.wOpcode_OptimList
	dl	0				;fboltOpcode_OptimList
	dl	0				;fbor.lOpcode_OptimList
	dl	0				;fbor.wOpcode_OptimList
	dl	0				;fborOpcode_OptimList
	dl	0				;fbseq.lOpcode_OptimList
	dl	0				;fbseq.wOpcode_OptimList
	dl	0				;fbseqOpcode_OptimList
	dl	0				;fbsf.lOpcode_OptimList
	dl	0				;fbsf.wOpcode_OptimList
	dl	0				;fbsfOpcode_OptimList
	dl	0				;fbsne.lOpcode_OptimList
	dl	0				;fbsne.wOpcode_OptimList
	dl	0				;fbsneOpcode_OptimList
	dl	0				;fbst.lOpcode_OptimList
	dl	0				;fbst.wOpcode_OptimList
	dl	0				;fbstOpcode_OptimList
	dl	0				;fbt.lOpcode_OptimList
	dl	0				;fbt.wOpcode_OptimList
	dl	0				;fbtOpcode_OptimList
	dl	0				;fbueq.lOpcode_OptimList
	dl	0				;fbueq.wOpcode_OptimList
	dl	0				;fbueqOpcode_OptimList
	dl	0				;fbuge.lOpcode_OptimList
	dl	0				;fbuge.wOpcode_OptimList
	dl	0				;fbugeOpcode_OptimList
	dl	0				;fbugt.lOpcode_OptimList
	dl	0				;fbugt.wOpcode_OptimList
	dl	0				;fbugtOpcode_OptimList
	dl	0				;fbule.lOpcode_OptimList
	dl	0				;fbule.wOpcode_OptimList
	dl	0				;fbuleOpcode_OptimList
	dl	0				;fbult.lOpcode_OptimList
	dl	0				;fbult.wOpcode_OptimList
	dl	0				;fbultOpcode_OptimList
	dl	0				;fbun.lOpcode_OptimList
	dl	0				;fbun.wOpcode_OptimList
	dl	0				;fbunOpcode_OptimList
	dl	0				;fcmp.bOpcode_OptimList
	dl	0				;fcmp.dOpcode_OptimList
	dl	0				;fcmp.lOpcode_OptimList
	dl	0				;fcmp.pOpcode_OptimList
	dl	0				;fcmp.sOpcode_OptimList
	dl	0				;fcmp.wOpcode_OptimList
	dl	0				;fcmp.xOpcode_OptimList
	dl	0				;fcos.bOpcode_OptimList
	dl	0				;fcos.dOpcode_OptimList
	dl	0				;fcos.lOpcode_OptimList
	dl	0				;fcos.pOpcode_OptimList
	dl	0				;fcos.sOpcode_OptimList
	dl	0				;fcos.wOpcode_OptimList
	dl	0				;fcos.xOpcode_OptimList
	dl	0				;fcosh.bOpcode_OptimList
	dl	0				;fcosh.dOpcode_OptimList
	dl	0				;fcosh.lOpcode_OptimList
	dl	0				;fcosh.pOpcode_OptimList
	dl	0				;fcosh.sOpcode_OptimList
	dl	0				;fcosh.wOpcode_OptimList
	dl	0				;fcosh.xOpcode_OptimList
	dl	0				;fdabs.bOpcode_OptimList
	dl	0				;fdabs.dOpcode_OptimList
	dl	0				;fdabs.lOpcode_OptimList
	dl	0				;fdabs.pOpcode_OptimList
	dl	0				;fdabs.sOpcode_OptimList
	dl	0				;fdabs.wOpcode_OptimList
	dl	0				;fdabs.xOpcode_OptimList
	dl	0				;fdadd.bOpcode_OptimList
	dl	0				;fdadd.dOpcode_OptimList
	dl	0				;fdadd.lOpcode_OptimList
	dl	0				;fdadd.pOpcode_OptimList
	dl	0				;fdadd.sOpcode_OptimList
	dl	0				;fdadd.wOpcode_OptimList
	dl	0				;fdadd.xOpcode_OptimList
	dl	0				;fdbeqOpcode_OptimList
	dl	0				;fdbfOpcode_OptimList
	dl	0				;fdbgeOpcode_OptimList
	dl	0				;fdbglOpcode_OptimList
	dl	0				;fdbgleOpcode_OptimList
	dl	0				;fdbgtOpcode_OptimList
	dl	0				;fdbleOpcode_OptimList
	dl	0				;fdbltOpcode_OptimList
	dl	0				;fdbneOpcode_OptimList
	dl	0				;fdbngeOpcode_OptimList
	dl	0				;fdbnglOpcode_OptimList
	dl	0				;fdbngleOpcode_OptimList
	dl	0				;fdbngtOpcode_OptimList
	dl	0				;fdbnleOpcode_OptimList
	dl	0				;fdbnltOpcode_OptimList
	dl	0				;fdbogeOpcode_OptimList
	dl	0				;fdboglOpcode_OptimList
	dl	0				;fdbogtOpcode_OptimList
	dl	0				;fdboleOpcode_OptimList
	dl	0				;fdboltOpcode_OptimList
	dl	0				;fdborOpcode_OptimList
	dl	0				;fdbseqOpcode_OptimList
	dl	0				;fdbsfOpcode_OptimList
	dl	0				;fdbsneOpcode_OptimList
	dl	0				;fdbstOpcode_OptimList
	dl	0				;fdbtOpcode_OptimList
	dl	0				;fdbueqOpcode_OptimList
	dl	0				;fdbugeOpcode_OptimList
	dl	0				;fdbugtOpcode_OptimList
	dl	0				;fdbuleOpcode_OptimList
	dl	0				;fdbultOpcode_OptimList
	dl	0				;fdbunOpcode_OptimList
	dl	0				;fddiv.bOpcode_OptimList
	dl	0				;fddiv.dOpcode_OptimList
	dl	0				;fddiv.lOpcode_OptimList
	dl	0				;fddiv.pOpcode_OptimList
	dl	0				;fddiv.sOpcode_OptimList
	dl	0				;fddiv.wOpcode_OptimList
	dl	0				;fddiv.xOpcode_OptimList
	dl	0				;fdiv.bOpcode_OptimList
	dl	0				;fdiv.dOpcode_OptimList
	dl	0				;fdiv.lOpcode_OptimList
	dl	0				;fdiv.pOpcode_OptimList
	dl	0				;fdiv.sOpcode_OptimList
	dl	0				;fdiv.wOpcode_OptimList
	dl	0				;fdiv.xOpcode_OptimList
	dl	0				;fdmove.bOpcode_OptimList
	dl	0				;fdmove.dOpcode_OptimList
	dl	0				;fdmove.lOpcode_OptimList
	dl	0				;fdmove.pOpcode_OptimList
	dl	0				;fdmove.sOpcode_OptimList
	dl	0				;fdmove.wOpcode_OptimList
	dl	0				;fdmove.xOpcode_OptimList
	dl	0				;fdmul.bOpcode_OptimList
	dl	0				;fdmul.dOpcode_OptimList
	dl	0				;fdmul.lOpcode_OptimList
	dl	0				;fdmul.pOpcode_OptimList
	dl	0				;fdmul.sOpcode_OptimList
	dl	0				;fdmul.wOpcode_OptimList
	dl	0				;fdmul.xOpcode_OptimList
	dl	0				;fdneg.bOpcode_OptimList
	dl	0				;fdneg.dOpcode_OptimList
	dl	0				;fdneg.lOpcode_OptimList
	dl	0				;fdneg.pOpcode_OptimList
	dl	0				;fdneg.sOpcode_OptimList
	dl	0				;fdneg.wOpcode_OptimList
	dl	0				;fdneg.xOpcode_OptimList
	dl	0				;fdsqrt.bOpcode_OptimList
	dl	0				;fdsqrt.dOpcode_OptimList
	dl	0				;fdsqrt.lOpcode_OptimList
	dl	0				;fdsqrt.pOpcode_OptimList
	dl	0				;fdsqrt.sOpcode_OptimList
	dl	0				;fdsqrt.wOpcode_OptimList
	dl	0				;fdsqrt.xOpcode_OptimList
	dl	0				;fdsub.bOpcode_OptimList
	dl	0				;fdsub.dOpcode_OptimList
	dl	0				;fdsub.lOpcode_OptimList
	dl	0				;fdsub.pOpcode_OptimList
	dl	0				;fdsub.sOpcode_OptimList
	dl	0				;fdsub.wOpcode_OptimList
	dl	0				;fdsub.xOpcode_OptimList
	dl	0				;fetox.bOpcode_OptimList
	dl	0				;fetox.dOpcode_OptimList
	dl	0				;fetox.lOpcode_OptimList
	dl	0				;fetox.pOpcode_OptimList
	dl	0				;fetox.sOpcode_OptimList
	dl	0				;fetox.wOpcode_OptimList
	dl	0				;fetox.xOpcode_OptimList
	dl	0				;fetoxm1.bOpcode_OptimList
	dl	0				;fetoxm1.dOpcode_OptimList
	dl	0				;fetoxm1.lOpcode_OptimList
	dl	0				;fetoxm1.pOpcode_OptimList
	dl	0				;fetoxm1.sOpcode_OptimList
	dl	0				;fetoxm1.wOpcode_OptimList
	dl	0				;fetoxm1.xOpcode_OptimList
	dl	0				;fgetexp.bOpcode_OptimList
	dl	0				;fgetexp.dOpcode_OptimList
	dl	0				;fgetexp.lOpcode_OptimList
	dl	0				;fgetexp.pOpcode_OptimList
	dl	0				;fgetexp.sOpcode_OptimList
	dl	0				;fgetexp.wOpcode_OptimList
	dl	0				;fgetexp.xOpcode_OptimList
	dl	0				;fgetman.bOpcode_OptimList
	dl	0				;fgetman.dOpcode_OptimList
	dl	0				;fgetman.lOpcode_OptimList
	dl	0				;fgetman.pOpcode_OptimList
	dl	0				;fgetman.sOpcode_OptimList
	dl	0				;fgetman.wOpcode_OptimList
	dl	0				;fgetman.xOpcode_OptimList
	dl	0				;fint.bOpcode_OptimList
	dl	0				;fint.dOpcode_OptimList
	dl	0				;fint.lOpcode_OptimList
	dl	0				;fint.pOpcode_OptimList
	dl	0				;fint.sOpcode_OptimList
	dl	0				;fint.wOpcode_OptimList
	dl	0				;fint.xOpcode_OptimList
	dl	0				;fintrz.bOpcode_OptimList
	dl	0				;fintrz.dOpcode_OptimList
	dl	0				;fintrz.lOpcode_OptimList
	dl	0				;fintrz.pOpcode_OptimList
	dl	0				;fintrz.sOpcode_OptimList
	dl	0				;fintrz.wOpcode_OptimList
	dl	0				;fintrz.xOpcode_OptimList
	dl	0				;flog10.bOpcode_OptimList
	dl	0				;flog10.dOpcode_OptimList
	dl	0				;flog10.lOpcode_OptimList
	dl	0				;flog10.pOpcode_OptimList
	dl	0				;flog10.sOpcode_OptimList
	dl	0				;flog10.wOpcode_OptimList
	dl	0				;flog10.xOpcode_OptimList
	dl	0				;flog2.bOpcode_OptimList
	dl	0				;flog2.dOpcode_OptimList
	dl	0				;flog2.lOpcode_OptimList
	dl	0				;flog2.pOpcode_OptimList
	dl	0				;flog2.sOpcode_OptimList
	dl	0				;flog2.wOpcode_OptimList
	dl	0				;flog2.xOpcode_OptimList
	dl	0				;flogn.bOpcode_OptimList
	dl	0				;flogn.dOpcode_OptimList
	dl	0				;flogn.lOpcode_OptimList
	dl	0				;flogn.pOpcode_OptimList
	dl	0				;flogn.sOpcode_OptimList
	dl	0				;flogn.wOpcode_OptimList
	dl	0				;flogn.xOpcode_OptimList
	dl	0				;flognp1.bOpcode_OptimList
	dl	0				;flognp1.dOpcode_OptimList
	dl	0				;flognp1.lOpcode_OptimList
	dl	0				;flognp1.pOpcode_OptimList
	dl	0				;flognp1.sOpcode_OptimList
	dl	0				;flognp1.wOpcode_OptimList
	dl	0				;flognp1.xOpcode_OptimList
	dl	0				;fmod.bOpcode_OptimList
	dl	0				;fmod.dOpcode_OptimList
	dl	0				;fmod.lOpcode_OptimList
	dl	0				;fmod.pOpcode_OptimList
	dl	0				;fmod.sOpcode_OptimList
	dl	0				;fmod.wOpcode_OptimList
	dl	0				;fmod.xOpcode_OptimList
	dl	0				;fmove.bOpcode_OptimList
	dl	0				;fmove.dOpcode_OptimList
	dl	0				;fmove.lOpcode_OptimList
	dl	0				;fmove.pOpcode_OptimList
	dl	0				;fmove.sOpcode_OptimList
	dl	0				;fmove.wOpcode_OptimList
	dl	0				;fmove.xOpcode_OptimList
	dl	0				;fmovecr.xOpcode_OptimList
	dl	0				;fmovecrOpcode_OptimList
	dl	0				;fmovem.lOpcode_OptimList
	dl	0				;fmovem.xOpcode_OptimList
	dl	0				;fmul.bOpcode_OptimList
	dl	0				;fmul.dOpcode_OptimList
	dl	0				;fmul.lOpcode_OptimList
	dl	0				;fmul.pOpcode_OptimList
	dl	0				;fmul.sOpcode_OptimList
	dl	0				;fmul.wOpcode_OptimList
	dl	0				;fmul.xOpcode_OptimList
	dl	0				;fneg.bOpcode_OptimList
	dl	0				;fneg.dOpcode_OptimList
	dl	0				;fneg.lOpcode_OptimList
	dl	0				;fneg.pOpcode_OptimList
	dl	0				;fneg.sOpcode_OptimList
	dl	0				;fneg.wOpcode_OptimList
	dl	0				;fneg.xOpcode_OptimList
	dl	0				;fnopOpcode_OptimList
	dl	0				;frem.bOpcode_OptimList
	dl	0				;frem.dOpcode_OptimList
	dl	0				;frem.lOpcode_OptimList
	dl	0				;frem.pOpcode_OptimList
	dl	0				;frem.sOpcode_OptimList
	dl	0				;frem.wOpcode_OptimList
	dl	0				;frem.xOpcode_OptimList
	dl	0				;frestoreOpcode_OptimList
	dl	0				;fsabs.bOpcode_OptimList
	dl	0				;fsabs.dOpcode_OptimList
	dl	0				;fsabs.lOpcode_OptimList
	dl	0				;fsabs.pOpcode_OptimList
	dl	0				;fsabs.sOpcode_OptimList
	dl	0				;fsabs.wOpcode_OptimList
	dl	0				;fsabs.xOpcode_OptimList
	dl	0				;fsadd.bOpcode_OptimList
	dl	0				;fsadd.dOpcode_OptimList
	dl	0				;fsadd.lOpcode_OptimList
	dl	0				;fsadd.pOpcode_OptimList
	dl	0				;fsadd.sOpcode_OptimList
	dl	0				;fsadd.wOpcode_OptimList
	dl	0				;fsadd.xOpcode_OptimList
	dl	0				;fsaveOpcode_OptimList
	dl	0				;fscale.bOpcode_OptimList
	dl	0				;fscale.dOpcode_OptimList
	dl	0				;fscale.lOpcode_OptimList
	dl	0				;fscale.pOpcode_OptimList
	dl	0				;fscale.sOpcode_OptimList
	dl	0				;fscale.wOpcode_OptimList
	dl	0				;fscale.xOpcode_OptimList
	dl	0				;fsdiv.bOpcode_OptimList
	dl	0				;fsdiv.dOpcode_OptimList
	dl	0				;fsdiv.lOpcode_OptimList
	dl	0				;fsdiv.pOpcode_OptimList
	dl	0				;fsdiv.sOpcode_OptimList
	dl	0				;fsdiv.wOpcode_OptimList
	dl	0				;fsdiv.xOpcode_OptimList
	dl	0				;fseqOpcode_OptimList
	dl	0				;fsfOpcode_OptimList
	dl	0				;fsgeOpcode_OptimList
	dl	0				;fsglOpcode_OptimList
	dl	0				;fsgldiv.bOpcode_OptimList
	dl	0				;fsgldiv.dOpcode_OptimList
	dl	0				;fsgldiv.lOpcode_OptimList
	dl	0				;fsgldiv.pOpcode_OptimList
	dl	0				;fsgldiv.sOpcode_OptimList
	dl	0				;fsgldiv.wOpcode_OptimList
	dl	0				;fsgldiv.xOpcode_OptimList
	dl	0				;fsgleOpcode_OptimList
	dl	0				;fsglmul.bOpcode_OptimList
	dl	0				;fsglmul.dOpcode_OptimList
	dl	0				;fsglmul.lOpcode_OptimList
	dl	0				;fsglmul.pOpcode_OptimList
	dl	0				;fsglmul.sOpcode_OptimList
	dl	0				;fsglmul.wOpcode_OptimList
	dl	0				;fsglmul.xOpcode_OptimList
	dl	0				;fsgtOpcode_OptimList
	dl	0				;fsin.bOpcode_OptimList
	dl	0				;fsin.dOpcode_OptimList
	dl	0				;fsin.lOpcode_OptimList
	dl	0				;fsin.pOpcode_OptimList
	dl	0				;fsin.sOpcode_OptimList
	dl	0				;fsin.wOpcode_OptimList
	dl	0				;fsin.xOpcode_OptimList
	dl	0				;fsincos.bOpcode_OptimList
	dl	0				;fsincos.dOpcode_OptimList
	dl	0				;fsincos.lOpcode_OptimList
	dl	0				;fsincos.pOpcode_OptimList
	dl	0				;fsincos.sOpcode_OptimList
	dl	0				;fsincos.wOpcode_OptimList
	dl	0				;fsincos.xOpcode_OptimList
	dl	0				;fsinh.bOpcode_OptimList
	dl	0				;fsinh.dOpcode_OptimList
	dl	0				;fsinh.lOpcode_OptimList
	dl	0				;fsinh.pOpcode_OptimList
	dl	0				;fsinh.sOpcode_OptimList
	dl	0				;fsinh.wOpcode_OptimList
	dl	0				;fsinh.xOpcode_OptimList
	dl	0				;fsleOpcode_OptimList
	dl	0				;fsltOpcode_OptimList
	dl	0				;fsmove.bOpcode_OptimList
	dl	0				;fsmove.dOpcode_OptimList
	dl	0				;fsmove.lOpcode_OptimList
	dl	0				;fsmove.pOpcode_OptimList
	dl	0				;fsmove.sOpcode_OptimList
	dl	0				;fsmove.wOpcode_OptimList
	dl	0				;fsmove.xOpcode_OptimList
	dl	0				;fsmul.bOpcode_OptimList
	dl	0				;fsmul.dOpcode_OptimList
	dl	0				;fsmul.lOpcode_OptimList
	dl	0				;fsmul.pOpcode_OptimList
	dl	0				;fsmul.sOpcode_OptimList
	dl	0				;fsmul.wOpcode_OptimList
	dl	0				;fsmul.xOpcode_OptimList
	dl	0				;fsneOpcode_OptimList
	dl	0				;fsneg.bOpcode_OptimList
	dl	0				;fsneg.dOpcode_OptimList
	dl	0				;fsneg.lOpcode_OptimList
	dl	0				;fsneg.pOpcode_OptimList
	dl	0				;fsneg.sOpcode_OptimList
	dl	0				;fsneg.wOpcode_OptimList
	dl	0				;fsneg.xOpcode_OptimList
	dl	0				;fsngeOpcode_OptimList
	dl	0				;fsnglOpcode_OptimList
	dl	0				;fsngleOpcode_OptimList
	dl	0				;fsngtOpcode_OptimList
	dl	0				;fsnleOpcode_OptimList
	dl	0				;fsnltOpcode_OptimList
	dl	0				;fsogeOpcode_OptimList
	dl	0				;fsoglOpcode_OptimList
	dl	0				;fsogtOpcode_OptimList
	dl	0				;fsoleOpcode_OptimList
	dl	0				;fsoltOpcode_OptimList
	dl	0				;fsorOpcode_OptimList
	dl	0				;fsqrt.bOpcode_OptimList
	dl	0				;fsqrt.dOpcode_OptimList
	dl	0				;fsqrt.lOpcode_OptimList
	dl	0				;fsqrt.pOpcode_OptimList
	dl	0				;fsqrt.sOpcode_OptimList
	dl	0				;fsqrt.wOpcode_OptimList
	dl	0				;fsqrt.xOpcode_OptimList
	dl	0				;fsseqOpcode_OptimList
	dl	0				;fssfOpcode_OptimList
	dl	0				;fssneOpcode_OptimList
	dl	0				;fssqrt.bOpcode_OptimList
	dl	0				;fssqrt.dOpcode_OptimList
	dl	0				;fssqrt.lOpcode_OptimList
	dl	0				;fssqrt.pOpcode_OptimList
	dl	0				;fssqrt.sOpcode_OptimList
	dl	0				;fssqrt.wOpcode_OptimList
	dl	0				;fssqrt.xOpcode_OptimList
	dl	0				;fsstOpcode_OptimList
	dl	0				;fssub.bOpcode_OptimList
	dl	0				;fssub.dOpcode_OptimList
	dl	0				;fssub.lOpcode_OptimList
	dl	0				;fssub.pOpcode_OptimList
	dl	0				;fssub.sOpcode_OptimList
	dl	0				;fssub.wOpcode_OptimList
	dl	0				;fssub.xOpcode_OptimList
	dl	0				;fstOpcode_OptimList
	dl	0				;fsub.bOpcode_OptimList
	dl	0				;fsub.dOpcode_OptimList
	dl	0				;fsub.lOpcode_OptimList
	dl	0				;fsub.pOpcode_OptimList
	dl	0				;fsub.sOpcode_OptimList
	dl	0				;fsub.wOpcode_OptimList
	dl	0				;fsub.xOpcode_OptimList
	dl	0				;fsueqOpcode_OptimList
	dl	0				;fsugeOpcode_OptimList
	dl	0				;fsugtOpcode_OptimList
	dl	0				;fsuleOpcode_OptimList
	dl	0				;fsultOpcode_OptimList
	dl	0				;fsunOpcode_OptimList
	dl	0				;ftan.bOpcode_OptimList
	dl	0				;ftan.dOpcode_OptimList
	dl	0				;ftan.lOpcode_OptimList
	dl	0				;ftan.pOpcode_OptimList
	dl	0				;ftan.sOpcode_OptimList
	dl	0				;ftan.wOpcode_OptimList
	dl	0				;ftan.xOpcode_OptimList
	dl	0				;ftanh.bOpcode_OptimList
	dl	0				;ftanh.dOpcode_OptimList
	dl	0				;ftanh.lOpcode_OptimList
	dl	0				;ftanh.pOpcode_OptimList
	dl	0				;ftanh.sOpcode_OptimList
	dl	0				;ftanh.wOpcode_OptimList
	dl	0				;ftanh.xOpcode_OptimList
	dl	0				;ftentox.bOpcode_OptimList
	dl	0				;ftentox.dOpcode_OptimList
	dl	0				;ftentox.lOpcode_OptimList
	dl	0				;ftentox.pOpcode_OptimList
	dl	0				;ftentox.sOpcode_OptimList
	dl	0				;ftentox.wOpcode_OptimList
	dl	0				;ftentox.xOpcode_OptimList
	dl	0				;ftrapeq.lOpcode_OptimList
	dl	0				;ftrapeq.wOpcode_OptimList
	dl	0				;ftrapeqOpcode_OptimList
	dl	0				;ftrapf.lOpcode_OptimList
	dl	0				;ftrapf.wOpcode_OptimList
	dl	0				;ftrapfOpcode_OptimList
	dl	0				;ftrapge.lOpcode_OptimList
	dl	0				;ftrapge.wOpcode_OptimList
	dl	0				;ftrapgeOpcode_OptimList
	dl	0				;ftrapgl.lOpcode_OptimList
	dl	0				;ftrapgl.wOpcode_OptimList
	dl	0				;ftrapglOpcode_OptimList
	dl	0				;ftrapgle.lOpcode_OptimList
	dl	0				;ftrapgle.wOpcode_OptimList
	dl	0				;ftrapgleOpcode_OptimList
	dl	0				;ftrapgt.lOpcode_OptimList
	dl	0				;ftrapgt.wOpcode_OptimList
	dl	0				;ftrapgtOpcode_OptimList
	dl	0				;ftraple.lOpcode_OptimList
	dl	0				;ftraple.wOpcode_OptimList
	dl	0				;ftrapleOpcode_OptimList
	dl	0				;ftraplt.lOpcode_OptimList
	dl	0				;ftraplt.wOpcode_OptimList
	dl	0				;ftrapltOpcode_OptimList
	dl	0				;ftrapne.lOpcode_OptimList
	dl	0				;ftrapne.wOpcode_OptimList
	dl	0				;ftrapneOpcode_OptimList
	dl	0				;ftrapnge.lOpcode_OptimList
	dl	0				;ftrapnge.wOpcode_OptimList
	dl	0				;ftrapngeOpcode_OptimList
	dl	0				;ftrapngl.lOpcode_OptimList
	dl	0				;ftrapngl.wOpcode_OptimList
	dl	0				;ftrapnglOpcode_OptimList
	dl	0				;ftrapngle.lOpcode_OptimList
	dl	0				;ftrapngle.wOpcode_OptimList
	dl	0				;ftrapngleOpcode_OptimList
	dl	0				;ftrapngt.lOpcode_OptimList
	dl	0				;ftrapngt.wOpcode_OptimList
	dl	0				;ftrapngtOpcode_OptimList
	dl	0				;ftrapnle.lOpcode_OptimList
	dl	0				;ftrapnle.wOpcode_OptimList
	dl	0				;ftrapnleOpcode_OptimList
	dl	0				;ftrapnlt.lOpcode_OptimList
	dl	0				;ftrapnlt.wOpcode_OptimList
	dl	0				;ftrapnltOpcode_OptimList
	dl	0				;ftrapoge.lOpcode_OptimList
	dl	0				;ftrapoge.wOpcode_OptimList
	dl	0				;ftrapogeOpcode_OptimList
	dl	0				;ftrapogl.lOpcode_OptimList
	dl	0				;ftrapogl.wOpcode_OptimList
	dl	0				;ftrapoglOpcode_OptimList
	dl	0				;ftrapogt.lOpcode_OptimList
	dl	0				;ftrapogt.wOpcode_OptimList
	dl	0				;ftrapogtOpcode_OptimList
	dl	0				;ftrapole.lOpcode_OptimList
	dl	0				;ftrapole.wOpcode_OptimList
	dl	0				;ftrapoleOpcode_OptimList
	dl	0				;ftrapolt.lOpcode_OptimList
	dl	0				;ftrapolt.wOpcode_OptimList
	dl	0				;ftrapoltOpcode_OptimList
	dl	0				;ftrapor.lOpcode_OptimList
	dl	0				;ftrapor.wOpcode_OptimList
	dl	0				;ftraporOpcode_OptimList
	dl	0				;ftrapseq.lOpcode_OptimList
	dl	0				;ftrapseq.wOpcode_OptimList
	dl	0				;ftrapseqOpcode_OptimList
	dl	0				;ftrapsf.lOpcode_OptimList
	dl	0				;ftrapsf.wOpcode_OptimList
	dl	0				;ftrapsfOpcode_OptimList
	dl	0				;ftrapsne.lOpcode_OptimList
	dl	0				;ftrapsne.wOpcode_OptimList
	dl	0				;ftrapsneOpcode_OptimList
	dl	0				;ftrapst.lOpcode_OptimList
	dl	0				;ftrapst.wOpcode_OptimList
	dl	0				;ftrapstOpcode_OptimList
	dl	0				;ftrapt.lOpcode_OptimList
	dl	0				;ftrapt.wOpcode_OptimList
	dl	0				;ftraptOpcode_OptimList
	dl	0				;ftrapueq.lOpcode_OptimList
	dl	0				;ftrapueq.wOpcode_OptimList
	dl	0				;ftrapueqOpcode_OptimList
	dl	0				;ftrapuge.lOpcode_OptimList
	dl	0				;ftrapuge.wOpcode_OptimList
	dl	0				;ftrapugeOpcode_OptimList
	dl	0				;ftrapugt.lOpcode_OptimList
	dl	0				;ftrapugt.wOpcode_OptimList
	dl	0				;ftrapugtOpcode_OptimList
	dl	0				;ftrapule.lOpcode_OptimList
	dl	0				;ftrapule.wOpcode_OptimList
	dl	0				;ftrapuleOpcode_OptimList
	dl	0				;ftrapult.lOpcode_OptimList
	dl	0				;ftrapult.wOpcode_OptimList
	dl	0				;ftrapultOpcode_OptimList
	dl	0				;ftrapun.lOpcode_OptimList
	dl	0				;ftrapun.wOpcode_OptimList
	dl	0				;ftrapunOpcode_OptimList
	dl	0				;ftst.bOpcode_OptimList
	dl	0				;ftst.dOpcode_OptimList
	dl	0				;ftst.lOpcode_OptimList
	dl	0				;ftst.pOpcode_OptimList
	dl	0				;ftst.sOpcode_OptimList
	dl	0				;ftst.wOpcode_OptimList
	dl	0				;ftst.xOpcode_OptimList
	dl	0				;ftwotox.bOpcode_OptimList
	dl	0				;ftwotox.dOpcode_OptimList
	dl	0				;ftwotox.lOpcode_OptimList
	dl	0				;ftwotox.pOpcode_OptimList
	dl	0				;ftwotox.sOpcode_OptimList
	dl	0				;ftwotox.wOpcode_OptimList
	dl	0				;ftwotox.xOpcode_OptimList
	dl	0				;illegalOpcode_OptimList
	dl	jmpOpcode_OptimList
	dl	jsrOpcode_OptimList
	dl	0				;lcmoveOpcode_OptimList
	dl	0				;leaOpcode_OptimList
	dl	0				;link.lOpcode_OptimList
	dl	0				;link.wOpcode_OptimList
	dl	0				;linkOpcode_OptimList
	dl	lsl.bOpcode_OptimList
	dl	lsl.lOpcode_OptimList
	dl	lsl.wOpcode_OptimList
	dl	lslOpcode_OptimList
	dl	lsr.bOpcode_OptimList
	dl	0				;lsr.lOpcode_OptimList
	dl	0				;lsr.wOpcode_OptimList
	dl	0				;lsrOpcode_OptimList
	dl	move.bOpcode_OptimList
	dl	move.lOpcode_OptimList
	dl	move.wOpcode_OptimList
	dl	0				;move16Opcode_OptimList
	dl	moveOpcode_OptimList
	dl	movea.lOpcode_OptimList
	dl	movea.wOpcode_OptimList
	dl	moveaOpcode_OptimList
	dl	0				;movecOpcode_OptimList
	dl	movei.bOpcode_OptimList
	dl	movei.lOpcode_OptimList
	dl	movei.wOpcode_OptimList
	dl	moveiOpcode_OptimList
	dl	0				;movem.lOpcode_OptimList
	dl	0				;movem.wOpcode_OptimList
	dl	0				;movemOpcode_OptimList
	dl	0				;movep.lOpcode_OptimList
	dl	0				;movep.wOpcode_OptimList
	dl	0				;movepOpcode_OptimList
	dl	0				;moveqOpcode_OptimList
	dl	0				;moves.bOpcode_OptimList
	dl	0				;moves.lOpcode_OptimList
	dl	0				;moves.wOpcode_OptimList
	dl	0				;movesOpcode_OptimList
	dl	0				;muls.lOpcode_OptimList
	dl	0				;muls.wOpcode_OptimList
	dl	0				;mulsOpcode_OptimList
	dl	0				;mulu.lOpcode_OptimList
	dl	mulu.wOpcode_OptimList
	dl	muluOpcode_OptimList
	dl	0				;nbcdOpcode_OptimList
	dl	0				;neg.bOpcode_OptimList
	dl	0				;neg.lOpcode_OptimList
	dl	0				;neg.wOpcode_OptimList
	dl	0				;negOpcode_OptimList
	dl	0				;negx.bOpcode_OptimList
	dl	0				;negx.lOpcode_OptimList
	dl	0				;negx.wOpcode_OptimList
	dl	0				;negxOpcode_OptimList
	dl	0				;nopOpcode_OptimList
	dl	0				;not.bOpcode_OptimList
	dl	0				;not.lOpcode_OptimList
	dl	0				;not.wOpcode_OptimList
	dl	0				;notOpcode_OptimList
	dl	0				;or.bOpcode_OptimList
	dl	0				;or.lOpcode_OptimList
	dl	0				;or.wOpcode_OptimList
	dl	0				;orOpcode_OptimList
	dl	0				;ori.bOpcode_OptimList
	dl	0				;ori.lOpcode_OptimList
	dl	0				;ori.wOpcode_OptimList
	dl	0				;oriOpcode_OptimList
	dl	0				;packOpcode_OptimList
	dl	0				;pbac.lOpcode_OptimList
	dl	0				;pbac.wOpcode_OptimList
	dl	0				;pbacOpcode_OptimList
	dl	0				;pbas.lOpcode_OptimList
	dl	0				;pbas.wOpcode_OptimList
	dl	0				;pbasOpcode_OptimList
	dl	0				;pbbc.lOpcode_OptimList
	dl	0				;pbbc.wOpcode_OptimList
	dl	0				;pbbcOpcode_OptimList
	dl	0				;pbbs.lOpcode_OptimList
	dl	0				;pbbs.wOpcode_OptimList
	dl	0				;pbbsOpcode_OptimList
	dl	0				;pbcc.lOpcode_OptimList
	dl	0				;pbcc.wOpcode_OptimList
	dl	0				;pbccOpcode_OptimList
	dl	0				;pbcs.lOpcode_OptimList
	dl	0				;pbcs.wOpcode_OptimList
	dl	0				;pbcsOpcode_OptimList
	dl	0				;pbgc.lOpcode_OptimList
	dl	0				;pbgc.wOpcode_OptimList
	dl	0				;pbgcOpcode_OptimList
	dl	0				;pbgs.lOpcode_OptimList
	dl	0				;pbgs.wOpcode_OptimList
	dl	0				;pbgsOpcode_OptimList
	dl	0				;pbic.lOpcode_OptimList
	dl	0				;pbic.wOpcode_OptimList
	dl	0				;pbicOpcode_OptimList
	dl	0				;pbis.lOpcode_OptimList
	dl	0				;pbis.wOpcode_OptimList
	dl	0				;pbisOpcode_OptimList
	dl	0				;pblc.lOpcode_OptimList
	dl	0				;pblc.wOpcode_OptimList
	dl	0				;pblcOpcode_OptimList
	dl	0				;pbls.lOpcode_OptimList
	dl	0				;pbls.wOpcode_OptimList
	dl	0				;pblsOpcode_OptimList
	dl	0				;pbsc.lOpcode_OptimList
	dl	0				;pbsc.wOpcode_OptimList
	dl	0				;pbscOpcode_OptimList
	dl	0				;pbss.lOpcode_OptimList
	dl	0				;pbss.wOpcode_OptimList
	dl	0				;pbssOpcode_OptimList
	dl	0				;pbwc.lOpcode_OptimList
	dl	0				;pbwc.wOpcode_OptimList
	dl	0				;pbwcOpcode_OptimList
	dl	0				;pbws.lOpcode_OptimList
	dl	0				;pbws.wOpcode_OptimList
	dl	0				;pbwsOpcode_OptimList
	dl	0				;pdbacOpcode_OptimList
	dl	0				;pdbasOpcode_OptimList
	dl	0				;pdbbcOpcode_OptimList
	dl	0				;pdbbsOpcode_OptimList
	dl	0				;pdbccOpcode_OptimList
	dl	0				;pdbcsOpcode_OptimList
	dl	0				;pdbgcOpcode_OptimList
	dl	0				;pdbgsOpcode_OptimList
	dl	0				;pdbicOpcode_OptimList
	dl	0				;pdbisOpcode_OptimList
	dl	0				;pdblcOpcode_OptimList
	dl	0				;pdblsOpcode_OptimList
	dl	0				;pdbscOpcode_OptimList
	dl	0				;pdbssOpcode_OptimList
	dl	0				;pdbwcOpcode_OptimList
	dl	0				;pdbwsOpcode_OptimList
	dl	0				;peaOpcode_OptimList
	dl	0				;pflushOpcode_OptimList
	dl	0				;pflushaOpcode_OptimList
	dl	0				;pflushanOpcode_OptimList
	dl	0				;pflushnOpcode_OptimList
	dl	0				;pflushrOpcode_OptimList
	dl	0				;pflushsOpcode_OptimList
	dl	0				;ploadrOpcode_OptimList
	dl	0				;ploadwOpcode_OptimList
	dl	0				;pmove.bOpcode_OptimList
	dl	0				;pmove.lOpcode_OptimList
	dl	0				;pmove.qOpcode_OptimList
	dl	0				;pmove.wOpcode_OptimList
	dl	0				;pmovefd.lOpcode_OptimList
	dl	0				;pmovefd.qOpcode_OptimList
	dl	0				;popOpcode_OptimList
	dl	0				;popmOpcode_OptimList
	dl	0				;prestoreOpcode_OptimList
	dl	0				;psacOpcode_OptimList
	dl	0				;psasOpcode_OptimList
	dl	0				;psaveOpcode_OptimList
	dl	0				;psbcOpcode_OptimList
	dl	0				;psbsOpcode_OptimList
	dl	0				;psccOpcode_OptimList
	dl	0				;pscsOpcode_OptimList
	dl	0				;psgcOpcode_OptimList
	dl	0				;psgsOpcode_OptimList
	dl	0				;psicOpcode_OptimList
	dl	0				;psisOpcode_OptimList
	dl	0				;pslcOpcode_OptimList
	dl	0				;pslsOpcode_OptimList
	dl	0				;psscOpcode_OptimList
	dl	0				;psssOpcode_OptimList
	dl	0				;pswcOpcode_OptimList
	dl	0				;pswsOpcode_OptimList
	dl	0				;ptestrOpcode_OptimList
	dl	0				;ptestwOpcode_OptimList
	dl	0				;ptrapac.lOpcode_OptimList
	dl	0				;ptrapac.wOpcode_OptimList
	dl	0				;ptrapacOpcode_OptimList
	dl	0				;ptrapas.lOpcode_OptimList
	dl	0				;ptrapas.wOpcode_OptimList
	dl	0				;ptrapasOpcode_OptimList
	dl	0				;ptrapbc.lOpcode_OptimList
	dl	0				;ptrapbc.wOpcode_OptimList
	dl	0				;ptrapbcOpcode_OptimList
	dl	0				;ptrapbs.lOpcode_OptimList
	dl	0				;ptrapbs.wOpcode_OptimList
	dl	0				;ptrapbsOpcode_OptimList
	dl	0				;ptrapcc.lOpcode_OptimList
	dl	0				;ptrapcc.wOpcode_OptimList
	dl	0				;ptrapccOpcode_OptimList
	dl	0				;ptrapcs.lOpcode_OptimList
	dl	0				;ptrapcs.wOpcode_OptimList
	dl	0				;ptrapcsOpcode_OptimList
	dl	0				;ptrapgc.lOpcode_OptimList
	dl	0				;ptrapgc.wOpcode_OptimList
	dl	0				;ptrapgcOpcode_OptimList
	dl	0				;ptrapgs.lOpcode_OptimList
	dl	0				;ptrapgs.wOpcode_OptimList
	dl	0				;ptrapgsOpcode_OptimList
	dl	0				;ptrapic.lOpcode_OptimList
	dl	0				;ptrapic.wOpcode_OptimList
	dl	0				;ptrapicOpcode_OptimList
	dl	0				;ptrapis.lOpcode_OptimList
	dl	0				;ptrapis.wOpcode_OptimList
	dl	0				;ptrapisOpcode_OptimList
	dl	0				;ptraplc.lOpcode_OptimList
	dl	0				;ptraplc.wOpcode_OptimList
	dl	0				;ptraplcOpcode_OptimList
	dl	0				;ptrapls.lOpcode_OptimList
	dl	0				;ptrapls.wOpcode_OptimList
	dl	0				;ptraplsOpcode_OptimList
	dl	0				;ptrapsc.lOpcode_OptimList
	dl	0				;ptrapsc.wOpcode_OptimList
	dl	0				;ptrapscOpcode_OptimList
	dl	0				;ptrapss.lOpcode_OptimList
	dl	0				;ptrapss.wOpcode_OptimList
	dl	0				;ptrapssOpcode_OptimList
	dl	0				;ptrapwc.lOpcode_OptimList
	dl	0				;ptrapwc.wOpcode_OptimList
	dl	0				;ptrapwcOpcode_OptimList
	dl	0				;ptrapws.lOpcode_OptimList
	dl	0				;ptrapws.wOpcode_OptimList
	dl	0				;ptrapwsOpcode_OptimList
	dl	0				;pushOpcode_OptimList
	dl	0				;pushmOpcode_OptimList
	dl	0				;pvalidOpcode_OptimList
	dl	0				;resetOpcode_OptimList
	dl	rol.bOpcode_OptimList
	dl	0				;rol.lOpcode_OptimList
	dl	0				;rol.wOpcode_OptimList
	dl	rolOpcode_OptimList
	dl	ror.bOpcode_OptimList
	dl	0				;ror.lOpcode_OptimList
	dl	0				;ror.wOpcode_OptimList
	dl	rorOpcode_OptimList
	dl	roxl.bOpcode_OptimList
	dl	roxl.lOpcode_OptimList
	dl	roxl.wOpcode_OptimList
	dl	roxlOpcode_OptimList
	dl	roxr.bOpcode_OptimList
	dl	0				;roxr.lOpcode_OptimList
	dl	0				;roxr.wOpcode_OptimList
	dl	roxrOpcode_OptimList
	dl	0				;rtdOpcode_OptimList
	dl	0				;rteOpcode_OptimList
	dl	0				;rtmOpcode_OptimList
	dl	0				;rtrOpcode_OptimList
	dl	rtsOpcode_OptimList
	dl	0				;sbcdOpcode_OptimList
	dl	0				;sccOpcode_OptimList
	dl	0				;scsOpcode_OptimList
	dl	0				;seqOpcode_OptimList
	dl	sfOpcode_OptimList
	dl	0				;sgeOpcode_OptimList
	dl	0				;sgtOpcode_OptimList
	dl	0				;shiOpcode_OptimList
	dl	0				;shsOpcode_OptimList
	dl	0				;sleOpcode_OptimList
	dl	0				;sloOpcode_OptimList
	dl	0				;slsOpcode_OptimList
	dl	0				;sltOpcode_OptimList
	dl	0				;smiOpcode_OptimList
	dl	0				;sneOpcode_OptimList
	dl	0				;splOpcode_OptimList
	dl	stOpcode_OptimList
	dl	0				;stopOpcode_OptimList
	dl	sub.bOpcode_OptimList
	dl	sub.lOpcode_OptimList
	dl	sub.wOpcode_OptimList
	dl	subOpcode_OptimList
	dl	suba.lOpcode_OptimList
	dl	suba.wOpcode_OptimList
	dl	subaOpcode_OptimList
	dl	subi.bOpcode_OptimList
	dl	subi.lOpcode_OptimList
	dl	subi.wOpcode_OptimList
	dl	subiOpcode_OptimList
	dl	0				;subq.bOpcode_OptimList
	dl	0				;subq.lOpcode_OptimList
	dl	0				;subq.wOpcode_OptimList
	dl	0				;subqOpcode_OptimList
	dl	0				;subx.bOpcode_OptimList
	dl	0				;subx.lOpcode_OptimList
	dl	0				;subx.wOpcode_OptimList
	dl	0				;subxOpcode_OptimList
	dl	0				;svcOpcode_OptimList
	dl	0				;svsOpcode_OptimList
	dl	0				;swapOpcode_OptimList
	dl	0				;tasOpcode_OptimList
	dl	0				;trapOpcode_OptimList
	dl	0				;trapcc.lOpcode_OptimList
	dl	0				;trapcc.wOpcode_OptimList
	dl	0				;trapccOpcode_OptimList
	dl	0				;trapcs.lOpcode_OptimList
	dl	0				;trapcs.wOpcode_OptimList
	dl	0				;trapcsOpcode_OptimList
	dl	0				;trapeq.lOpcode_OptimList
	dl	0				;trapeq.wOpcode_OptimList
	dl	0				;trapeqOpcode_OptimList
	dl	0				;trapf.lOpcode_OptimList
	dl	0				;trapf.wOpcode_OptimList
	dl	0				;trapfOpcode_OptimList
	dl	0				;trapge.lOpcode_OptimList
	dl	0				;trapge.wOpcode_OptimList
	dl	0				;trapgeOpcode_OptimList
	dl	0				;trapgt.lOpcode_OptimList
	dl	0				;trapgt.wOpcode_OptimList
	dl	0				;trapgtOpcode_OptimList
	dl	0				;traphi.lOpcode_OptimList
	dl	0				;traphi.wOpcode_OptimList
	dl	0				;traphiOpcode_OptimList
	dl	0				;traple.lOpcode_OptimList
	dl	0				;traple.wOpcode_OptimList
	dl	0				;trapleOpcode_OptimList
	dl	0				;trapls.lOpcode_OptimList
	dl	0				;trapls.wOpcode_OptimList
	dl	0				;traplsOpcode_OptimList
	dl	0				;traplt.lOpcode_OptimList
	dl	0				;traplt.wOpcode_OptimList
	dl	0				;trapltOpcode_OptimList
	dl	0				;trapmi.lOpcode_OptimList
	dl	0				;trapmi.wOpcode_OptimList
	dl	0				;trapmiOpcode_OptimList
	dl	0				;trapne.lOpcode_OptimList
	dl	0				;trapne.wOpcode_OptimList
	dl	0				;trapneOpcode_OptimList
	dl	0				;trappl.lOpcode_OptimList
	dl	0				;trappl.wOpcode_OptimList
	dl	0				;trapplOpcode_OptimList
	dl	0				;trapt.lOpcode_OptimList
	dl	0				;trapt.wOpcode_OptimList
	dl	0				;traptOpcode_OptimList
	dl	0				;trapvOpcode_OptimList
	dl	0				;trapvc.lOpcode_OptimList
	dl	0				;trapvc.wOpcode_OptimList
	dl	0				;trapvcOpcode_OptimList
	dl	0				;trapvs.lOpcode_OptimList
	dl	0				;trapvs.wOpcode_OptimList
	dl	0				;trapvsOpcode_OptimList
	dl	tst.bOpcode_OptimList
	dl	tst.lOpcode_OptimList
	dl	tst.wOpcode_OptimList
	dl	tstOpcode_OptimList
	dl	0				;unlkOpcode_OptimList
	dl	0				;unpkOpcode_OptimList

	dl	pcrelControlStruct
	dl	absoluteShortControlStruct
	dl	baseRegControlStructure
	dl	nullDispControlStruct
	dl	byteBranchControlStruct
	dl	wordBranchControlStruct
	dl	nullBranchControlStruct
	dl	unrefLabelControlStruct

********************************************************************************
********************************************************************************
*                        OPTIMIZATION EVALUATION UNITS                         *
********************************************************************************
********************************************************************************

***** VALID ID NUMBERS
*
*  Basically any word value that you like.
*  The ID numbers are currently set up to work with "optim68.rexx" so if you
* change them you will have to write your own rexx interface program or equivilent.
*
*  autoFix  = tell AREXX to automatically fix this line if possible.
*  showUser = tell AREXX not to replace this line by itself.
*
*****


	oddok

add.bOpcode_OptimList:
add.lOpcode_OptimList:
add.wOpcode_OptimList:
addOpcode_OptimList:
adda.lOpcode_OptimList:
adda.wOpcode_OptimList:
addaOpcode_OptimList:
addi.bOpcode_OptimList:
addi.lOpcode_OptimList:
addi.wOpcode_OptimList:
addiOpcode_OptimList:

;if n = 0 then remove
	nextLink	add_1			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		0			;if value is equal to next longword
	if_NoLabel				;if line has no label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		AddRemove_OptimMsg
	OEU_end

;if n = 0 then remove
add_1:	nextLink	add_2			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		0			;if value is equal to next longword
	if_Label				;if line has label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	AlwaysShowUser				;automation = never
	Message		AddRemove_OptimMsg
	OEU_end

;if n >= 1 and n <= 8 then optimize to addq
add_2:	nextLink	add_3			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_GE		1			;if value is greater or equal to next longword
	if_LE		8			;if value is less or equal to next longword
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	autoFix			;special automation code
	Message		AddAddq_OptimMsg
	OptimString	AddAddq_OptimProc
	OEU_end

;if n >= 9 and n <= 16 then optimize to addq * 2
add_3:	nextLink	add_4			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_GE		9			;if value is greater or equal to next longword
	if_LE		16			;if value is less or equal to next longword
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		AddAddq2_OptimMsg
	OptimString	AddAddq2_OptimProc
	OEU_end

;if n >= 17 and n <= 32767 then optimize to lea
add_4:	nextLink	0			;end of chain
	if_Operand2	addressReg		;if the destination is address register
	if_ImmediateSrc				;if first field is an immediate
	if_GE		-32768			;if value is greater or equal to next longword
	if_LE		32767			;if value is less or equal to next longword
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		AddaLea_OptimMsg
	OptimString	AddaLea_OptimProc
	OEU_end

*****

and.bOpcode_OptimList:
and.lOpcode_OptimList:
and.wOpcode_OptimList:
andOpcode_OptimList:
andi.bOpcode_OptimList:
andi.lOpcode_OptimList:
andi.wOpcode_OptimList:
andiOpcode_OptimList:
	nextLink	and_1
	if_ImmediateSrc
	if_GE		-128			;if value is greater or equal to -128
	if_LE		127			;if value is less or equal to 127
	if_Operand2	dataReg			;if the destination is data register
	ifSame_Operand2	remIndex1,oneLineAgo,moveLast,Operand2
	ifPrev_Operand	remIndex1,oneLineAgo,moveLast,Operand1,addrRegDirect,falseIfSame
	if_NoLabel				;if line has no label
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		moveAnd_OptimMsg
	OptimString	moveAnd_OptimProc	;source code substitution proceedure
	OEU_end

and_1:	nextLink	0
	if_ImmediateSrc
	if_GE		-128			;if value is greater or equal to -128
	if_LE		127			;if value is less or equal to 127
	if_Operand2	dataReg			;if the destination is data register
	ifSame_Operand2	remIndex1,oneLineAgo,moveLast,Operand2
	ifPrev_Operand	remIndex1,oneLineAgo,moveLast,Operand1,addrRegDirect,falseIfSame
	if_Label				;if line has label
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	AlwaysShowUser				;automation = never
	Message		moveAndCaution_OptimMsg
	OptimString	moveAndCaution_OptimProc	;source code substitution proceedure
	OEU_end

*****

sub.bOpcode_OptimList:
sub.lOpcode_OptimList:
sub.wOpcode_OptimList:
subOpcode_OptimList:
suba.lOpcode_OptimList:
suba.wOpcode_OptimList:
subaOpcode_OptimList:
subi.bOpcode_OptimList:
subi.lOpcode_OptimList:
subi.wOpcode_OptimList:
subiOpcode_OptimList:

;if n = 0 then remove
	nextLink	sub_1			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		0			;if value is 0
	if_NoLabel				;if line has no label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		SubRemove_OptimMsg
	OEU_end

sub_1:	nextLink	sub_2			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		0			;if value is 0
	if_Label				;if line has label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	AlwaysShowUser				;automation = never
	Message		SubRemove_OptimMsg
	OEU_end

;if n >= 1 and n <= 8 then optimize to addq
sub_2:	nextLink	sub_3			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_GE		1			;if value is greater or equal to 1
	if_LE		8			;if value is less or equal to 8
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	autoFix			;special automation code
	Message		SubSubq_OptimMsg
	OptimString	SubSubq_OptimProc
	OEU_end

;if n >= 9 and n <= 16 then optimize to addq * 2
sub_3:	nextLink	sub_4			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_GE		9			;if value is greater or equal to 9
	if_LE		16			;if value is less or equal to 16
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		SubSubq2_OptimMsg
	OptimString	SubSubq2_OptimProc
	OEU_end

;if n >= 17 and n <= 32767 then optimize to lea
sub_4:	nextLink	0			;end of chain
	if_Operand2	addressReg		;if the destination is address register
	if_ImmediateSrc				;if first field is an immediate
	if_GE		-32768			;if value is greater or equal to -32768
	if_LE		32767			;if value is less or equal to 32767
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		SubaLea_OptimMsg
	OptimString	SubaLea_OptimProc
	OEU_end

*****

move.bOpcode_OptimList:
move.lOpcode_OptimList:
move.wOpcode_OptimList:
moveOpcode_OptimList:
movea.lOpcode_OptimList:
movea.wOpcode_OptimList:
moveaOpcode_OptimList:
movei.bOpcode_OptimList:
movei.lOpcode_OptimList:
movei.wOpcode_OptimList:
moveiOpcode_OptimList:
	nextLink	move_0
	if_Operand2	dataReg		;condition 1 -> is destination a data register ?
	Action		rememberInfo,remIndex1,moveLast	;remember the operand information
	OEU_end

move_0:	nextLink	move_0
	ifNot_Operand2	addressReg		;condition 1 -> is destination a data register ?
	Action		rememberInfo,remIndex10,flagsLast	;remember flags affected
	OEU_end

move_1:	nextLink	move_2			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		0			;if value is 0
	if_Operand2	addressReg		;if the destination is address register
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MoveaSuba_OptimMsg
	OptimString	MoveaSuba_OptimProc
	OEU_end

move_2:	nextLink	move_3			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_WordSize				;if size is word
	if_EQ		0			;if value is 0
	if_Operand2	dataReg			;if the destination is data register
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MovewClrw_OptimMsg
	OptimString	MovewClrw_OptimProc
	OEU_end

move_3:	nextLink	move_4			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_ByteSize				;if size is byte
	if_EQ		0			;if value is 0
	if_Operand2	dataReg			;if the destination is data register
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MovebClrb_OptimMsg
	OptimString	MovebClrb_OptimProc
	OEU_end

move_4:	nextLink	move_5			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_WordSize				;if size is word
	if_EQ		0			;if value is 0
	if_Operand2	controlMode		;if the destination is...
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MovewClrw_OptimMsg
	OptimString	MovewClrw_OptimProc
	OEU_end

move_5:	nextLink	move_6			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_ByteSize				;if size is byte
	if_EQ		0			;if value is 0
	if_Operand2	controlMode		;if the destination is...
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MovebClrb_OptimMsg
	OptimString	MovebClrb_OptimProc
	OEU_end

move_6:	nextLink	move_7			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_GE		-128			;if value is greater or equal to -128
	if_LE		127			;if value is less or equal to 127
	if_Operand2	dataReg			;if the destination is data register
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MoveMoveq_OptimMsg
	OptimString	MoveMoveq_OptimProc
	OEU_end

move_7:	nextLink	move_8
	if_ImmediateSrc				;condition 1 -> is source operand immediate ?
	if_EQ		4294967040		;condition 2 -> is immediate value = 4294967040 ?
	if_Operand2	dataReg			;condition 3 -> is destination a data register ?
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		MoveMoveqClrb_OptimMsg	;message that goes with this optimization
	OptimString	MoveMoveqClrb_OptimProc	;source code substitution proceedure
	OEU_end

move_8:	nextLink	move_9
	if_ImmediateSrc				;condition 1 -> is source operand immediate ?
	if_EQ		4294901760		;condition 2 -> is immediate value = 4294901760 ?
	if_Operand2	dataReg			;condition 3 -> is destination a data register ?
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		MoveMoveqClrw_OptimMsg	;message that goes with this optimization
	OptimString	MoveMoveqClrw_OptimProc	;source code substitution proceedure
	OEU_end

move_9:	nextLink	move_10
	if_ImmediateSrc				;condition 1 -> is source operand immediate ?
	if_GE		129			;condition 2 -> is immediate value >= 129 ?
	if_LE		255			;condition 3 -> is immediate value <= 255 ?
	if_Operand2	dataReg			;condition 4 -> is destination a data register ?
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		MoveMoveqNegb_OptimMsg	;message that goes with this optimization
	OptimString	MoveMoveqNegb_OptimProc	;source code substitution proceedure
	OEU_end

move_10:
	nextLink	move_11
	if_ImmediateSrc				;condition 1 -> is source operand immediate ?
	if_GE		65409			;condition 2 -> is immediate value >= 65409 ?
	if_LE		65535			;condition 3 -> is immediate value <= 65535 ?
	if_Operand2	dataReg			;condition 4 -> is destination a data register ?
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		MoveMoveqNegw_OptimMsg	;message that goes with this optimization
	OptimString	MoveMoveqNegw_OptimProc	;source code substitution proceedure
	OEU_end


move_11:
	nextLink	move_12
	if_ImmediateSrc				;condition 1 -> is source operand immediate ?
	if_GE		4294967041		;condition 2 -> is immediate value >= 4294901761 ?
	if_LE		4294967168		;condition 3 -> is immediate value <= 4294901888 ?
	if_Operand2	dataReg			;condition 4 -> is destination a data register ?
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		MoveMoveqMNegb_OptimMsg	;message that goes with this optimization
	OptimString	MoveMoveqMNegb_OptimProc	;source code substitution proceedure
	OEU_end

move_12:
	nextLink	move_13
	if_ImmediateSrc				;condition 1 -> is source operand immediate ?
	if_GE		4294901761		;condition 2 -> is immediate value >= 4294901761 ?
	if_LE		4294901888		;condition 3 -> is immediate value <= 4294901888 ?
	if_Operand2	dataReg			;condition 4 -> is destination a data register ?
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		MoveMoveqMNegw_OptimMsg	;message that goes with this optimization
	OptimString	MoveMoveqMNegw_OptimProc	;source code substitution proceedure
	OEU_end

move_13:
	nextLink	0
	if_ImmediateSrc
	if_Operand2	addressReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		MoveaLea_OptimMsg	;message that goes with this optimization
	OptimString	MoveaLea_OptimProc	;source code substitution proceedure
	OEU_end


*****

btst.bOpcode_OptimList:
btst.lOpcode_OptimList:
btstOpcode_OptimList:
	nextLink	btst_2
	if_ImmediateSrc
	if_EQ		7
	Action		rememberInfo,remIndex1,btst7Last	;just remember it
	OEU_end

btst_2:	nextLink	btst_3
	if_ImmediateSrc
	if_EQ		15
	Action		rememberInfo,remIndex1,btst15Last	;just remember it
	OEU_end

btst_3:	nextLink	0
	if_ImmediateSrc
	if_EQ		31
	Action		rememberInfo,remIndex1,btst31Last	;just remember it
	OEU_end

*****

beq.bOpcode_OptimList:
beq.lOpcode_OptimList:
beq.wOpcode_OptimList:
beqOpcode_OptimList:
	nextLink	beq_2
	if_Remembered	remIndex1,oneLineAgo,btst7Last
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		BtstBeqTstbBpl_OptimMsg	;message that goes with this optimization
	OptimString	BtstBeqTstbBpl_OptimProc	;source code substitution proceedure
	OEU_end

beq_2:	nextLink	beq_3
	if_Remembered	remIndex1,oneLineAgo,btst15Last
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		BtstBeqTstwBpl_OptimMsg	;message that goes with this optimization
	OptimString	BtstBeqTstwBpl_OptimProc	;source code substitution proceedure
	OEU_end

beq_3:	nextLink	0
	if_Remembered	remIndex1,oneLineAgo,btst31Last
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		BtstBeqTstlBpl_OptimMsg	;message that goes with this optimization
	OptimString	BtstBeqTstlBpl_OptimProc	;source code substitution proceedure
	OEU_end

bne.bOpcode_OptimList:
bne.lOpcode_OptimList:
bne.wOpcode_OptimList:
bneOpcode_OptimList:
	nextLink	bne_2
	if_Remembered	remIndex1,oneLineAgo,btst7Last
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		BtstBneTstbBmi_OptimMsg	;message that goes with this optimization
	OptimString	BtstBneTstbBmi_OptimProc	;source code substitution proceedure
	OEU_end

bne_2:	nextLink	bne_3
	if_Remembered	remIndex1,oneLineAgo,btst15Last
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		BtstBneTstwBmi_OptimMsg	;message that goes with this optimization
	OptimString	BtstBneTstwBmi_OptimProc	;source code substitution proceedure
	OEU_end

bne_3:	nextLink	0
	if_Remembered	remIndex1,oneLineAgo,btst31Last
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		BtstBneTstlBmi_OptimMsg	;message that goes with this optimization
	OptimString	BtstBneTstlBmi_OptimProc	;source code substitution proceedure
	OEU_end


*****

jsrOpcode_OptimList:
	nextLink	jsr_1
	Action		rememberInfo,remIndex1,jsrLast	;just remember it
	OEU_end

jsr_1:	nextLink	0
	if_Operand1	PCBaseDisp		;is destination pc relative ?
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		JsrBsr_OptimMsg		;message that goes with this optimization
	OptimString	JsrBsr_OptimProc	;source code substitution proceedure
	OEU_end

*****

jmpOpcode_OptimList:
	nextLink	0
	if_Operand1	PCBaseDisp		;is destination pc relative ?
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		JmpBra_OptimMsg		;message that goes with this optimization
	OptimString	JmpBra_OptimProc	;source code substitution proceedure
	OEU_end

*****

bsr.bOpcode_OptimList:
bsr.lOpcode_OptimList:
bsr.wOpcode_OptimList:
bsrOpcode_OptimList:
	nextLink	0
	Action		rememberInfo,remIndex1,bsrLast	;just remember it
	OEU_end

*****

rtsOpcode_OptimList:
	nextLink	rts_2
	if_NoLabel				;if line has no label
	if_Remembered	remIndex1,oneLineAgo,bsrLast
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		BsrRtsBra_OptimMsg	;message that goes with this optimization
	OptimString	BsrRtsBra_OptimProc	;source code substitution proceedure
	OEU_end

rts_2:	nextLink	rts_3
	if_Label				;if line has label
	if_Remembered	remIndex1,oneLineAgo,bsrLast
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		BsrRtsBraRts_OptimMsg	;message that goes with this optimization
	OptimString	BsrRtsBraRts_OptimProc	;source code substitution proceedure
	OEU_end

rts_3:	nextLink	rts_4
	if_NoLabel				;if line has no label
	if_Remembered	remIndex1,oneLineAgo,jsrLast
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		JsrRtsJmp_OptimMsg	;message that goes with this optimization
	OptimString	JsrRtsJmp_OptimProc	;source code substitution proceedure
	OEU_end

rts_4:	nextLink	0
	if_Label				;if line has label
	if_Remembered	remIndex1,oneLineAgo,jsrLast
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		JsrRtsJmpRts_OptimMsg	;message that goes with this optimization
	OptimString	JsrRtsJmpRts_OptimProc	;source code substitution proceedure
	OEU_end

*****

asl.bOpcode_OptimList:
asl.lOpcode_OptimList:
asl.wOpcode_OptimList:
aslOpcode_OptimList:
lsl.bOpcode_OptimList:
lsl.lOpcode_OptimList:
lsl.wOpcode_OptimList:
lslOpcode_OptimList:
	nextLink	xsd_2
	if_ImmediateSrc
	if_EQ		1
	if_Operand2	dataReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		XslAdd_OptimMsg		;message that goes with this optimization
	OptimString	XslAdd_OptimProc		;source code substitution proceedure
	OEU_end

asr.bOpcode_OptimList:
lsr.bOpcode_OptimList:
xsd_2:	nextLink	0
	if_ImmediateSrc
	if_ByteSize
	if_EQ		8
	if_Operand2	dataReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		XslClr_OptimMsg		;message that goes with this optimization
	OptimString	XslClr_OptimProc	;source code substitution proceedure
	OEU_end

*****

rol.bOpcode_OptimList:
rolOpcode_OptimList:
	nextLink	rol_1			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_ByteSize
	if_EQ		8			;if value is 0
	if_NoLabel				;if line has no label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		srRemove_OptimMsg
	OEU_end

rol_1:	nextLink	rol_2			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_ByteSize
	if_EQ		8			;if value is 0
	if_Label				;if line has label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	AlwaysShowUser				;automation = never
	Message		srRemove_OptimMsg
	OEU_end

rol_2:	nextLink	0
	if_ImmediateSrc
	if_ByteSize
	if_GE		5
	if_LE		7
	if_Operand2	dataReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		rolRor_OptimMsg		;message that goes with this optimization
	OptimString	rolRor_OptimProc		;source code substitution proceedure
	OEU_end

*****

ror.bOpcode_OptimList:
rorOpcode_OptimList:
	nextLink	ror_1			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_ByteSize
	if_EQ		8			;if value is 0
	if_NoLabel				;if line has no label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		srRemove_OptimMsg
	OEU_end

ror_1:	nextLink	ror_2			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_ByteSize
	if_EQ		8			;if value is 0
	if_Label				;if line has label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	AlwaysShowUser				;automation = never
	Message		srRemove_OptimMsg
	OEU_end

ror_2:	nextLink	0
	if_ImmediateSrc
	if_ByteSize
	if_GE		5
	if_LE		7
	if_Operand2	dataReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		rorRol_OptimMsg		;message that goes with this optimization
	OptimString	rorRol_OptimProc		;source code substitution proceedure
	OEU_end

*****

roxl.bOpcode_OptimList:
roxlOpcode_OptimList:
	nextLink	roxl_2
	if_ImmediateSrc
	if_ByteSize
	if_GE		6
	if_LE		8
	if_Operand2	dataReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		roxlRoxr_OptimMsg	;message that goes with this optimization
	OptimString	roxlRoxr_OptimProc	;source code substitution proceedure
	OEU_end

roxl.lOpcode_OptimList:
roxl.wOpcode_OptimList:
roxl_2:	nextLink	0
	if_ImmediateSrc
	if_EQ		1
	if_Operand2	dataReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		roxlAddx_OptimMsg	;message that goes with this optimization
	OptimString	roxlAddx_OptimProc	;source code substitution proceedure
	OEU_end

*****

roxr.bOpcode_OptimList:
roxrOpcode_OptimList:
	nextLink	0
	if_ImmediateSrc
	if_ByteSize
	if_GE		6
	if_LE		8
	if_Operand2	dataReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		roxrRoxl_OptimMsg	;message that goes with this optimization
	OptimString	roxrRoxl_OptimProc	;source code substitution proceedure
	OEU_end

*****

sfOpcode_OptimList:
	nextLink	0
	if_020
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		sfClr_OptimMsg		;message that goes with this optimization
	OptimString	sfClr_OptimProc		;source code substitution proceedure
	OEU_end

*****

stOpcode_OptimList:
	nextLink	0
	if_020
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		stMove_OptimMsg		;message that goes with this optimization
	OptimString	stMove_OptimProc		;source code substitution proceedure
	OEU_end

*****

clr.lOpcode_OptimList:
	nextLink	0
	if_Operand2	dataReg
	Action		substituteLine		;build replacement source code
	Output		xxxxExport		;output the suggestion to error file (if specified)
	Automation	showUser		;no automation
	Message		clrMoveq_OptimMsg	;message that goes with this optimization
	OptimString	clrMoveq_OptimProc	;source code substitution proceedure
	OEU_end

*****

tst.bOpcode_OptimList:
tst.lOpcode_OptimList:
tst.wOpcode_OptimList:
tstOpcode_OptimList:
	nextLink	tst_1
	ifSame_Operand1	remIndex10,oneLineAgo,flagsLast,Operand2
	if_NoLabel				;if line has no label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		tstRemove_OptimMsg
	OEU_end

tst_1:	nextLink	0
	ifSame_Operand1	remIndex10,oneLineAgo,flagsLast,Operand2
	if_Label				;if line has label
	Action		removeLine		;type of action to take
	Output		xxxxExport		;form of output
	AlwaysShowUser				;automation = never
	Message		tstRemove_OptimMsg
	OEU_end

*****

divu.wOpcode_OptimList:
divuOpcode_OptimList:
	nextLink	divu_1			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		2			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		DivuLsr2_OptimMsg
	OptimString	DivuLsr2_OptimProc
	OEU_end

divu_1:	nextLink	divu_2			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		4			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		DivuLsr4_OptimMsg
	OptimString	DivuLsr4_OptimProc
	OEU_end

divu_2:	nextLink	divu_3			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		8			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		DivuLsr8_OptimMsg
	OptimString	DivuLsr8_OptimProc
	OEU_end

divu_3:	nextLink	divu_4			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		16			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		DivuLsr16_OptimMsg
	OptimString	DivuLsr16_OptimProc
	OEU_end

divu_4:	nextLink	divu_5			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		32			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		DivuLsr32_OptimMsg
	OptimString	DivuLsr32_OptimProc
	OEU_end

divu_5:	nextLink	divu_6			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		64			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		DivuLsr64_OptimMsg
	OptimString	DivuLsr64_OptimProc
	OEU_end

divu_6:	nextLink	divu_7			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		128			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		DivuLsr128_OptimMsg
	OptimString	DivuLsr128_OptimProc
	OEU_end

divu_7:	nextLink	0			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		256			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		DivuLsr256_OptimMsg
	OptimString	DivuLsr256_OptimProc
	OEU_end

*****

mulu.wOpcode_OptimList:
muluOpcode_OptimList:
	nextLink	mulu_1			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		2			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluAdd_OptimMsg
	OptimString	MuluAdd_OptimProc
	OEU_end

mulu_1:	nextLink	mulu_2			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		4			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluAddAdd_OptimMsg
	OptimString	MuluAddAdd_OptimProc
	OEU_end

mulu_2:	nextLink	mulu_3			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		8			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluLsl8_OptimMsg
	OptimString	MuluLsl8_OptimProc
	OEU_end

mulu_3:	nextLink	mulu_4			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		16			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluLsl16_OptimMsg
	OptimString	MuluLsl16_OptimProc
	OEU_end

mulu_4:	nextLink	mulu_5			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		32			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluLsl32_OptimMsg
	OptimString	MuluLsl32_OptimProc
	OEU_end

mulu_5:	nextLink	mulu_6			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		64			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluLsl64_OptimMsg
	OptimString	MuluLsl64_OptimProc
	OEU_end

mulu_6:	nextLink	mulu_7			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		128			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluLsl128_OptimMsg
	OptimString	MuluLsl128_OptimProc
	OEU_end

mulu_7:	nextLink	mulu_8			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		256			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluLsl256_OptimMsg
	OptimString	MuluLsl256_OptimProc
	OEU_end

mulu_8:	nextLink	mulu_9			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		512			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluLsl256Add_OptimMsg
	OptimString	MuluLsl256Add_OptimProc
	OEU_end

mulu_9:	nextLink	0			;next test in chain
	if_ImmediateSrc				;if first field is an immediate
	if_EQ		1024			;if value is 2
	Action		substituteLine		;type of action to take
	Output		xxxxExport		;form of output
	Automation	showUser		;special automation code
	Message		MuluLsl256AddAdd_OptimMsg
	OptimString	MuluLsl256AddAdd_OptimProc
	OEU_end




















*****

pcrelControlStruct:
	nextLink	pcrel2
	if_Operand1	AbsoluteLong
	Action		substituteLine
	Output		xxxxExport
	Automation	showUser
	Message		usePCRel_OptimMsg
	OptimString	srcPCRel_OptimProc
	OEU_end

pcrel2:	nextLink	0
	if_Operand2	AbsoluteLong
	Action		substituteLine
	Output		xxxxExport
	Automation	showUser
	Message		usePCRel_OptimMsg
	OptimString	destPCRel_OptimProc
	OEU_end

*****

absoluteShortControlStruct:
	nextLink	absSht
	if_Operand1	AbsoluteLong
	Action		substituteLine
	Output		xxxxExport
	Automation	showUser
	Message		absoluteShort_OptimMsg
	OptimString	absoluteShortSrc_OptimProc
	OEU_end

absSht:	nextLink	0
	if_Operand2	AbsoluteLong
	Action		substituteLine
	Output		xxxxExport
	Automation	showUser
	Message		absoluteShort_OptimMsg
	OptimString	absoluteShortDest_OptimProc
	OEU_end

*****

baseRegControlStructure:
	nextLink	0
	Action		reportLine	;not enough information is available to suggest a replacement
	Output		xxxxExport
	Automation	tellUser
	Message		baseRegMessageStub_File
	Message		baseRegMessageStub_Screen
	OEU_end

*****

nullDispControlStruct:
	nextLink	0
	Action		ignoreLine	;too many variables (read user preferences) to try to suggest a replacement use "reportLine" if not ignoring)
	Output		xxxxExport
	Automation	tellUser
	Message		nullDispMessageStub_File
	Message		nullDispMessageStub_Screen
	OEU_end

*****

byteBranchControlStruct:
	nextLink	0
	Action		substituteLine
	Output		xxxxExport
	Automation	showUser
	Message		byteBranch_OptimMsg
	OptimString	byteBranch_OptimProc
	OEU_end

*****

wordBranchControlStruct:
	nextLink	0
	Action		substituteLine
	Output		xxxxExport
	Automation	showUser
	Message		wordBranch_OptimMsg
	OptimString	wordBranch_OptimProc
	OEU_end

*****

nullBranchControlStruct:
	nextLink	0
	Action		reportLine	;too many variables (read user preferences) to try to suggest a replacement
	Output		xxxxExport
	Automation	tellUser
	Message		nullBranchMessageStub_File
	OptimString	nullBranchMessageStub_Screen
	OEU_end

*****

unrefLabelControlStruct:
	nextLink	0
	Action		substituteLine
	Output		xxxxExport
	Automation	showUser
	Message		unrefLab_OptimMsg
	OptimString	unrefLab_OptimProc
	OEU_end

********************************************************************************
********************************************************************************
*                    SPECIAL OPTIMIZATION SPECIFIC MESSAGES                    *
********************************************************************************
********************************************************************************


moveAndCaution_OptimMsg:
	db	'CAUTION --- LABEL MAY CONFLICT WITH THIS OPTIMIZATION.',Lf
moveAnd_OptimMsg:
	db	'Use a "moveq" first followed by an "and" instead of andi.',Lf
	db	'This optimization is both smaller and will execute faster.',Lf
	cstr	'No flags are changed by this substitution.'

AddRemove_OptimMsg:
SubRemove_OptimMsg:
	db	'Nothing is gained by adding or subtracting zero.  If you',Lf
	db	'are testing the flags after this instruction then substitute',Lf
	db	'a TST instruction instead.  Remember that no flags are',Lf
	db	'affected by this instruction if the destination is an address',Lf
	cstr	'register.'

AddAddq_OptimMsg:
SubSubq_OptimMsg:
	db	'Use the QUICK instruction for all immediate values',Lf
	db	'between 1 and 8 inclusive.  The flags are not affected',Lf
	db	'by this instruction when the destination is an address',Lf
	db	'register, otherwise the effect is the same as for the',Lf
	cstr	'instruction replaced.'

AddAddq2_OptimMsg:
SubSubq2_OptimMsg:
	db	'Using two QUICK instructions will result in faster and',Lf
	db	'possibly smaller code (at least it won''t be any larger).',Lf
	db	'The flags will be affected in exactly the same manner as',Lf
	cstr	'for the instruction being replaced.'

AddaLea_OptimMsg:
SubaLea_OptimMsg:
	db	'Use LEA for values between -32768 and 32767.  There is no',Lf
	cstr	'change in the effect on the flags.'

MoveaSuba_OptimMsg:
	db	'Use SUBA to clear an address register.  It is both smaller',Lf
	cstr	'and faster.  Flags are not affected.'

MoveMoveq_OptimMsg:
	db	'Use the QUICK instruction for all immediate values',Lf
	db	'between -128 and +127 inclusive.  The flags are affected',Lf
	cstr	'in the same manner as for the instruction replaced.'

MovewClrw_OptimMsg:
MovebClrb_OptimMsg:
	db	'Use the CLR instruction to zero a byte or a word of a',Lf
	db	'data register.  Flags will be set the same as for the',Lf
	cstr	'instruction replaced.'

MoveMoveqClrb_OptimMsg:
MoveMoveqClrw_OptimMsg:
MoveMoveqNegb_OptimMsg:
MoveMoveqNegw_OptimMsg:
MoveMoveqMNegb_OptimMsg:
MoveMoveqMNegw_OptimMsg:
	db	'This is one of a range of longword values that can be',Lf
	db	'handled more efficiently by first using a moveq instruction',Lf
	db	'and then using a second instruction to adjust the value',Lf
	db	'to that required.  CAUTION; the flags will probably not be',Lf
	cstr	'affected in the same manner as for the original code.'

MoveaLea_OptimMsg:
	db	'Use the LEA instruction for loading address registers.  This',Lf
	db	'instruction has not only been optimized by Motorola for this',Lf
	db	'use but the address modes allowed will give Macro68 a better',Lf
	db	'chance of further optimization.  No flags are affected by this',Lf
	cstr	'optimization.'

BtstBeqTstbBpl_OptimMsg:
BtstBneTstbBmi_OptimMsg:
BtstBeqTstwBpl_OptimMsg:
BtstBneTstwBmi_OptimMsg:
BtstBeqTstlBpl_OptimMsg:
BtstBneTstlBmi_OptimMsg:
	db	'For testing bit 7, 15 or 31 and then conditionally branching',Lf
	db	'it is better to use the appropiate TST instruction and then',Lf
	db	'branch on either condition PL or MI.  Be aware that this',Lf
	cstr	'optimization WILL CHANGE the state of the flags.'

BsrRtsBra_OptimMsg:
JsrRtsJmp_OptimMsg:
BsrRtsBraRts_OptimMsg:
JsrRtsJmpRts_OptimMsg:
	db	'A BSR or JSR instruction followed immediately by a RTS',Lf
	db	'instruction is equivilent to a BRA or JMP instruction.',Lf
	cstr	'No flags will be affected by this optimization.'

roxlAddx_OptimMsg:
XslAdd_OptimMsg:
	db	'Use an add instruction when shifting left 1 bit.  No flags',Lf
	cstr	'will be affected by this change.'

XslClr_OptimMsg:
	db	'Use a clr instruction when shifting a byte left 8 bits.  The',Lf
	cstr	'X, V and C flags may be affected as a result of this change.'

rolRor_OptimMsg:
rorRol_OptimMsg:
roxlRoxr_OptimMsg:
roxrRoxl_OptimMsg:
	db	'This can be optimized by altering the count value and reversing',Lf
	cstr	'the direction of rotation.  No flags will be affected'

srRemove_OptimMsg:
	cstr	'No purpose is served by this instruction.  It should be removed'

sfClr_OptimMsg:
	db	'It is generally more efficient (depending on addressing mode)'
	db	'to use the CLR instruction.  In any case you won''t lose anything'
	cstr	'by makeing this change.'

stMove_OptimMsg:
	db	'It is generally more efficient (depending on addressing mode)'
	db	'to use the MOVE instruction.  In any case you won''t lose anything'
	cstr	'by makeing this change.'

clrMoveq_OptimMsg:
	db	'Use MOVEQ to clear a data register.  No flags are affected by'
	cstr	'this change'

tstRemove_OptimMsg:
	db	'Since the last operation set the status flags this test is'
	cstr	'redundant and can be removed.'

JmpBra_OptimMsg:
JsrBsr_OptimMsg:
	db	'The BSR/BRA instructions are faster than the JSR/JMP instructions',Lf
	db	'on most CPU''s.  Also use of the BSR/BRA instructions gives Macro68',Lf
	db	'the oppertunity to further optimize this to short form.  No flags',Lf
	cstr	'are affected by this substitution.'

DivuLsr2_OptimMsg:
DivuLsr4_OptimMsg:
DivuLsr8_OptimMsg:
DivuLsr16_OptimMsg:
DivuLsr32_OptimMsg:
DivuLsr64_OptimMsg:
DivuLsr128_OptimMsg:
DivuLsr256_OptimMsg:
	db	'Use lsr instead of divu wherever possible.  No flags are affected',Lf
	cstr	'by this optimization.'

MuluAdd_OptimMsg:
MuluAddAdd_OptimMsg:
MuluLsl8_OptimMsg:
MuluLsl16_OptimMsg:
MuluLsl32_OptimMsg:
MuluLsl64_OptimMsg:
MuluLsl128_OptimMsg:
MuluLsl256_OptimMsg:
MuluLsl256Add_OptimMsg:
MuluLsl256AddAdd_OptimMsg:
	db	'Useing lsl or combinations of lsl and add in preference to mulu can',Lf
	db	'result in a significent speed increase.  No flags will be affected',Lf
	cstr	'by this optimization, however exercise caution with word->long factors.'



unrefLab_OptimMsg:
	db	'This label is not referenced anywhere within this code',Lf
	db	'nor is it defined as an external entry point.  The label',Lf
	db	'itself can be deleted or if it is the only entry point to',Lf
	cstr	'a sub-routine then the whole sub-routine may be deleted.',Lf

usePCRel_OptimMsg:
	cstr	'Use PC relative addressing wherever possible.'

absoluteShort_OptimMsg:
	cstr	'Use absolute short addressing wherever possible.'

byteBranch_OptimMsg:
	cstr	'Use byte size for this branch.'

wordBranch_OptimMsg:
	cstr	'Use word size for this branch.'





********************************************************************************
********************************************************************************
*                        OPTIMIZATION ACTION TEMPLATES                         *
********************************************************************************
********************************************************************************

	; --- These are your optimization action templates, they may be altered
	; -- in any way to suit your needs.

moveAnd_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	SaveLocPtr1
	StartOfLine1Back			;start at the beginning of the MOVE source line
	CopyToOpcodeField
	LoadLocPtr1
	SkipToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	CopyToEOL
	StartOfLine1Back			;start at the beginning of the MOVE source line
	SaveLocPtr2
	SkipToEOL				;skip the code line
	CopyToCurrentLine			;copy any comment lines
	LoadLocPtr2				;start at the beginning of the MOVE source line
	CopyWhitespace
	SaveLocPtr2
	LoadLocPtr1
	SkipToOpcodeField
	NewSource		<'and'>
	CopySizeExt
	LoadLocPtr2				;start at the beginning of the MOVE source line
	CopyWhitespace
	CopyToEOL
	Terminate

moveAndCaution_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	SaveLocPtr1
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	CopyToEOL
	StartOfLine1Back			;start at the beginning of the MOVE source line
	SaveLocPtr2
	SkipToEOL				;skip the code line
	CopyToCurrentLine			;copy any comment lines
	LoadLocPtr2				;start at the beginning of the MOVE source line
	CopyToOpcodeField
	SaveLocPtr2
	LoadLocPtr1
	SkipToOpcodeField
	NewSource		<'and'>
	CopySizeExt
	LoadLocPtr2				;start at the beginning of the MOVE source line
	CopyWhitespace
	CopyToEOL
	Terminate

AddAddq_OptimProc:
SubSubq_OptimProc:
	CopyToOpcodeField
	CopyNChars		3	;copy the add/sub
	NewSource		<'q'>
	CopySizeExt
	CopyToEOL
	Terminate

AddAddq2_OptimProc:
SubSubq2_OptimProc:
	CopyToOpcodeField
	CopyNChars		3	;copy the add/sub
	NewSource		<'q'>
	CopySizeExt
	CopyWhitespace
	Copy1OperandField
	NewSource		<'-8'>
	CopyNChars		1	;copy the ","
	Copy1OperandField
	NewSource		Lf
	StartOfLine
	CopyWhitespace
	CopyNChars		3	;copy the add/sub
	NewSource		<'q'>
	CopySizeExt
	CopyWhitespace
	CopyNChars		1	;copy the "#"
	NewSource		<'8'>
	Skip1OperandField
	CopyToEOL
	Terminate

AddaLea_OptimProc:
	CopyToOpcodeField
	NewSource		<'lea'>
	CopyWhitespace
	SkipNChars		1	;skip the "#"
	NewSource		<'('>
	Copy1OperandField
	SaveLocPtr1
	CopyNChars		1	;copy the ","
	Copy1OperandField
	NewSource		<')'>
	LoadLocPtr1
	CopyToEOL
	Terminate

SubaLea_OptimProc:
	CopyToOpcodeField
	NewSource		<'lea'>
	CopyWhitespace
	SkipNChars		1	;skip the "#"
	NewSource		<'(-'>
	Copy1OperandField
	SaveLocPtr1
	CopyNChars		1	;copy the ","
	Copy1OperandField
	NewSource		<')'>
	LoadLocPtr1
	CopyToEOL
	Terminate

MoveaSuba_OptimProc:
	CopyToOpcodeField
	NewSource		<'suba.l'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1	;skip the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		<','>
	LoadLocPtr1
	CopyToEOL
	Terminate

MoveMoveq_OptimProc:
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	CopyToEOL
	Terminate

MovewClrw_OptimProc:
MovebClrb_OptimProc:
	CopyToOpcodeField
	NewSource		<'clr'>
	CopySizeExt
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1	;skip the ","
	CopyToEOL
	Terminate

MoveMoveqClrb_OptimProc:
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	Copy1OperandField
	NewSource		<'!$ff'>
	CopyNChars		1
	SaveLocPtr1
	Copy1OperandField
	NewSource		Lf
	StartOfLine
	CopyWhitespace
	NewSource		<'clr.b'>
	CopyWhitespace
	LoadLocPtr1
	CopyToEOL
	Terminate

MoveMoveqClrw_OptimProc:
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	Copy1OperandField
	NewSource		<'!$ffff'>
	CopyNChars		1
	SaveLocPtr1
	Copy1OperandField
	NewSource		Lf
	StartOfLine
	CopyWhitespace
	NewSource		<'clr.w'>
	CopyWhitespace
	LoadLocPtr1
	CopyToEOL
	Terminate

MoveMoveqNegb_OptimProc:
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	CopyNChars		1		;copy the "#"
	NewSource		<'256-'>
	Copy1OperandField
	CopyNChars		1		;copy the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		Lf		;next line
	StartOfLine
	CopyWhitespace
	NewSource		<'neg.b'>
	CopyWhitespace
	LoadLocPtr1
	CopyToEOL
	Terminate

MoveMoveqNegw_OptimProc:
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	CopyNChars		1		;copy the "#"
	NewSource		<'65536-'>
	Copy1OperandField
	CopyNChars		1		;copy the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		Lf		;next line
	StartOfLine
	CopyWhitespace
	NewSource		<'neg.w'>
	CopyWhitespace
	LoadLocPtr1
	CopyToEOL
	Terminate

MoveMoveqMNegb_OptimProc:
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	CopyNChars		1		;copy the "#"
	NewSource		<'-('>
	Copy1OperandField
	NewSource		<'-4294967040)'>
	CopyNChars		1		;copy the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		Lf		;next line
	StartOfLine
	CopyWhitespace
	NewSource		<'neg.b'>
	CopyWhitespace
	LoadLocPtr1
	CopyToEOL
	Terminate

MoveMoveqMNegw_OptimProc:
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	CopyNChars		1		;copy the "#"
	NewSource		<'-('>
	Copy1OperandField
	NewSource		<'-4294901760)'>
	CopyNChars		1		;copy the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		Lf		;next line
	StartOfLine
	CopyWhitespace
	NewSource		<'neg.w'>
	CopyWhitespace
	LoadLocPtr1
	CopyToEOL
	Terminate

MoveaLea_OptimProc:
	CopyToOpcodeField
	NewSource		<'lea'>
	CopyWhitespace
	SkipNChars		1		;skip the "#"
	NewSource		<'('>
	Copy1OperandField
	NewSource		<')'>
	CopyToEOL
	Terminate

BtstBeqTstbBpl_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'tst.b'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	CopyToCurrentLine
	CopyToOpcodeField
	NewSource		<'bpl'>
	CopySizeExt
	CopyToEOL
	Terminate

BtstBneTstbBmi_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'tst.b'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	CopyToCurrentLine
	CopyToOpcodeField
	NewSource		<'bmi'>
	CopySizeExt
	CopyToEOL
	Terminate

BtstBeqTstwBpl_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'tst.w'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	CopyToCurrentLine
	CopyToOpcodeField
	NewSource		<'bpl'>
	CopySizeExt
	CopyToEOL
	Terminate

BtstBneTstwBmi_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'tst.w'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	CopyToCurrentLine
	CopyToOpcodeField
	NewSource		<'bmi'>
	CopySizeExt
	CopyToEOL
	Terminate

BtstBeqTstlBpl_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'tst.l'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	CopyToCurrentLine
	CopyToOpcodeField
	NewSource		<'bpl'>
	CopySizeExt
	CopyToEOL
	Terminate

BtstBneTstlBmi_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'tst.l'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	CopyToCurrentLine
	CopyToOpcodeField
	NewSource		<'bmi'>
	CopySizeExt
	CopyToEOL
	Terminate

JsrRtsJmp_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'jmp'>
	CopyWhitespace
	CopyToEOL
	Terminate

JsrRtsJmpRts_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'jmp'>
	CopyWhitespace
	CopyToCurrentLine
	CopyToEOL
	Terminate

BsrRtsBra_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'bra'>
	CopySizeExt
	CopyWhitespace
	CopyToEOL
	Terminate

BsrRtsBraRts_OptimProc:
	SetOrigin1LineBack			;set origin of original code
	StartOfLine1Back			;start at the beginning of the BTST source line
	CopyToOpcodeField
	NewSource		<'bra'>
	CopySizeExt
	CopyWhitespace
	CopyToCurrentLine
	CopyToEOL
	Terminate

XslAdd_OptimProc:
	CopyToOpcodeField
	NewSource		<'add'>
	CopySizeExt
	CopyWhitespace
	Skip1OperandField
	SaveLocPtr1
	SkipNChars		1		;skip the ","
	Copy1OperandField
	LoadLocPtr1
	CopyToEOL
	Terminate

XslClr_OptimProc:
	CopyToOpcodeField
	NewSource		<'clr.b'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	CopyToEOL
	Terminate

rolRor_OptimProc:
	CopyToOpcodeField
	NewSource		<'ror'>
	CopySizeExt
	CopyWhitespace
	CopyNChars		1		;copy the "#"
	NewSource		<'8-'>
	CopyToEOL
	Terminate

rorRol_OptimProc:
	CopyToOpcodeField
	NewSource		<'rol'>
	CopySizeExt
	CopyWhitespace
	CopyNChars		1		;copy the "#"
	NewSource		<'8-'>
	CopyToEOL
	Terminate

roxlRoxr_OptimProc:
	CopyToOpcodeField
	NewSource		<'roxr'>
	CopySizeExt
	CopyWhitespace
	CopyNChars		1		;copy the "#"
	NewSource		<'9-'>
	CopyToEOL
	Terminate

roxrRoxl_OptimProc:
	CopyToOpcodeField
	NewSource		<'roxl'>
	CopySizeExt
	CopyWhitespace
	CopyNChars		1		;copy the "#"
	NewSource		<'9-'>
	CopyToEOL
	Terminate

roxlAddx_OptimProc:
	CopyToOpcodeField
	NewSource		<'addx'>
	CopySizeExt
	CopyWhitespace
	Skip1OperandField
	SaveLocPtr1
	SkipNChars		1		;skip the ","
	Copy1OperandField
	LoadLocPtr1
	CopyToEOL
	Terminate

sfClr_OptimProc:
	CopyToOpcodeField
	NewSource		<'clr.b'>
	CopyWhitespace
	CopyToEOL
	Terminate

stMove_OptimProc:
	CopyToOpcodeField
	NewSource		<'move.b'>
	CopyWhitespace
	NewSource		<'#-1,'>
	CopyToEOL
	Terminate

clrMoveq_OptimProc:
	CopyToOpcodeField
	NewSource		<'moveq'>
	CopyWhitespace
	NewSource		<'#0,'>
	CopyToEOL
	Terminate

JsrBsr_OptimProc:
	CopyToOpcodeField
	NewSource		<'bsr'>
	CopyWhitespace
	SkipNChars		1		;skip the "("
	Copy1OperandField			;will copy up to the ",pc)" - because first "(" was skipped
	SkipNChars		4		;skip the ",pc)"
	CopyToEOL
	Terminate

JmpBra_OptimProc:
	CopyToOpcodeField
	NewSource		<'bra'>
	CopyWhitespace
	SkipNChars		1		;skip the "("
	Copy1OperandField			;will copy up to the ",pc)" - because first "(" was skipped
	SkipNChars		4		;skip the ",pc)"
	CopyToEOL
	Terminate

DivuLsr2_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsr.l'>
	CopyWhitespace
	NewSource		<'#1'>
	Skip1OperandField
	CopyToEOL
	Terminate

DivuLsr4_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsr.l'>
	CopyWhitespace
	NewSource		<'#2'>
	Skip1OperandField
	CopyToEOL
	Terminate

DivuLsr8_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsr.l'>
	CopyWhitespace
	NewSource		<'#3'>
	Skip1OperandField
	CopyToEOL
	Terminate

DivuLsr16_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsr.l'>
	CopyWhitespace
	NewSource		<'#4'>
	Skip1OperandField
	CopyToEOL
	Terminate

DivuLsr32_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsr.l'>
	CopyWhitespace
	NewSource		<'#5'>
	Skip1OperandField
	CopyToEOL
	Terminate

DivuLsr64_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsr.l'>
	CopyWhitespace
	NewSource		<'#6'>
	Skip1OperandField
	CopyToEOL
	Terminate

DivuLsr128_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsr.l'>
	CopyWhitespace
	NewSource		<'#7'>
	Skip1OperandField
	CopyToEOL
	Terminate

DivuLsr256_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsr.l'>
	CopyWhitespace
	NewSource		<'#8'>
	Skip1OperandField
	CopyToEOL
	Terminate

MuluAdd_OptimProc:
	CopyToOpcodeField
	NewSource		<'add.l'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		<','>
	LoadLocPtr1
	CopyToEOL
	Terminate

MuluAddAdd_OptimProc:
	CopyToOpcodeField
	NewSource		<'add.l'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		<','>
	LoadLocPtr1
	Copy1OperandField
	NewSource		Lf
	StartOfLine
	CopyWhitespace
	NewSource		<'add.l'>
	CopyWhitespace
	LoadLocPtr1
	Copy1OperandField
	NewSource		<','>
	LoadLocPtr1
	CopyToEOL
	Terminate

MuluLsl8_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsl.l'>
	CopyWhitespace
	NewSource		<'#3'>
	Skip1OperandField
	CopyToEOL
	Terminate

MuluLsl16_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsl.l'>
	CopyWhitespace
	NewSource		<'#4'>
	Skip1OperandField
	CopyToEOL
	Terminate

MuluLsl32_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsl.l'>
	CopyWhitespace
	NewSource		<'#5'>
	Skip1OperandField
	CopyToEOL
	Terminate

MuluLsl64_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsl.l'>
	CopyWhitespace
	NewSource		<'#6'>
	Skip1OperandField
	CopyToEOL
	Terminate

MuluLsl128_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsl.l'>
	CopyWhitespace
	NewSource		<'#7'>
	Skip1OperandField
	CopyToEOL
	Terminate

MuluLsl256_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsl.l'>
	CopyWhitespace
	NewSource		<'#8'>
	Skip1OperandField
	CopyToEOL
	Terminate

MuluLsl256Add_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsl.l'>
	CopyWhitespace
	NewSource		<'#8,'>
	Skip1OperandField
	SkipNChars		1		;skip the ","
	Copy1OperandField
	NewSource		Lf
	StartOfLine
	CopyWhitespace
	NewSource		<'add.l'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		<','>
	LoadLocPtr1
	CopyToEOL
	Terminate

MuluLsl256AddAdd_OptimProc:
	CopyToOpcodeField
	NewSource		<'lsl.l'>
	CopyWhitespace
	NewSource		<'#8,'>
	Skip1OperandField
	SkipNChars		1		;skip the ","
	Copy1OperandField
	NewSource		Lf
	StartOfLine
	CopyWhitespace
	NewSource		<'add.l'>
	CopyWhitespace
	Skip1OperandField
	SkipNChars		1		;skip the ","
	SaveLocPtr1
	Copy1OperandField
	NewSource		<','>
	LoadLocPtr1
	Copy1OperandField
	NewSource		Lf
	StartOfLine
	CopyWhitespace
	NewSource		<'add.l'>
	CopyWhitespace
	LoadLocPtr1
	Copy1OperandField
	NewSource		<','>
	LoadLocPtr1
	CopyToEOL
	Terminate


















unrefLab_OptimProc:
	CopyWhitespace
	CopyToEOL
	Terminate

srcPCRel_OptimProc:
	CopyToOperandField
	Copy1OperandField
	BackupNChars		1		;back inside bracket (assumes new syntax)
	NewSource		<',pc'>
	CopyToEOL
	Terminate

destPCRel_OptimProc:
	CopyToOperandField
	Copy1OperandField
	CopyNChars		1		;copy the ","
	Copy1OperandField
	BackupNChars		1		;back inside bracket (assumes new syntax)
	NewSource		<',pc'>
	CopyToEOL
	Terminate

absoluteShortSrc_OptimProc:
	CopyToOperandField
	Copy1OperandField
	NewSource		<'.w'>
	CopyToEOL
	Terminate

absoluteShortDest_OptimProc:
	CopyToOperandField
	Copy1OperandField
	CopyNChars		1		;copy the ","
	Copy1OperandField
	NewSource		<'.w'>
	CopyToEOL
	Terminate

byteBranch_OptimProc:
	CopyToOpcodeField
	CopyNChars		3		;copy the "bxx"
	NewSource		<'.b'>
	CopyWhitespace
	CopyToEOL
	Terminate

wordBranch_OptimProc:
	CopyToOpcodeField
	CopyNChars		3		;copy the "bxx"
	NewSource		<'.w'>
	CopyWhitespace
	CopyToEOL
	Terminate

********************************************************************************
********************************************************************************
*              SPECIAL CASE (NO CONDITIONALS) CONTROL STRUCTURES               *
********************************************************************************
********************************************************************************


unrefRegisterControlStruct:
	ControlAction	reportLine
	Output		xxxxExport
	Automation	informUser
	Message		unrefRegisterMessageStub_File
	Message		unrefRegisterMessageStub_Screen
	specialOEU_end

********************************************************************************
********************************************************************************
*                        OPTIMIZATION MESSAGE TEMPLATES                        *
********************************************************************************
********************************************************************************

	; --- These are your optimization message templates, they may be altered
	; -- in any way to suit your needs.
	; -- Case sensitive reserved characters are:-
	; -- "\"	command introducer
	; -- "\\"	put "\" char in error message
	; -- "c"	insert optimization number	(lower case only!)
	; -- "f"	insert the filename		(lower case only!)
	; -- "l"	insert the line number		(lower case only!)
	; -- "m"	insert optimization message	(lower case only!)
	; -- "n"	insert base register number	(lower case only!)
	; -- "o"	insert original code line	(lower case only!)
	; -- "p"	insert pass number		(lower case only!)
	; -- "r"	insert register name		(lower case only!)
	; -- "s"	insert suggested code line	(lower case only!)
	; -- "t"	insert id number		(lower case only!)

replaceMessageStub_File:
	db	Lf,'OPT *** \f *** Line \l *** AutoCode \t',Lf
	db	'¤¤¤\o¤¤',Lf
	cstr	'¶¶¶\s¶¶',Lf

replaceMessageStub_Screen:
	db	Lf,'OPTIM *** \f *** Line \l',Lf
	db	'\m',Lf
	db	'Original code  =',Lf,'\o',Lf
	cstr	'Suggested code =',Lf,'\s',Lf


removeMessageStub_File:
	db	Lf,'OPT * REMOVE *** \f *** Line \l *** AutoCode \t',Lf
	cstr	'¤¤¤\o¤¤',Lf

removeMessageStub_Screen:
	db	Lf,'OPTIM * REMOVE *** \f *** Line \l *** \c',Lf
	db	'I suggest that this code is superfluous and should be removed.',Lf
	cstr	'Original code  =',Lf,'\o',Lf


unrefMessageStub_File:
	db	Lf,'OPT * UNREF *** \f *** Line \l *** AutoCode \t',Lf
	cstr	'¤¤¤\o¤¤',Lf
unrefMessageStub_Screen:
	db	Lf,'OPTIM * UNREFERENCED LABEL *** \f *** Line \l *** \c',Lf
	db	'This label is not referenced anywhere within this code',Lf
	db	'nor is it defined as an external entry point.  The label',Lf
	db	'itself can be deleted or if it is the only entry point to',Lf
	db	'a sub-routine then the whole sub-routine may be deleted.',Lf
	cstr	'Original line  =',Lf,'\o',Lf


unrefRegisterMessageStub_File:
	db	Lf,'INFO * UNREF REG *** \f',Lf
	cstr	'¤¤¤\r¤¤',Lf
unrefRegisterMessageStub_Screen:
	db	Lf,'INFO * UNREFERENCED REGISTER *** \f *** \c',Lf
	db	'This register is not referenced anywhere within this code.',Lf
	db	'You may be able to use this register for optimization purposes.',Lf
	cstr	'Register name  = \r',Lf


baseRegMessageStub_File:
	db	Lf,'OPT * BASE REG *** \f *** Line \l *** Base register A\n',Lf
	cstr	'¤¤¤\o¤¤',Lf
baseRegMessageStub_Screen:
	db	Lf,'OPTIM * BASE REG *** \f *** Line \l  *** \c *** Base register A\n',Lf
	db	'Base register offset addressing is possible here',Lf
	cstr	'Original line  =',Lf,'\o',Lf


nullDispMessageStub_File:
	db	Lf,'OPT * NULL DISP *** \f *** Line \l',Lf
	cstr	'¤¤¤\o¤¤',Lf
nullDispMessageStub_Screen:
	db	Lf,'OPTIM * NULL DISP *** \f *** Line \l *** \c',Lf
	db	'Null displacement value is unnecesserary',Lf
	cstr	'Original line  =',Lf,'\o',Lf


nullBranchMessageStub_File:
	db	Lf,'OPT * NULL BRANCH *** \f *** Line \l',Lf
	cstr	'¤¤¤\o¤¤',Lf
nullBranchMessageStub_Screen:
	db	Lf,'OPTIM * NULL BRANCH *** \f *** Line \l *** \c',Lf
	db	'Null displacement branch is unnecesserary, removal suggested',Lf
	cstr	'Original line  =',Lf,'\o',Lf

*******************************************************************************

	END
