Skip to content

[Release] Don't build during test-release.sh Phase 3 install #82001

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

Merged
merged 1 commit into from
Feb 20, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions llvm/utils/release/test-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -537,6 +537,11 @@ function build_llvmCore() {
InstallTarget="$InstallTarget install-builtins"
fi
fi
if [ "$Phase" -eq "3" ]; then
# Build everything at once, with the proper parallelism and verbosity,
# in Phase 3.
BuildTarget=
Copy link
Collaborator

Choose a reason for hiding this comment

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

Does this actually change anything? Isn't this variable already unset?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

IIUC, BuildTarget is global, so stays unchanged from previous Phases unless reset. That's what I see in the build logs when comparing rc1 (with unchanged test-release.sh) and rc2 (with locally patched test-release.sh):

rc1:

 Phase 3: Building llvmCore
[...]
# Compiling llvm 18.1.0-rc1 Release
# ninja -j 8 -v
[1/4140
[...]
# Installing llvm 18.1.0-rc1 Release
# ninja install
[1/4093] Creating export file for LLVMHello
[2/4093] Building CXX object lib/MCA/CMakeFiles/LLVMMCA.dir/HardwareUnits/HardwareUnit.cpp.o

vs. rc2:

# Phase 3: Building llvmCore
[...]
# Compiling llvm 18.1.0-rc2 Release
# ninja -j 12 -v
[1/8225]
[...]
# Installing llvm 18.1.0-rc2 Release
# ninja install
[0/8] Performing build step for 'builtins'

i.e. with the patched script, in Phase 3 way more targets are actually built (with proper -v and -jN) in the build phase and nothing's built during ninja install, as it should be (and where the default parallelism does no harm).

fi

cd $ObjDir
echo "# Compiling llvm $Release-$RC $Flavor"
Expand Down