1 =================================
2 How To Release LLVM To The Public
3 =================================
8 This document contains information about successfully releasing LLVM ---
9 including sub-projects: e.g., ``clang`` and ``compiler-rt`` --- to the public.
10 It is the Release Manager's responsibility to ensure that a high quality build
13 If you're looking for the document on how to test the release candidates and
14 create the binary packages, please refer to the :doc:`ReleaseProcess` instead.
21 LLVM is released on a time based schedule --- with major releases roughly
22 every 6 months. In between major releases there may be dot releases.
23 The release manager will determine if and when to make a dot release based
24 on feedback from the community. Typically, dot releases should be made if
25 there are large number of bug-fixes in the stable branch or a critical bug
26 has been discovered that affects a large number of users.
28 Unless otherwise stated, dot releases will follow the same procedure as
31 The release process is roughly as follows:
33 * Set code freeze and branch creation date for 6 months after last code freeze
34 date. Announce release schedule to the LLVM community and update the website.
36 * Create release branch and begin release process.
38 * Send out release candidate sources for first round of testing. Testing lasts
39 7-10 days. During the first round of testing, any regressions found should be
40 fixed. Patches are merged from mainline into the release branch. Also, all
41 features need to be completed during this time. Any features not completed at
42 the end of the first round of testing will be removed or disabled for the
45 * Generate and send out the second release candidate sources. Only *critical*
46 bugs found during this testing phase will be fixed. Any bugs introduced by
47 merged patches will be fixed. If so a third round of testing is needed.
49 * The release notes are updated.
53 * Announce bug fix release schedule to the LLVM community and update the website.
55 * Tag bug fix -rc1 after 4 weeks have passed.
57 * Tag bug fix -rc2 4 weeks after -rc1.
59 * Tag additional -rc candidates, if needed, to fix critical issues in
60 previous -rc releases.
70 Release Administrative Tasks
71 ----------------------------
73 This section describes a few administrative tasks that need to be done for the
74 release process to begin. Specifically, it involves:
76 * Updating version numbers,
78 * Creating the release branch, and
80 * Tagging release candidates for the release team to begin testing.
85 Branch the Git trunk using the following procedure:
87 #. Remind developers that the release branching is imminent and to refrain from
88 committing patches that might break the build. E.g., new features, large
89 patches for works in progress, an overhaul of the type system, an exciting
90 new TableGen feature, etc.
92 #. Verify that the current git trunk is in decent shape by
93 examining nightly tester and buildbot results.
95 #. Bump the version in trunk to N.0.0git and tag the commit with llvmorg-N-init.
96 If ``X`` is the version to be released, then ``N`` is ``X + 1``.
100 $ git tag -a llvmorg-N-init
102 #. Clear the release notes in trunk.
104 #. Create the release branch from the last known good revision from before the
105 version bump. The branch's name is release/X.x where ``X`` is the major version
106 number and ``x`` is just the letter ``x``.
108 #. All tags and branches need to be created in both the llvm/llvm-project and
109 llvm/llvm-test-suite repos.
114 After creating the LLVM release branch, update the release branches'
115 ``CMakeLists.txt`` versions from '``X.0.0git``' to '``X.0.0``'.
117 In addition, the version numbers of all the Bugzilla components must be updated
118 for the next release.
120 Tagging the LLVM Release Candidates
121 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
123 Tag release candidates:
127 $ git tag -a llvmorg-X.Y.Z-rcN
129 The Release Manager must supply pre-packaged source tarballs for users. This can
130 be done with the export.sh script in utils/release.
132 Tarballs, release binaries, or any other release artifacts must be uploaded to
133 GitHub. This can be done using the github-upload-release.py script in utils/release.
137 $ github-upload-release.py upload --token <github-token> --release X.Y.Z-rcN --files <release_files>
141 $ ./export.sh -release X.Y.Z -rc $RC
143 This will generate source tarballs for each LLVM project being validated, which
144 can be uploaded to github for further testing.
146 Build The Binary Distribution
147 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
149 Creating the binary distribution requires following the instructions
150 :doc:`here <ReleaseProcess>`.
152 That process will perform both Release+Asserts and Release builds but only
153 pack the Release build for upload. You should use the Release+Asserts sysroot,
154 normally under ``final/Phase3/Release+Asserts/llvmCore-3.8.1-RCn.install/``,
155 for test-suite and run-time benchmarks, to make sure nothing serious has
156 passed through the net. For compile-time benchmarks, use the Release version.
158 The minimum required version of the tools you'll need are :doc:`here <GettingStarted>`
160 Release Qualification Criteria
161 ------------------------------
163 There are no official release qualification criteria. It is up to the
164 the release manager to determine when a release is ready. The release manager
165 should pay attention to the results of community testing, the number of outstanding
166 bugs, and then number of regressions when determining whether or not to make a
169 The community values time based releases, so releases should not be delayed for
170 too long unless there are critical issues remaining. In most cases, the only
171 kind of bugs that are critical enough to block a release would be a major regression
172 from a previous release.
177 A few developers in the community have dedicated time to validate the release
178 candidates and volunteered to be the official release testers for each
181 These will be the ones testing, generating and uploading the official binaries
182 to the server, and will be the minimum tests *necessary* for the release to
185 This will obviously not cover all OSs and distributions, so additional community
186 validation is important. However, if community input is not reached before the
187 release is out, all bugs reported will have to go on the next stable release.
189 The official release managers are:
191 * Major releases (X.0): Hans Wennborg
192 * Stable releases (X.n): Tom Stellard
194 The official release testers are volunteered from the community and have
195 consistently validated and released binaries for their targets/OSs. To contact
196 them, you should email the ``release-testers@lists.llvm.org`` mailing list.
198 The official testers list is in the file ``RELEASE_TESTERS.TXT``, in the ``LLVM``
204 Once all testing has been completed and appropriate bugs filed, the release
205 candidate tarballs are put on the website and the LLVM community is notified.
207 We ask that all LLVM developers test the release in any the following ways:
209 #. Download ``llvm-X.Y``, ``llvm-test-X.Y``, and the appropriate ``clang``
210 binary. Build LLVM. Run ``make check`` and the full LLVM test suite (``make
211 TEST=nightly report``).
213 #. Download ``llvm-X.Y``, ``llvm-test-X.Y``, and the ``clang`` sources. Compile
214 everything. Run ``make check`` and the full LLVM test suite (``make
215 TEST=nightly report``).
217 #. Download ``llvm-X.Y``, ``llvm-test-X.Y``, and the appropriate ``clang``
218 binary. Build whole programs with it (ex. Chromium, Firefox, Apache) for
221 #. Download ``llvm-X.Y``, ``llvm-test-X.Y``, and the appropriate ``clang``
222 binary. Build *your* programs with it and check for conformance and
223 performance regressions.
225 #. Run the :doc:`release process <ReleaseProcess>`, if your platform is
226 *different* than that which is officially supported, and report back errors
227 only if they were not reported by the official release tester for that
230 We also ask that the OS distribution release managers test their packages with
231 the first candidate of every release, and report any *new* errors in Bugzilla.
232 If the bug can be reproduced with an unpatched upstream version of the release
233 candidate (as opposed to the distribution's own build), the priority should be
236 During the first round of testing, all regressions must be fixed before the
237 second release candidate is tagged.
239 In the subsequent stages, the testing is only to ensure that bug
240 fixes previously merged in have not created new major problems. *This is not
241 the time to solve additional and unrelated bugs!* If no patches are merged in,
242 the release is determined to be ready and the release manager may move onto the
245 Reporting Regressions
246 ---------------------
248 Every regression that is found during the tests (as per the criteria above),
249 should be filled in a bug in Bugzilla with the priority *release blocker* and
250 blocking a specific release.
252 To help manage all the bugs reported and which ones are blockers or not, a new
253 "[meta]" bug should be created and all regressions *blocking* that Meta. Once
254 all blockers are done, the Meta can be closed.
256 If a bug can't be reproduced, or stops being a blocker, it should be removed
257 from the Meta and its priority decreased to *normal*. Debugging can continue,
263 You can use any of the following methods to request that a revision from trunk
264 be merged into a release branch:
266 #. Use the ``utils/release/merge-request.sh`` script which will automatically
267 file a bug_ requesting that the patch be merged. e.g. To request revision
268 12345 be merged into the branch for the 5.0.1 release:
269 ``llvm.src/utils/release/merge-request.sh -stable-version 5.0 -r 12345 -user bugzilla@example.com``
271 #. Manually file a bug_ with the subject: "Merge r12345 into the X.Y branch",
272 enter the commit(s) that you want merged in the "Fixed by Commit(s)" and mark
273 it as a blocker of the current release bug. Release bugs are given aliases
274 in the form of release-x.y.z, so to mark a bug as a blocker for the 5.0.1
275 release, just enter release-5.0.1 in the "Blocks" field.
277 #. Reply to the commit email on llvm-commits for the revision to merge and cc
280 .. _bug: https://bugs.llvm.org/
285 Below are the rules regarding patching the release branch:
287 #. Patches applied to the release branch may only be applied by the release
288 manager, the official release testers or the code owners with approval from
291 #. Release managers are encouraged, but not required, to get approval from code
292 owners before approving patches. If there is no code owner or the code owner
293 is unreachable then release managers can ask approval from patch reviewers or
294 other developers active in that area.
296 #. *Before RC1* Patches should be limited to bug fixes, important optimization
297 improvements, or completion of features that were started before the branch
298 was created. As with all phases, release managers and code owners can reject
299 patches that are deemed too invasive.
301 #. *Before RC2* Patches should be limited to bug fixes or backend specific
302 improvements that are determined to be very safe.
304 #. *Before RC3/Final Major Release* Patches should be limited to critical
307 #. *Bug fix releases* Patches should be limited to bug fixes or very safe
308 and critical performance improvements. Patches must maintain both API and
309 ABI compatibility with the previous major release.
315 Use the ``git cherry-pick -x`` command to merge patches to the release branch:
317 #. ``git cherry-pick -x abcdef0``
319 #. Run regression tests.
324 The final stages of the release process involves tagging the "final" release
325 branch, updating documentation that refers to the release, and updating the
331 Review the documentation in the release branch and ensure that it is up
332 to date. The "Release Notes" must be updated to reflect new features, bug
333 fixes, new known issues, and changes in the list of supported platforms.
334 The "Getting Started Guide" should be updated to reflect the new release
335 version number tag available from Subversion and changes in basic system
340 Tag the LLVM Final Release
341 ^^^^^^^^^^^^^^^^^^^^^^^^^^
343 Tag the final release sources:
347 $ git tag -a llvmorg-X.Y.Z
348 $ git push https://github.com/llvm/llvm-project.git llvmorg-X.Y.Z
350 Update the LLVM Website
351 ^^^^^^^^^^^^^^^^^^^^^^^
353 The website must be updated before the release announcement is sent out. Here
356 #. Check out the ``www-releases`` module from GitHub.
358 #. Create a new sub-directory ``X.Y.Z`` in the releases directory.
360 #. Copy and commit the ``llvm/docs`` and ``LICENSE.txt`` files into this new
363 #. Update the ``releases/download.html`` file with links to the release
366 #. Update the ``releases/index.html`` with the new release and link to release
369 #. Finally checkout the llvm-www repo and update the main page
370 (``index.html`` and sidebar) to point to the new release and release
376 Send an email to the list announcing the release, pointing people to all the
377 relevant documentation, download pages and bugs fixed.