On 19.06.2019 19:49, Paul Reeves wrote:

I have never compared load and call times for UDFs and SPs, but I have
always assumed that a UDF will load and execute more quickly than a SP.


Calling UDF is hard process. We must emulate C call stack therefore parameters are multiple times copied here and there, making CSTRING from CHAR / VARCHAR is also headache - there is no place for terminating zero in the end of that string, therefore memory allocation takes place. Almost all of that migth be avoided calling BY DESCRIPTOR but looks like there are not too much UDF doing this.




Firebird-Devel mailing list, web interface at 
https://lists.sourceforge.net/lists/listinfo/firebird-devel

Reply via email to