move irefs to ast.intrinsic