def sanitizers_from_args(args):
    """Returns the sanitizers enabled by a given set of ldflags."""
    sanitizers = set()
    for arg in args:
        if arg.startswith('-fsanitize='):
            sanitizer_list = arg.partition('=')[2]
            sanitizers |= set(sanitizer_list.split(','))
        elif arg.startswith('-fno-sanitize='):
            sanitizer_list = arg.partition('=')[2]
            sanitizers -= set(sanitizer_list.split(','))
    return sorted(list(sanitizers))