]> git.ipfire.org Git - thirdparty/bird.git/commit
Filter: Improve handling of stack frames in filter bytecode
authorOndrej Zajicek (work) <santiago@crfreenet.org>
Wed, 9 Mar 2022 01:32:29 +0000 (02:32 +0100)
committerOndrej Zajicek <santiago@crfreenet.org>
Mon, 27 Jun 2022 19:13:32 +0000 (21:13 +0200)
commita2527ee53d9d8fe7a1c29b56f8450b9ef1f9c7bc
treea4dbac6cea35ef3c675c9a12b37dc67719b1b5ac
parentf31f4e6eef1762a4b9bf54a274f1ba9e9e161802
Filter: Improve handling of stack frames in filter bytecode

When f_line is done, we have to pop the stack frame. The old code just
removed nominal number of args/vars. Change it to use stored ventry value
modified by number of returned values. This allows to allocate variables
on a stack frame during execution of f_lines instead of just at start.

But we need to know the number of returned values for a f_line. It is 1
for term, 0 for cmd. Store that to f_line during linearization.
conf/confbase.Y
filter/config.Y
filter/decl.m4
filter/f-inst.c
filter/f-inst.h
filter/f-util.c
filter/filter.c
nest/config.Y
proto/static/config.Y