SEGV when exercising code at bottom of processing table
Barry Wiseman
barrywiseman at verizon.net
Fri Feb 5 10:33:54 PST 2010
fP 5.0.15 on linux
We have an input processing table which is currently 5886 lines of code. (The associated automatic table is 6845 lines.) Several chunks of code near the end of the table are throwing SEGV's when called at runtime. Moving these code blocks higher in the table constitutes a workaround.
The simplest example is:
@key4:::
:@sn eq "4":switchto "4t" ; end:
::switchto 4 ; end:
With this code block located at line 5861, pressing "4" from a record generates a segmentation fault. When I move this three-line block above the short subroutine which precedes it in the table -- so that it is now located at line 5852 -- the @key4 executes without a problem.
Another example, a short subroutine
ttype:::
:18 eq "" or 18 eq "SPOT":return:
::lookup typ = gottype k=18 i=A -nx:
:not typ:return:
:typ(21) eq "Y":ltagtype = "LTL":
::return:
which works fine when located above line 5856, SEGV's when lower in the table, or, when at the very bottom, generates:
FATAL ERROR!
Invalid opcode 254 in token table.
Line 5881, offset 1.
Any ideas what the issue could be here? We have other similar versions of this table which are larger (more lines) but do not produce these errors.
More information about the Filepro-list
mailing list