-
Notifications
You must be signed in to change notification settings - Fork 13.4k
[llvm-lit] Expand and Rewrite Tests for FileNotFoundError for compiler-rt tests in lit internal shell #106111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
4 tasks done
Labels
Comments
This was referenced Aug 26, 2024
Harini0924
added a commit
that referenced
this issue
Aug 27, 2024
…ompatibility (#106115) This patch addresses compatibility issues with the lit internal shell by expanding and rewriting test scripts in the compiler-rt subproject. These changes were prompted by the FileNotFound unresolved errors encountered during the testing process, specifically when running the command `LIT_USE_INTERNAL_SHELL=1 ninja check compiler-rt`. **Why the error occurred:** The error occurred because the original test scripts used process substitution `(<(...))` in their diff commands. Process substitution creates temporary files or FIFOs to hold command output, and these are then passed to `diff`. However, the lit internal shell, which is more limited than a typical shell like `bash`, does not support process substitution. When lit tries to execute these commands, it is unable to create or access the temporary files or FIFOs generated by process substitution. As a result, lit attempts to open a file or directory that doesn't exist, leading to the `FileNotFoundError`. **Changes Made:** - Instead of using process substitution, the commands now explicitly redirect the output of `llvm-profdata show` to temporary files before performing the `diff` comparison. This ensures that the lit internal shell can correctly find and open these files, resolving the `FileNotFoundError`. [This change is relevant [RFC] Enabling the lit internal shell by Default](https://discourse.llvm.org/t/rfc-enabling-the-lit-internal-shell-by-default/80179) fixes: #106111
Harini0924
added a commit
that referenced
this issue
Aug 27, 2024
…or-loop (#106150) This patch adds `REQUIRES: shell` to the `focus-function.test` because the lit internal shell does not support the for loop syntax. This will make the test file unsupported when running llvm-lit with its internal shell implementation, which is enabled by turning on the `LIT_USE_INTERNAL_SHELL=1`. fixes: #106111
14 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When using the internal shell with this command
LIT_USE_INTERNAL_SHELL=1
anFileNotFoundError
is displayed.Error displayed:
Affected Tests:
These files need to be expanded to resolve the issue.
The text was updated successfully, but these errors were encountered: