Module AnalyzeResiduation

A tool to analyze the residuation behavior of a module. It can just show the results, making some statistics, or writes the results into a file which can be used by PAKCS to optimize the implementation of non-residuating operations.

Author: Michael Hanus

Version: December 2020

Summary of exported operations:

:: String  Deterministic 
main :: IO ()  Non-deterministic 
residuationInfoOf :: String -> IO [((String,String),ResiduationInfo)]  Non-deterministic 
Returns the residuation information of all operations defined in a module.
genResInfo :: Options -> String -> IO ()  Non-deterministic 
writeResInfoFile :: Options -> [((String,String),ResiduationInfo)] -> IO ()  Deterministic 
Writes a file containing residuation information in Curry term format.
allResOps :: [((String,String),ResiduationInfo)] -> [String]  Deterministic 
Returns the list of possibly residuating operations.
countResOps :: String -> IO [String]  Non-deterministic 
Counts all possibly residuating and non-residuating operations.
countResOps2CSV :: [String] -> IO ()  Non-deterministic 

Exported operations:

main :: IO ()  Non-deterministic 

residuationInfoOf :: String -> IO [((String,String),ResiduationInfo)]  Non-deterministic 

Returns the residuation information of all operations defined in a module.

genResInfo :: Options -> String -> IO ()  Non-deterministic 

writeResInfoFile :: Options -> [((String,String),ResiduationInfo)] -> IO ()  Deterministic 

Writes a file containing residuation information in Curry term format. The term is a list of pairs consisting of the qualified function name together with the list of argument positions which must be ground values to ensure that the function call does not residuate and yields a ground value. If the function might always residuate, the argument position list is [0].

allResOps :: [((String,String),ResiduationInfo)] -> [String]  Deterministic 

Returns the list of possibly residuating operations.

countResOps :: String -> IO [String]  Non-deterministic 

Counts all possibly residuating and non-residuating operations.

countResOps2CSV :: [String] -> IO ()  Non-deterministic