Skip to content

Conversation

@lanza
Copy link
Member

@lanza lanza commented Nov 15, 2025

No description provided.

@lanza lanza requested review from MaskRay and Copilot November 15, 2025 05:09
@llvmbot llvmbot added the lld label Nov 15, 2025
@lanza lanza requested a review from smeenai November 15, 2025 05:09
@llvmbot
Copy link
Member

llvmbot commented Nov 15, 2025

@llvm/pr-subscribers-lld

@llvm/pr-subscribers-lld-elf

Author: Nathan Lanza (lanza)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/168174.diff

1 Files Affected:

  • (modified) lld/ELF/DriverUtils.cpp (+1)
diff --git a/lld/ELF/DriverUtils.cpp b/lld/ELF/DriverUtils.cpp
index 6d027c529c19e..ac8bf4c003314 100644
--- a/lld/ELF/DriverUtils.cpp
+++ b/lld/ELF/DriverUtils.cpp
@@ -177,6 +177,7 @@ std::string elf::createResponseFile(const opt::InputArgList &args) {
     case OPT_o:
     case OPT_Map:
     case OPT_dependency_file:
+    case OPT_plugin_opt_stats_file:
     case OPT_print_archive_stats:
     case OPT_why_extract:
       // If an output path contains directories, "lld @response.txt" will

Copilot finished reviewing on behalf of lanza November 15, 2025 05:12
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for properly handling the --plugin-opt=stats-file option in LLD's --reproduce functionality. The --reproduce feature creates a tarball containing all inputs needed to reproduce a link, along with a response file to re-run the command. For output file options, the reproduce feature strips directory paths since the archive doesn't contain empty directories.

  • Added OPT_plugin_opt_stats_file to the list of output file options that have their directory paths stripped in the reproduce response file

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@MaskRay
Copy link
Member

MaskRay commented Nov 15, 2025

Can you update the test lld/test/ELF/reproduce-lto.s?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants