Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] View of /sml/trunk/src/MLRISC/alpha/instructions/alphaInstr.sml
ViewVC logotype

View of /sml/trunk/src/MLRISC/alpha/instructions/alphaInstr.sml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 624 - (download) (annotate)
Fri Apr 21 03:06:21 2000 UTC (19 years, 5 months ago) by leunga
File size: 9032 byte(s)

   This update synchronizes my repository with Yale's.  Most of these
changes are related to C--, Moby, and my optimizations.  It should have
little impact on SML/NJ.

   CVS tag leunga-20000420-ssa-c---stuff
(*
 * This file was automatically generated by MDGen (v2.0)
 * from the machine description file "alpha/alpha.md".
 *)


signature ALPHAINSTR =
sig
   structure C : ALPHACELLS
   structure Constant: CONSTANT
   structure LabelExp: LABELEXP
   structure Region : REGION
      sharing Constant = LabelExp.Constant
   datatype ea =
     Direct of int
   | FDirect of int
   | Displace of {base:int, disp:int}
   datatype operand =
     REGop of int
   | IMMop of int
   | HILABop of LabelExp.labexp
   | LOLABop of LabelExp.labexp
   | LABop of LabelExp.labexp
   datatype branch =
     BR
   | BLBC
   | BEQ
   | BLT
   | BLE
   | BLBS
   | BNE
   | BGE
   | BGT
   datatype fbranch =
     FBEQ
   | FBLT
   | FBLE
   | FBNE
   | FBGE
   | FBGT
   datatype load =
     LDB
   | LDW
   | LDBU
   | LDWU
   | LDL
   | LDL_L
   | LDQ
   | LDQ_L
   | LDQ_U
   datatype store =
     STB
   | STW
   | STL
   | STQ
   | STQ_U
   datatype fload =
     LDF
   | LDG
   | LDS
   | LDT
   datatype fstore =
     STF
   | STG
   | STS
   | STT
   datatype operate =
     ADDL
   | ADDQ
   | CMPBGE
   | CMPEQ
   | CMPLE
   | CMPLT
   | CMPULE
   | CMPULT
   | SUBL
   | SUBQ
   | S4ADDL
   | S4ADDQ
   | S4SUBL
   | S4SUBQ
   | S8ADDL
   | S8ADDQ
   | S8SUBL
   | S8SUBQ
   | AND
   | BIC
   | BIS
   | EQV
   | ORNOT
   | XOR
   | EXTBL
   | EXTLH
   | EXTLL
   | EXTQH
   | EXTQL
   | EXTWH
   | EXTWL
   | INSBL
   | INSLH
   | INSLL
   | INSQH
   | INSQL
   | INSWH
   | INSWL
   | MSKBL
   | MSKLH
   | MSKLL
   | MSKQH
   | MSKQL
   | MSKWH
   | MSKWL
   | SLL
   | SRA
   | SRL
   | ZAP
   | ZAPNOT
   | MULL
   | MULQ
   | UMULH
   | SGNXL
   datatype cmove =
     CMOVEQ
   | CMOVLBC
   | CMOVLBS
   | CMOVGE
   | CMOVGT
   | CMOVLE
   | CMOVLT
   | CMOVNE
   datatype pseudo_op =
     DIVL
   | DIVLU
   | DIVQ
   | DIVQU
   | REML
   | REMLU
   | REMQ
   | REMQU
   datatype operateV =
     ADDLV
   | ADDQV
   | SUBLV
   | SUBQV
   | MULLV
   | MULQV
   datatype funary =
     CVTLQ
   | CVTQL
   | CVTQLSV
   | CVTQLV
   | CVTQS
   | CVTQSC
   | CVTQT
   | CVTQTC
   | CVTTS
   | CVTTSC
   | CVTST
   | CVTSTS
   | CVTTQ
   | CVTTQC
   datatype foperate =
     CPYS
   | CPYSE
   | CPYSN
   | MF_FPCR
   | MT_FPCR
   | CMPTEQ
   | CMPTLT
   | CMPTLE
   | CMPTUN
   | CMPTEQSU
   | CMPTLTSU
   | CMPTLESU
   | CMPTUNSU
   | ADDS
   | ADDT
   | DIVS
   | DIVT
   | MULS
   | MULT
   | SUBS
   | SUBT
   datatype fcmove =
     FCMOVEQ
   | FCMOVGE
   | FCMOVGT
   | FCMOVLE
   | FCMOVLT
   | FCMOVNE
   datatype foperateV =
     ADDSSUD
   | ADDSSU
   | ADDTSUD
   | ADDTSU
   | DIVSSUD
   | DIVSSU
   | DIVTSUD
   | DIVTSU
   | MULSSUD
   | MULSSU
   | MULTSUD
   | MULTSU
   | SUBSSUD
   | SUBSSU
   | SUBTSUD
   | SUBTSU
   datatype osf_user_palcode =
     BPT
   | BUGCHK
   | CALLSYS
   | GENTRAP
   | IMB
   | RDUNIQUE
   | WRUNIQUE
   type addressing_mode = (C.cell * operand)
   datatype instruction =
     DEFFREG of int
   | LDA of {r:int, b:int, d:operand}
   | LDAH of {r:int, b:int, d:operand}
   | LOAD of {ldOp:load, r:int, b:int, d:operand, mem:Region.region}
   | STORE of {stOp:store, r:int, b:int, d:operand, mem:Region.region}
   | FLOAD of {ldOp:fload, r:int, b:int, d:operand, mem:Region.region}
   | FSTORE of {stOp:fstore, r:int, b:int, d:operand, mem:Region.region
     }
   | JMPL of ({r:int, b:int, d:int} * Label.label list)
   | JSR of {r:int, b:int, d:int, defs:C.cellset, uses:C.cellset, mem:Region.region
     }
   | BSR of {r:int, lab:Label.label, defs:C.cellset, uses:C.cellset, mem:Region.region
     }
   | RET of {r:int, b:int, d:int}
   | BRANCH of {b:branch, r:int, lab:Label.label}
   | FBRANCH of {b:fbranch, f:int, lab:Label.label}
   | OPERATE of {oper:operate, ra:int, rb:operand, rc:int}
   | OPERATEV of {oper:operateV, ra:int, rb:operand, rc:int}
   | CMOVE of {oper:cmove, ra:int, rb:operand, rc:int}
   | PSEUDOARITH of {oper:pseudo_op, ra:int, rb:operand, rc:int, tmps:C.cellset
     }
   | COPY of {dst:int list, src:int list, impl:instruction list option ref
     , tmp:ea option}
   | FCOPY of {dst:int list, src:int list, impl:instruction list option ref
     , tmp:ea option}
   | FUNARY of {oper:funary, fb:int, fc:int}
   | FOPERATE of {oper:foperate, fa:int, fb:int, fc:int}
   | FOPERATEV of {oper:foperateV, fa:int, fb:int, fc:int}
   | FCMOVE of {oper:fcmove, fa:int, fb:int, fc:int}
   | TRAPB
   | CALL_PAL of {code:osf_user_palcode, def:int list, use:int list}
   | ANNOTATION of {i:instruction, a:Annotations.annotation}
   | SOURCE of {}
   | SINK of {}
   | PHI of {}
end

functor AlphaInstr(structure LabelExp : LABELEXP
                   structure Region   : REGION
                  ) : ALPHAINSTR =
struct
   structure C = AlphaCells
   structure Region = Region
   structure LabelExp = LabelExp
   structure Constant = LabelExp.Constant
   datatype ea =
     Direct of int
   | FDirect of int
   | Displace of {base:int, disp:int}
   datatype operand =
     REGop of int
   | IMMop of int
   | HILABop of LabelExp.labexp
   | LOLABop of LabelExp.labexp
   | LABop of LabelExp.labexp
   datatype branch =
     BR
   | BLBC
   | BEQ
   | BLT
   | BLE
   | BLBS
   | BNE
   | BGE
   | BGT
   datatype fbranch =
     FBEQ
   | FBLT
   | FBLE
   | FBNE
   | FBGE
   | FBGT
   datatype load =
     LDB
   | LDW
   | LDBU
   | LDWU
   | LDL
   | LDL_L
   | LDQ
   | LDQ_L
   | LDQ_U
   datatype store =
     STB
   | STW
   | STL
   | STQ
   | STQ_U
   datatype fload =
     LDF
   | LDG
   | LDS
   | LDT
   datatype fstore =
     STF
   | STG
   | STS
   | STT
   datatype operate =
     ADDL
   | ADDQ
   | CMPBGE
   | CMPEQ
   | CMPLE
   | CMPLT
   | CMPULE
   | CMPULT
   | SUBL
   | SUBQ
   | S4ADDL
   | S4ADDQ
   | S4SUBL
   | S4SUBQ
   | S8ADDL
   | S8ADDQ
   | S8SUBL
   | S8SUBQ
   | AND
   | BIC
   | BIS
   | EQV
   | ORNOT
   | XOR
   | EXTBL
   | EXTLH
   | EXTLL
   | EXTQH
   | EXTQL
   | EXTWH
   | EXTWL
   | INSBL
   | INSLH
   | INSLL
   | INSQH
   | INSQL
   | INSWH
   | INSWL
   | MSKBL
   | MSKLH
   | MSKLL
   | MSKQH
   | MSKQL
   | MSKWH
   | MSKWL
   | SLL
   | SRA
   | SRL
   | ZAP
   | ZAPNOT
   | MULL
   | MULQ
   | UMULH
   | SGNXL
   datatype cmove =
     CMOVEQ
   | CMOVLBC
   | CMOVLBS
   | CMOVGE
   | CMOVGT
   | CMOVLE
   | CMOVLT
   | CMOVNE
   datatype pseudo_op =
     DIVL
   | DIVLU
   | DIVQ
   | DIVQU
   | REML
   | REMLU
   | REMQ
   | REMQU
   datatype operateV =
     ADDLV
   | ADDQV
   | SUBLV
   | SUBQV
   | MULLV
   | MULQV
   datatype funary =
     CVTLQ
   | CVTQL
   | CVTQLSV
   | CVTQLV
   | CVTQS
   | CVTQSC
   | CVTQT
   | CVTQTC
   | CVTTS
   | CVTTSC
   | CVTST
   | CVTSTS
   | CVTTQ
   | CVTTQC
   datatype foperate =
     CPYS
   | CPYSE
   | CPYSN
   | MF_FPCR
   | MT_FPCR
   | CMPTEQ
   | CMPTLT
   | CMPTLE
   | CMPTUN
   | CMPTEQSU
   | CMPTLTSU
   | CMPTLESU
   | CMPTUNSU
   | ADDS
   | ADDT
   | DIVS
   | DIVT
   | MULS
   | MULT
   | SUBS
   | SUBT
   datatype fcmove =
     FCMOVEQ
   | FCMOVGE
   | FCMOVGT
   | FCMOVLE
   | FCMOVLT
   | FCMOVNE
   datatype foperateV =
     ADDSSUD
   | ADDSSU
   | ADDTSUD
   | ADDTSU
   | DIVSSUD
   | DIVSSU
   | DIVTSUD
   | DIVTSU
   | MULSSUD
   | MULSSU
   | MULTSUD
   | MULTSU
   | SUBSSUD
   | SUBSSU
   | SUBTSUD
   | SUBTSU
   datatype osf_user_palcode =
     BPT
   | BUGCHK
   | CALLSYS
   | GENTRAP
   | IMB
   | RDUNIQUE
   | WRUNIQUE
   type addressing_mode = (C.cell * operand)
   datatype instruction =
     DEFFREG of int
   | LDA of {r:int, b:int, d:operand}
   | LDAH of {r:int, b:int, d:operand}
   | LOAD of {ldOp:load, r:int, b:int, d:operand, mem:Region.region}
   | STORE of {stOp:store, r:int, b:int, d:operand, mem:Region.region}
   | FLOAD of {ldOp:fload, r:int, b:int, d:operand, mem:Region.region}
   | FSTORE of {stOp:fstore, r:int, b:int, d:operand, mem:Region.region
     }
   | JMPL of ({r:int, b:int, d:int} * Label.label list)
   | JSR of {r:int, b:int, d:int, defs:C.cellset, uses:C.cellset, mem:Region.region
     }
   | BSR of {r:int, lab:Label.label, defs:C.cellset, uses:C.cellset, mem:Region.region
     }
   | RET of {r:int, b:int, d:int}
   | BRANCH of {b:branch, r:int, lab:Label.label}
   | FBRANCH of {b:fbranch, f:int, lab:Label.label}
   | OPERATE of {oper:operate, ra:int, rb:operand, rc:int}
   | OPERATEV of {oper:operateV, ra:int, rb:operand, rc:int}
   | CMOVE of {oper:cmove, ra:int, rb:operand, rc:int}
   | PSEUDOARITH of {oper:pseudo_op, ra:int, rb:operand, rc:int, tmps:C.cellset
     }
   | COPY of {dst:int list, src:int list, impl:instruction list option ref
     , tmp:ea option}
   | FCOPY of {dst:int list, src:int list, impl:instruction list option ref
     , tmp:ea option}
   | FUNARY of {oper:funary, fb:int, fc:int}
   | FOPERATE of {oper:foperate, fa:int, fb:int, fc:int}
   | FOPERATEV of {oper:foperateV, fa:int, fb:int, fc:int}
   | FCMOVE of {oper:fcmove, fa:int, fb:int, fc:int}
   | TRAPB
   | CALL_PAL of {code:osf_user_palcode, def:int list, use:int list}
   | ANNOTATION of {i:instruction, a:Annotations.annotation}
   | SOURCE of {}
   | SINK of {}
   | PHI of {}
end


root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0