Add a new piece of metadata to the UDFs to specify if whether a UDF is a runtime constant. Runtime constants also exist in SQL Server, and this is similar to Postgres' concept of STABLE functions. This metadata may be useful for materialized views and query caching.
Some Hive functions such as the ones listed below are currently labelled as deterministic, but really are runtime constants:
The values for these functions are not deterministic between different queries - for example current_timestamp will most likely be different every query executed. This makes these functions ineligible for things like materialized views or cached query results.
However the value for the current_timestamp should not change during the life of a single query, which allows these values to be used in optimizations such as constant folding.