mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-30 09:54:49 +00:00
some progress on #7261; VM does not support the new backwards indexing
This commit is contained in:
@@ -779,9 +779,21 @@ proc rawExecute(c: PCtx, start: int, tos: PStackFrame): TFullReg =
|
||||
regs[ra].intVal = ord(regs[rb].intVal <% regs[rc].intVal)
|
||||
of opcEqRef:
|
||||
decodeBC(rkInt)
|
||||
regs[ra].intVal = ord((regs[rb].node.kind == nkNilLit and
|
||||
regs[rc].node.kind == nkNilLit) or
|
||||
regs[rb].node == regs[rc].node)
|
||||
if regs[rb].kind == rkNodeAddr:
|
||||
if regs[rc].kind == rkNodeAddr:
|
||||
regs[ra].intVal = ord(regs[rb].nodeAddr == regs[rc].nodeAddr)
|
||||
else:
|
||||
assert regs[rc].kind == rkNode
|
||||
# we know these cannot be equal
|
||||
regs[ra].intVal = ord(false)
|
||||
elif regs[rc].kind == rkNodeAddr:
|
||||
assert regs[rb].kind == rkNode
|
||||
# we know these cannot be equal
|
||||
regs[ra].intVal = ord(false)
|
||||
else:
|
||||
regs[ra].intVal = ord((regs[rb].node.kind == nkNilLit and
|
||||
regs[rc].node.kind == nkNilLit) or
|
||||
regs[rb].node == regs[rc].node)
|
||||
of opcEqNimrodNode:
|
||||
decodeBC(rkInt)
|
||||
regs[ra].intVal =
|
||||
|
||||
@@ -1288,7 +1288,7 @@ proc whichAsgnOpc(n: PNode): TOpcode =
|
||||
opcAsgnStr
|
||||
of tyFloat..tyFloat128:
|
||||
opcAsgnFloat
|
||||
of tyRef, tyNil, tyVar, tyLent:
|
||||
of tyRef, tyNil, tyVar, tyLent, tyPtr:
|
||||
opcAsgnRef
|
||||
else:
|
||||
opcAsgnComplex
|
||||
|
||||
Reference in New Issue
Block a user