diff options
author | Camil Staps | 2023-01-28 12:48:43 +0100 |
---|---|---|
committer | Camil Staps | 2023-01-28 12:48:43 +0100 |
commit | f84fca3b169d808943b5f329c177870dc87c1d51 (patch) | |
tree | c6af7707ecd8fc52c4ed4804ece707fce941b0be /snug-clean/src/Snug/Compile/ABI.dcl | |
parent | Add compilation of constructors and basic values (diff) |
Add stack simulator for compilation
Diffstat (limited to 'snug-clean/src/Snug/Compile/ABI.dcl')
-rw-r--r-- | snug-clean/src/Snug/Compile/ABI.dcl | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/snug-clean/src/Snug/Compile/ABI.dcl b/snug-clean/src/Snug/Compile/ABI.dcl new file mode 100644 index 0000000..938a65e --- /dev/null +++ b/snug-clean/src/Snug/Compile/ABI.dcl @@ -0,0 +1,21 @@ +definition module Snug.Compile.ABI + +from MIPS.MIPS32 import :: Label, :: Register(GP,S,T) +from Snug.Compile import :: Namespace +from Snug.Syntax import :: ConstructorIdent, :: SymbolIdent + +:: EntryPoint + = NodeEntry + +BackPrintPtr :== S 0 +FrontPrintPtr :== S 1 + +BackEvalPtr :== S 2 +FrontEvalPtr :== S 3 + +HeapPtr :== GP + +TempImm :== T 0 + +constructorLabel :: !Namespace !ConstructorIdent -> Label +functionLabel :: !Namespace !EntryPoint !SymbolIdent -> Label |