Skip to content
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

App Controlled Execution Config #3034

Merged
merged 34 commits into from
Sep 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
0d74887
App Controlled Execution Config
nibanks Aug 30, 2022
0f9ee9a
Fix kernel datapath
nibanks Aug 30, 2022
eefc587
XDP uses shared EC
nibanks Aug 30, 2022
cff97fe
Some fixes
nibanks Aug 30, 2022
e48d362
Merge branch 'main' into nibanks/custom-execution-config
nibanks Aug 30, 2022
1e2503e
Fix posix build error
nibanks Aug 30, 2022
e111f25
Fix winkernel
nibanks Aug 30, 2022
2eaee7e
More fixes and improvements
nibanks Aug 31, 2022
b7b9842
Comment out SharedEC from CI
nibanks Aug 31, 2022
e3ab9c2
Fix XDP alloc size
nibanks Aug 31, 2022
2a62cd3
Some fixes
nibanks Sep 1, 2022
d9ebb80
Reenable send queuing
nibanks Sep 1, 2022
22d8c7b
Merge branch 'main' into nibanks/custom-execution-config
nibanks Sep 11, 2022
f067366
Some refactor to use execution profile instead
nibanks Sep 12, 2022
90479c1
Fix dotnet/clog
nibanks Sep 12, 2022
08a6bb8
Specify execution profile on client side
nibanks Sep 12, 2022
9d964d2
Remove all sharedEC stuff
nibanks Sep 12, 2022
49e49a5
Fix scavenger
nibanks Sep 12, 2022
37eb155
Move to windbgx
nibanks Sep 12, 2022
224145a
Disable -cpu option on kernel for build fix
nibanks Sep 12, 2022
14e1b06
Copy exec mode to server
nibanks Sep 26, 2022
fd8fb02
Merge branch 'main' into nibanks/custom-execution-config
nibanks Sep 26, 2022
51630bf
Merge branch 'main' into nibanks/custom-execution-config
nibanks Sep 27, 2022
4b04c70
Fix exec profile
nibanks Sep 27, 2022
d3c4202
Fix exec profile check
nibanks Sep 27, 2022
689a21e
New logs
nibanks Sep 27, 2022
b586f1a
Use latest XDP release
nibanks Sep 28, 2022
5695f88
split low lat and max tput RPS tests
nibanks Sep 28, 2022
020797f
Use max throughput for ping tests
nibanks Sep 28, 2022
6a140eb
Unique name
nibanks Sep 28, 2022
2cd8d95
Revert test split
nibanks Sep 28, 2022
e022058
Update PDG files
nibanks Sep 28, 2022
6913772
Set uninitialized flag on error path
nibanks Sep 29, 2022
c61f671
Fix name and comment for polling idle timeout
nibanks Sep 30, 2022
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
34 changes: 0 additions & 34 deletions .azure/azure-pipelines.ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -178,15 +178,6 @@ stages:
config: Debug
extraName: 'static'
extraBuildArgs: -EnableTelemetryAsserts -Static -ExtraArtifactDir Static
- template: ./templates/build-config-user.yml
parameters:
image: windows-2019
platform: windows
arch: x64
tls: schannel
config: Debug
extraName: 'shared_ec'
extraBuildArgs: -EnableTelemetryAsserts -SharedEC -ExtraArtifactDir shared_ec
- template: ./templates/build-config-user.yml
parameters:
image: windows-2019
Expand Down Expand Up @@ -334,15 +325,6 @@ stages:
config: Debug
extraName: 'systemopenssl'
extraBuildArgs: -UseSystemOpenSSLCrypto -ExtraArtifactDir SystemCrypto
- template: ./templates/build-config-user.yml
parameters:
image: ubuntu-latest
platform: linux
arch: x64
tls: openssl
config: Debug
extraName: 'shared_ec'
extraBuildArgs: -SharedEC -ExtraArtifactDir shared_ec

- stage: build_linux_nontest
displayName: Build Linux - Non Tested
Expand Down Expand Up @@ -689,14 +671,6 @@ stages:
platform: windows
tls: schannel
allocFail: 100
- template: ./templates/run-spinquic.yml
parameters:
image: windows-2022
platform: windows
tls: schannel
allocFail: 100
extraArtifactDir: '_shared_ec'
extraTestArgs: -ExtraArtifactDir shared_ec
- template: ./templates/run-spinquic.yml
parameters:
image: windows-2022
Expand Down Expand Up @@ -738,14 +712,6 @@ stages:
platform: linux
tls: openssl
allocFail: 100
- template: ./templates/run-spinquic.yml
parameters:
image: ubuntu-latest
platform: linux
tls: openssl
allocFail: 100
extraArtifactDir: '_shared_ec'
extraTestArgs: -ExtraArtifactDir shared_ec
- template: ./templates/run-spinquic.yml
parameters:
image: macOS-12
Expand Down
114 changes: 3 additions & 111 deletions .azure/azure-pipelines.perf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,6 @@ parameters:
type: boolean
displayName: Windows (Schannel)
default: true
- name: winuser_sharedec
type: boolean
displayName: Windows (SharedEC, Schannel)
default: true
- name: winuser_xdp
type: boolean
displayName: Windows (XDP, Schannel)
Expand All @@ -68,10 +64,6 @@ parameters:
type: boolean
displayName: Linux (OpenSSL)
default: true
- name: linux_sharedec
type: boolean
displayName: Linux (SharedEC, OpenSSL)
default: true
- name: arch
type: string
displayName: Architecture
Expand Down Expand Up @@ -172,27 +164,6 @@ stages:
${{ if eq(parameters.pgo_mode, true) }}:
extraBuildArgs: -DisableTest -DisableTools -PGO

- ${{ if eq(parameters.winuser_sharedec, true) }}:
- stage: build_winuser_sharedec
displayName: Build Windows (SharedEC)
dependsOn: []
variables:
runCodesignValidationInjection: false
jobs:
- template: ./templates/build-config-user.yml
parameters:
image: windows-latest
platform: windows
arch: ${{ parameters.arch }}
tls: schannel
config: Release
extraName: 'sharedec'
extraPrepareArgs: -DisableTest
${{ if eq(parameters.pgo_mode, false) }}:
extraBuildArgs: -DisableTest -DisableTools -SharedEC -ExtraArtifactDir SharedEC
${{ if eq(parameters.pgo_mode, true) }}:
extraBuildArgs: -DisableTest -DisableTools -SharedEC -ExtraArtifactDir SharedEC -PGO

- ${{ if eq(parameters.winuser_xdp, true) }}:
- stage: build_winuser_xdp
displayName: Build Windows (XDP)
Expand Down Expand Up @@ -251,27 +222,6 @@ stages:
extraPrepareArgs: -DisableTest
extraBuildArgs: -DisableTest -DisableTools

- ${{ if eq(parameters.linux_sharedec, true) }}:
- stage: build_linux_sharedec
displayName: Build Linux (SharedEC)
dependsOn: []
variables:
runCodesignValidationInjection: false
jobs:
- template: ./templates/build-config-user.yml
parameters:
image: ubuntu-latest
platform: linux
arch: ${{ parameters.arch }}
tls: openssl
config: Release
extraName: 'sharedec'
extraPrepareArgs: -DisableTest
${{ if eq(parameters.pgo_mode, false) }}:
extraBuildArgs: -DisableTest -DisableTools -SharedEC -ExtraArtifactDir SharedEC
${{ if eq(parameters.pgo_mode, true) }}:
extraBuildArgs: -DisableTest -DisableTools -SharedEC -ExtraArtifactDir SharedEC -PGO

#
# Tests
#
Expand Down Expand Up @@ -327,33 +277,6 @@ stages:
extraArgs: -PGO
failOnRegression: 0

- ${{ if eq(parameters.winuser_sharedec, true) }}:
- stage: perf_winuser_sharedec
displayName: Performance Testing Windows (SharedEC)
dependsOn:
- build_winuser_sharedec
jobs:
- template: ./templates/run-performance.yml
parameters:
pool: MsQuic-Win-Perf
platform: windows
localTls: schannel
remoteTls: schannel
iterations: ${{ parameters.iterations }}
arch: ${{ parameters.arch }}
protocol: ${{ parameters.protocol }}
logProfile: ${{ parameters.logging }}
timeout: ${{ parameters.timeout }}
extraArtifactDir: '_SharedEC'
extraTestArgs: -ExtraArtifactDir _SharedEC
${{ if ne(parameters.testToRun, 'all') }}:
testToRun: ${{ parameters.testToRun }}
${{ if eq(parameters.pgo_mode, false) }}:
extraArgs: -SharedEC -Publish
${{ if eq(parameters.pgo_mode, true) }}:
extraArgs: -SharedEC -PGO
failOnRegression: 0

- ${{ if eq(parameters.winuser_xdp, true) }}:
- stage: perf_winuser_xdp
displayName: Performance Testing Windows (XDP)
Expand All @@ -372,14 +295,14 @@ stages:
logProfile: ${{ parameters.logging }}
timeout: ${{ parameters.timeout }}
extraArtifactDir: '_Xdp'
extraTestArgs: -ExtraArtifactDir _Xdp
extraTestArgs: -ExtraArtifactDir _Xdp -XDP
${{ if ne(parameters.testToRun, 'all') }}:
testToRun: ${{ parameters.testToRun }}
testTypes: Remote
${{ if eq(parameters.pgo_mode, false) }}:
extraArgs: -XDP -Publish
extraArgs: -Publish
${{ if eq(parameters.pgo_mode, true) }}:
extraArgs: -XDP -PGO
extraArgs: -PGO
failOnRegression: 0

- ${{ if eq(parameters.winuser_openssl, true) }}:
Expand Down Expand Up @@ -430,46 +353,15 @@ stages:
extraArgs: -PGO
failOnRegression: 0

- ${{ if eq(parameters.linux_sharedec, true) }}:
- stage: perf_linux_sharedec
displayName: Performance Testing Linux (SharedEC)
dependsOn:
- build_linux_sharedec
jobs:
- template: ./templates/run-performance.yml
parameters:
pool: MsQuic-Linux-Perf
platform: linux
localTls: openssl
remoteTls: openssl
iterations: ${{ parameters.iterations }}
arch: ${{ parameters.arch }}
protocol: ${{ parameters.protocol }}
logProfile: ${{ parameters.logging }}
timeout: ${{ parameters.timeout }}
extraArtifactDir: '_SharedEC'
extraTestArgs: -ExtraArtifactDir _SharedEC
${{ if ne(parameters.testToRun, 'all') }}:
testToRun: ${{ parameters.testToRun }}
testTypes: 'Remote'
${{ if eq(parameters.pgo_mode, false) }}:
extraArgs: -SharedEC -Publish
${{ if eq(parameters.pgo_mode, true) }}:
extraArgs: -SharedEC -PGO
failOnRegression: 0


- ${{ if eq(variables['Build.Reason'], 'IndividualCI') }}:
- stage: perf_post_process
displayName: Perf Post Processing
condition: succeededOrFailed()
dependsOn:
- perf_winkernel
- perf_winuser_schannel
- perf_winuser_sharedec
- perf_winuser_xdp
- perf_winuser_openssl
- perf_linux_openssl
- perf_linux_sharedec
jobs:
- template: ./templates/post-process-performance.yml
40 changes: 2 additions & 38 deletions .azure/azure-pipelines.periodic.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,23 +53,6 @@ stages:
extraPrepareArgs: -DisableTest
extraBuildArgs: -DisableTest -DisableTools -PGO

- stage: build_winuser_sharedec
displayName: Build Windows (SharedEC)
dependsOn: []
variables:
runCodesignValidationInjection: false
jobs:
- template: ./templates/build-config-user.yml
parameters:
image: windows-latest
platform: windows
arch: x64
tls: schannel
config: Release
extraName: 'sharedec'
extraPrepareArgs: -DisableTest
extraBuildArgs: -DisableTest -DisableTools -SharedEC -ExtraArtifactDir SharedEC -PGO

- stage: build_winuser_xdp
displayName: Build Windows (XDP)
dependsOn: []
Expand Down Expand Up @@ -123,24 +106,6 @@ stages:
extraArgs: -PGO
failOnRegression: 0

- stage: perf_winuser_sharedec
displayName: Performance Testing Windows (SharedEC)
dependsOn:
- build_winuser_sharedec
jobs:
- template: ./templates/run-performance.yml
parameters:
pool: MsQuic-Win-Perf
platform: windows
localTls: schannel
remoteTls: schannel
arch: x64
extraArtifactDir: '_SharedEC'
extraTestArgs: -ExtraArtifactDir _SharedEC
testTypes: Remote
extraArgs: -SharedEC -PGO
failOnRegression: 0

- stage: perf_winuser_xdp
displayName: Performance Testing Windows (XDP)
dependsOn:
Expand All @@ -154,17 +119,16 @@ stages:
remoteTls: schannel
arch: x64
extraArtifactDir: '_Xdp'
extraTestArgs: -ExtraArtifactDir _Xdp
extraTestArgs: -ExtraArtifactDir _Xdp -XDP
testTypes: Remote
extraArgs: -XDP -PGO
extraArgs: -PGO
failOnRegression: 0

- stage: make_pull_request
displayName: Make Pull Request
dependsOn:
- perf_winuser_schannel
- perf_winuser_openssl
- perf_winuser_sharedec
- perf_winuser_xdp
jobs:
- template: ./templates/make-pgo-pr.yml
4 changes: 2 additions & 2 deletions .github/workflows/test-down-level.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ jobs:
run: |
chmod +x artifacts/bin/linux/${{matrix.arch}}_Release_${{matrix.tls}}/msquictest
$env:LD_LIBRARY_PATH = Join-Path (Get-Location).Path "artifacts/bin/linux/${{matrix.arch}}_Release_${{matrix.tls}}"
scripts/test.ps1 -AZP -Config Release -Arch ${{ matrix.arch }} -Tls ${{ matrix.tls }} -SkipUnitTests -Filter -*CredValidation*:*ConnectClientCertificate*:Basic.StartTwoListenersSameALPN
scripts/test.ps1 -AZP -Config Release -Arch ${{ matrix.arch }} -Tls ${{ matrix.tls }} -SkipUnitTests -Filter -*CredValidation*:*ConnectClientCertificate*:Basic.StartTwoListenersSameALPN:ParameterValidation.ValidateGlobalParam
- name: Run Tests (Windows)
if: runner.os == 'Windows'
run: scripts/test.ps1 -AZP -Config Release -Arch ${{ matrix.arch }} -Tls ${{ matrix.tls }} -SkipUnitTests -Filter -*ValidateConfiguration:*ValidAlpnLengths:*ResumeRejection*:*ConnectClientCertificate*:Basic.StartTwoListenersSameALPN
run: scripts/test.ps1 -AZP -Config Release -Arch ${{ matrix.arch }} -Tls ${{ matrix.tls }} -SkipUnitTests -Filter -*ValidateConfiguration:*ValidAlpnLengths:*ResumeRejection*:*ConnectClientCertificate*:Basic.StartTwoListenersSameALPN:ParameterValidation.ValidateGlobalParam
20 changes: 6 additions & 14 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ option(QUIC_SKIP_CI_CHECKS "Disable CI specific build checks" OFF)
option(QUIC_TELEMETRY_ASSERTS "Enable telemetry asserts in release builds" OFF)
option(QUIC_USE_SYSTEM_LIBCRYPTO "Use system libcrypto if openssl TLS" OFF)
option(QUIC_HIGH_RES_TIMERS "Configure the system to use high resolution timers" OFF)
option(QUIC_SHARED_EC "Use shared execution contexts between QUIC and UDP" OFF)
option(QUIC_USE_XDP "Uses XDP instead of socket APIs" OFF)
option(QUIC_DISABLE_POSIX_GSO "Disable GSO for systems that say they support it but don't" OFF)
set(QUIC_FOLDER_PREFIX "" CACHE STRING "Optional prefix for source group folders when using an IDE generator")
Expand Down Expand Up @@ -323,21 +322,14 @@ if(QUIC_HIGH_RES_TIMERS)
list(APPEND QUIC_COMMON_DEFINES QUIC_HIGH_RES_TIMERS=1)
endif()

if(QUIC_SHARED_EC)
list(APPEND QUIC_COMMON_DEFINES QUIC_USE_EXECUTION_CONTEXTS=1)
endif()

if(QUIC_USE_XDP)
list(APPEND QUIC_COMMON_DEFINES QUIC_USE_EXECUTION_CONTEXTS=1 QUIC_USE_RAW_DATAPATH=1)
list(APPEND QUIC_COMMON_DEFINES QUIC_USE_RAW_DATAPATH=1)
endif()

if(QUIC_TLS STREQUAL "schannel")
message(STATUS "Enabling Schannel configuration tests")
list(APPEND QUIC_COMMON_DEFINES QUIC_TEST_SCHANNEL_FLAGS=1)
if (NOT QUIC_SHARED_EC)
message(STATUS "Enabling UDP Send Queuing")
list(APPEND QUIC_COMMON_DEFINES CXPLAT_DATAPATH_QUEUE_SENDS=1)
endif()

message(STATUS "Disabling PFX tests")
list(APPEND QUIC_COMMON_DEFINES QUIC_DISABLE_PFX_TESTS)
message(STATUS "Disabling 0-RTT support")
Expand Down Expand Up @@ -383,6 +375,9 @@ if(WIN32)
message(STATUS "Disabling (client) shared port support")
list(APPEND QUIC_COMMON_DEFINES QUIC_DISABLE_SHARED_PORT_TESTS)

message(STATUS "Enabling UDP Send Queuing")
list(APPEND QUIC_COMMON_DEFINES CXPLAT_DATAPATH_QUEUE_SENDS=1)

if (QUIC_UWP_BUILD)
list(APPEND QUIC_COMMON_DEFINES QUIC_UWP_BUILD QUIC_RESTRICTED_BUILD)
set(CMAKE_CXX_STANDARD_LIBRARIES "")
Expand Down Expand Up @@ -484,10 +479,7 @@ if(WIN32)
set(QUIC_PGO_NAME "msquic.${QUIC_TLS}.xdp.pgd")
set(QUIC_PGO_FILE "${CMAKE_CURRENT_SOURCE_DIR}/src/bin/winuser/pgo_${SYSTEM_PROCESSOR}/${QUIC_PGO_NAME}")
endif()
if(NOT EXISTS "${QUIC_PGO_FILE}" AND QUIC_SHARED_EC)
set(QUIC_PGO_NAME "msquic.${QUIC_TLS}.sharedec.pgd")
set(QUIC_PGO_FILE "${CMAKE_CURRENT_SOURCE_DIR}/src/bin/winuser/pgo_${SYSTEM_PROCESSOR}/${QUIC_PGO_NAME}")
endif()

if(NOT EXISTS "${QUIC_PGO_FILE}")
set(QUIC_PGO_NAME "msquic.${QUIC_TLS}.pgd")
set(QUIC_PGO_FILE "${CMAKE_CURRENT_SOURCE_DIR}/src/bin/winuser/pgo_${SYSTEM_PROCESSOR}/${QUIC_PGO_NAME}")
Expand Down
2 changes: 1 addition & 1 deletion docs/Settings.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ These parameters are accessed by calling [GetParam](./api/GetParam.md) or [SetPa
| `QUIC_PARAM_GLOBAL_GLOBAL_SETTINGS`<br> 6 | QUIC_GLOBAL_SETTINGS | Both | Globally change global only settings. |
| `QUIC_PARAM_GLOBAL_VERSION_SETTINGS`<br> 7 | QUIC_VERSIONS_SETTINGS | Both | Globally change version settings for all subsequent connections. |
| `QUIC_PARAM_GLOBAL_LIBRARY_GIT_HASH`<br> 8 | char[64] | Get-only | Git hash used to build MsQuic (null terminated string) |
| `QUIC_PARAM_GLOBAL_DATAPATH_PROCESSORS`<br> 9 | uint16_t[] | Both | Globally change the list of CPUs that datapath can use. Must be set before opening registration. |
| `QUIC_PARAM_GLOBAL_EXECUTION_CONFIG`<br> 9 | QUIC_EXECUTION_CONFIG | Both | Globally configure the execution model used for QUIC. Must be set before opening registration. |
| `QUIC_PARAM_GLOBAL_TLS_PROVIDER`<br> 10 | QUIC_TLS_PROVIDER | Get-Only | The TLS provider being used by MsQuic for the TLS handshake. |

## Registration Parameters
Expand Down
Loading