persistent thread macros