summary refs log tree commit diff stats
path: root/compiler/vmdef.nim
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2015-04-25 20:23:09 +0200
committerAraq <rumpf_a@web.de>2015-04-25 23:17:00 +0200
commitd3fc6e1f285950d9cddb338206d553ff7baee7d5 (patch)
tree5fcbd5ff92b50e341ecfa722d2229b3327c549b2 /compiler/vmdef.nim
parent6725aa363426db74d44df29d74fca0ca6e227bbe (diff)
downloadNim-d3fc6e1f285950d9cddb338206d553ff7baee7d5.tar.gz
marshalling can be done at compile-time
Diffstat (limited to 'compiler/vmdef.nim')
-rw-r--r--compiler/vmdef.nim9
1 files changed, 6 insertions, 3 deletions
diff --git a/compiler/vmdef.nim b/compiler/vmdef.nim
index b4892d010..047009f01 100644
--- a/compiler/vmdef.nim
+++ b/compiler/vmdef.nim
@@ -66,7 +66,8 @@ type
     opcMulSet, opcPlusSet, opcMinusSet, opcSymdiffSet, opcConcatStr,
     opcContainsSet, opcRepr, opcSetLenStr, opcSetLenSeq,
     opcSwap, opcIsNil, opcOf, opcIs,
-    opcSubStr, opcParseFloat, opcConv, opcCast, opcQuit, opcReset,
+    opcSubStr, opcParseFloat, opcConv, opcCast,
+    opcQuit, opcReset,
     opcNarrowS, opcNarrowU,
 
     opcAddStrCh,
@@ -132,7 +133,8 @@ type
     opcLdImmInt,  # dest = immediate value
     opcNBindSym,
     opcSetType,   # dest.typ = types[Bx]
-    opcTypeTrait
+    opcTypeTrait,
+    opcMarshalLoad, opcMarshalStore
 
   TBlock* = object
     label*: PSym
@@ -221,7 +223,8 @@ proc registerCallback*(c: PCtx; name: string; callback: VmCallback) =
 const
   firstABxInstr* = opcTJmp
   largeInstrs* = { # instructions which use 2 int32s instead of 1:
-    opcSubStr, opcConv, opcCast, opcNewSeq, opcOf}
+    opcSubStr, opcConv, opcCast, opcNewSeq, opcOf,
+    opcMarshalLoad, opcMarshalStore}
   slotSomeTemp* = slotTempUnknown
   relativeJumps* = {opcTJmp, opcFJmp, opcJmp, opcJmpBack}