tool_path = lit_config.params.get(tool_name)
if tool_path is None:
tool_path = lit.util.which(tool_name, llvm_tools_dir)
tool_path = lit_config.params.get(tool_name)
if tool_path is None:
tool_path = lit.util.which(tool_name, llvm_tools_dir)
if (tool_name == "llc" and
'LLVM_ENABLE_MACHINE_VERIFIER' in os.environ and
os.environ['LLVM_ENABLE_MACHINE_VERIFIER'] == "1"):
tool_path += " -verify-machineinstrs"
if (tool_name == "llc" and
'LLVM_ENABLE_MACHINE_VERIFIER' in os.environ and
os.environ['LLVM_ENABLE_MACHINE_VERIFIER'] == "1"):
tool_path += " -verify-machineinstrs"
if (config.llvm_use_sanitizer == "Memory" or
config.llvm_use_sanitizer == "MemoryWithOrigins"):
config.available_features.add("msan")
if (config.llvm_use_sanitizer == "Memory" or
config.llvm_use_sanitizer == "MemoryWithOrigins"):
config.available_features.add("msan")
if not re.match(r'^x86_64.*-(mingw32|windows-gnu|win32)', config.target_triple):
config.available_features.add('debug_frame')
if not re.match(r'^x86_64.*-(mingw32|windows-gnu|win32)', config.target_triple):
config.available_features.add('debug_frame')
# Check if we should use gmalloc.
use_gmalloc_str = lit_config.params.get('use_gmalloc', None)
if use_gmalloc_str is not None:
# Check if we should use gmalloc.
use_gmalloc_str = lit_config.params.get('use_gmalloc', None)
if use_gmalloc_str is not None: