Dir and signal functions.