Skip to content
Merged
Show file tree
Hide file tree
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
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ which ships as part of the MSVC toolset and the Visual Studio IDE.
* Our [Status Chart][] displays our overall progress over time.
* Join our [Discord server][].

[![Build Status](https://dev.azure.com/vclibs/STL/_apis/build/status/microsoft.STL?branchName=master)][Pipelines]
[![Build Status](https://dev.azure.com/vclibs/STL/_apis/build/status/microsoft.STL?branchName=main)][Pipelines]

# What This Repo Is Useful For

Expand Down Expand Up @@ -57,12 +57,12 @@ issue. The [bug tag][] and [enhancement tag][] are being populated.

# Goals

We're implementing the latest C++ Working Draft, currently [N4868][], which will eventually become the next C++
International Standard, C++20. The terms Working Draft (WD) and Working Paper (WP) are interchangeable; we often
We're implementing the latest C++ Working Draft, currently [N4878][], which will eventually become the next C++
International Standard. The terms Working Draft (WD) and Working Paper (WP) are interchangeable; we often
informally refer to these drafts as "the Standard" while being aware of the difference. (There are other relevant
Standards; for example, supporting `/std:c++14` and `/std:c++17` involves understanding how the C++14 and C++17
Standards differ from the Working Paper, and we often need to refer to the C Standard Library and ECMAScript regular
expression specifications.)
expression specifications.) We're currently prioritizing C++20 features before starting any work on C++23.

Our primary goals are conformance, performance, usability, and compatibility.

Expand Down Expand Up @@ -405,10 +405,10 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
[LWG issues]: https://cplusplus.github.io/LWG/lwg-toc.html
[LWG tag]: https://github.com/microsoft/STL/issues?q=is%3Aopen+is%3Aissue+label%3ALWG
[Microsoft Open Source Code of Conduct]: https://opensource.microsoft.com/codeofconduct/
[N4868]: https://wg21.link/n4868
[N4878]: https://wg21.link/n4878
[NOTICE.txt]: NOTICE.txt
[Ninja]: https://ninja-build.org
[Pipelines]: https://dev.azure.com/vclibs/STL/_build/latest?definitionId=4&branchName=master
[Pipelines]: https://dev.azure.com/vclibs/STL/_build/latest?definitionId=4&branchName=main
[Python]: https://www.python.org/downloads/windows/
[Roadmap]: https://github.com/microsoft/STL/wiki/Roadmap
[Status Chart]: https://microsoft.github.io/STL/
Expand Down
71 changes: 71 additions & 0 deletions azure-devops/checkout-sources.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

parameters:
- name: vcpkgSHAVar
type: string
default: vcpkgSHA
- name: llvmSHAVar
type: string
default: llvmSHA
steps:
- checkout: self
clean: true
submodules: false
- task: PowerShell@2
displayName: 'Get submodule SHAs'
timeoutInMinutes: 1
inputs:
targetType: inline
script: |
cd $(Build.SourcesDirectory)
$regexSubmoduleSHA = '^[ \-+]([0-9a-f]+) .*$'
$llvmSHA = git submodule status --cached llvm-project | %{$_ -replace $regexSubmoduleSHA, '$1'}
Write-Host "##vso[task.setvariable variable=${{ parameters.llvmSHAVar }};]$llvmSHA"
$vcpkgSHA = git submodule status --cached vcpkg | %{$_ -replace $regexSubmoduleSHA, '$1'}
Write-Host "##vso[task.setvariable variable=${{ parameters.vcpkgSHAVar }};]$vcpkgSHA"
- script: |
cd $(Build.SourcesDirectory)
if not exist "llvm-project" (
mkdir llvm-project
)
cd llvm-project

if not exist ".git" (
del /S /Q *
git init
)

git remote get-url llvm
if errorlevel 1 (
git remote add llvm https://github.com/llvm/llvm-project.git
git config --local extensions.partialClone llvm
)

git fetch --filter=tree:0 --depth=1 llvm $(${{ parameters.llvmSHAVar }})
git sparse-checkout init --cone
git sparse-checkout set libcxx/test libcxx/utils/libcxx llvm/utils/lit
git reset --quiet --hard FETCH_HEAD
git clean --quiet -x -d -f
displayName: "Checkout LLVM source"
- script: |
cd $(Build.SourcesDirectory)
if not exist "vcpkg" (
mkdir vcpkg
)
cd vcpkg

if not exist ".git" (
del /S /Q *
git init
)

git remote get-url vcpkg
if errorlevel 1 (
git remote add vcpkg https://github.com/Microsoft/vcpkg.git
git config --local extensions.partialClone vcpkg
)

git fetch --filter=tree:0 --depth=1 vcpkg $(${{ parameters.vcpkgSHAVar }})
git checkout -f FETCH_HEAD
displayName: "Checkout vcpkg source"
52 changes: 52 additions & 0 deletions azure-devops/cmake-configure-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

parameters:
- name: hostArch
type: string
- name: targetArch
type: string
- name: vcpkgLocationVar
type: string
default: vcpkgLocation
- name: targetPlatform
type: string
- name: buildOutputLocationVar
type: string
default: buildOutputLocation
- name: cmakeAdditionalFlags
type: string
default: ''
steps:
- task: PowerShell@2
displayName: 'Get Test Parallelism'
timeoutInMinutes: 1
inputs:
targetType: inline
script: |
$testParallelism = $env:NUMBER_OF_PROCESSORS - 2
Write-Host "##vso[task.setvariable variable=testParallelism;]$testParallelism"
- script: |
if exist "$(${{ parameters.buildOutputLocationVar }})" (
rmdir /S /Q "$(${{ parameters.buildOutputLocationVar }})"
)
call "%PROGRAMFILES(X86)%\Microsoft Visual Studio\2019\Preview\Common7\Tools\VsDevCmd.bat" ^
-host_arch=${{ parameters.hostArch }} -arch=${{ parameters.targetArch }} -no_logo
cmake ${{ parameters.cmakeAdditionalFlags}} -G Ninja ^
-DCMAKE_TOOLCHAIN_FILE=$(${{ parameters.vcpkgLocationVar }})\scripts\buildsystems\vcpkg.cmake ^
-DVCPKG_TARGET_TRIPLET=${{ parameters.targetPlatform }}-windows ^
-DCMAKE_CXX_COMPILER=cl ^
-DCMAKE_BUILD_TYPE=Release ^
-DLIT_FLAGS=$(litFlags) ^
-DCMAKE_CXX_FLAGS=/analyze:autolog- ^
-S $(Build.SourcesDirectory) -B $(${{ parameters.buildOutputLocationVar }})
displayName: 'Configure the STL'
timeoutInMinutes: 2
env: { TMP: $(tmpDir), TEMP: $(tmpDir) }
- script: |
call "%PROGRAMFILES(X86)%\Microsoft Visual Studio\2019\Preview\Common7\Tools\VsDevCmd.bat" ^
-host_arch=${{ parameters.hostArch }} -arch=${{ parameters.targetArch }} -no_logo
cmake --build $(${{ parameters.buildOutputLocationVar }})
displayName: 'Build the STL'
timeoutInMinutes: 10
env: { TMP: $(tmpDir), TEMP: $(tmpDir) }
51 changes: 51 additions & 0 deletions azure-devops/cross-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

parameters:
- name: hostArch
type: string
default: amd64
- name: targetPlatform
type: string
- name: vsDevCmdArch
type: string
- name: buildOutputLocationVar
type: string
default: buildOutputLocation
- name: numShards
type: number
default: 8
jobs:
- job: '${{ parameters.targetPlatform }}'
variables:
fixedFlags: '--timeout=240;--shuffle'
parallelismFlag: '-j$(testParallelism)'
xmlOutputFlag: '--xunit-xml-output=$(${{ parameters.buildOutputLocationVar }})/test-results.xml'
shardFlags: '--num-shards=$(System.TotalJobsInPhase);--run-shard=$(System.JobPositionInPhase)'
litFlags: '$(fixedFlags);$(parallelismFlag);$(xmlOutputFlag);$(shardFlags)'
strategy:
parallel: ${{ parameters.numShards }}
timeoutInMinutes: 360
steps:
- script: |
if exist "$(tmpDir)" (rmdir /S /Q $(tmpDir))
mkdir $(tmpDir)
displayName: 'Setup TMP Directory'

- template: checkout-sources.yml
- template: vcpkg-dependencies.yml
parameters:
targetPlatform: ${{ parameters.targetPlatform }}
- template: cmake-configure-build.yml
parameters:
targetPlatform: ${{ parameters.targetPlatform }}
hostArch: ${{ parameters.hostArch }}
targetArch: ${{ parameters.vsDevCmdArch }}
cmakeAdditionalFlags: '-DTESTS_BUILD_ONLY=ON'
- template: run-tests.yml
parameters:
hostArch: ${{ parameters.hostArch }}
targetPlatform: ${{ parameters.targetPlatform }}
targetArch: ${{ parameters.vsDevCmdArch }}
displayName: 'Build Tests'
publishArtifact: true
45 changes: 45 additions & 0 deletions azure-devops/native-build-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

parameters:
- name: targetPlatform
type: string
- name: vsDevCmdArch
type: string
- name: buildOutputLocationVar
type: string
default: buildOutputLocation
- name: numShards
type: number
default: 8
jobs:
- job: '${{ parameters.targetPlatform }}'
variables:
fixedFlags: '--timeout=240;--shuffle'
parallelismFlag: '-j$(testParallelism)'
xmlOutputFlag: '--xunit-xml-output=$(${{ parameters.buildOutputLocationVar }})/test-results.xml'
shardFlags: '--num-shards=$(System.TotalJobsInPhase);--run-shard=$(System.JobPositionInPhase)'
litFlags: '$(fixedFlags);$(parallelismFlag);$(xmlOutputFlag);$(shardFlags)'
strategy:
parallel: ${{ parameters.numShards }}
timeoutInMinutes: 360
steps:
- script: |
if exist "$(tmpDir)" (rmdir /S /Q $(tmpDir))
mkdir $(tmpDir)
displayName: 'Setup TMP Directory'

- template: checkout-sources.yml
- template: vcpkg-dependencies.yml
parameters:
targetPlatform: ${{ parameters.targetPlatform }}
- template: cmake-configure-build.yml
parameters:
targetPlatform: ${{ parameters.targetPlatform }}
targetArch: ${{ parameters.vsDevCmdArch }}
hostArch: ${{ parameters.vsDevCmdArch }}
- template: run-tests.yml
parameters:
hostArch: ${{ parameters.vsDevCmdArch }}
targetPlatform: ${{ parameters.targetPlatform }}
targetArch: ${{ parameters.vsDevCmdArch }}
130 changes: 0 additions & 130 deletions azure-devops/run-build.yml

This file was deleted.

Loading