/myDict<<
/myProc {
(Hello world) =
}
>>def
myDict begin %A
myProc %A
end %A
myDict /myProc get exec %B
Given the above Postscript code, which (not surprisingly) produces the following output using ghostscript (GPL Ghostscript 9.55.0 (2021-09-27) on Linux):
Hello world
Hello world
The %A lines pushes the whole dictionary and any state it might have onto the dict stack; I don’t think this is true for the line marked %B, as I believe it just does a lookup and runs the procedure it finds, without loading the dictionary onto the dict stack .
I am interested for times where the dict is very large and loading it (perhaps many times) would have significant overhead.
Context: Running in ghostscript.
Question: Does the last line (myDict /myProc get exec %B
) have less overhead than the lines which are marked with %A?