Experiencing long delays (-500ms) delays when calling IAudioClient::Initialize.
The issue is reproducible using WASAPIRendering sample application from https://github.com/microsoft/Windows-classic-samples after running app and selecting "2. default media device":
Intel Vtune profiler shows that all this time is spent inside some RPC call:
Sound devices info:
Name Realtek Audio
Manufacturer Realtek
Status OK
PNP Device ID INTELAUDIO\FUNC_01&VEN_10EC&DEV_0236&SUBSYS_10280A20&REV_1000\5&4790050&0&0001
Driver C:\WINDOWS\SYSTEM32\DRIVERS\RTKVHD64.SYS (6.0.9261.1, 6.24 MB (6,548,024 bytes), 2/27/2022 4:26 PM)
Name Intel® Smart Sound Technology for USB Audio
Manufacturer Intel(R) Corporation
Status OK
PNP Device ID INTELAUDIO\CTLR_DEV_A0C8&LINKTYPE_06&DEVTYPE_06&VEN_8086&DEV_AE50&SUBSYS_0A201028&REV_0001\0601
Driver C:\WINDOWS\SYSTEM32\DRIVERSTORE\FILEREPOSITORY\INTCUSB.INF_AMD64_2F4C83F014FFDAEE\INTCUSB.SYS (10.24.0.6815, 862.16 KB (882,848 bytes), 11/30/2021 2:33 AM)
System info:
OS Name Microsoft Windows 10 Pro
Version 10.0.19045 Build 19045
Other OS Description Not Available
OS Manufacturer Microsoft Corporation
System Name LWO1-LDL-A15808
System Manufacturer Dell Inc.
System Model Latitude 5420
System Type x64-based PC
System SKU 0A20
Processor 11th Gen Intel(R) Core(TM) i7-1185G7 @ 3.00GHz, 1805 Mhz, 4 Core(s), 8 Logical Processor(s)
BIOS Version/Date Dell Inc. 1.15.1, 12/20/2021
SMBIOS Version 3.2
Embedded Controller Version 255.255
BIOS Mode UEFI
BaseBoard Manufacturer Dell Inc.
BaseBoard Product 054CCV
BaseBoard Version A00
Platform Role Mobile
Secure Boot State Off
PCR7 Configuration Binding Not Possible
Windows Directory C:\Windows
System Directory C:\Windows\system32
Boot Device \Device\HarddiskVolume1
Locale Ukraine
Hardware Abstraction Layer Version = "10.0.19041.2251"
User Name SYNAPSE\sviatoslav.romankiv
Time Zone FLE Standard Time
Installed Physical Memory (RAM) 16.0 GB
Total Physical Memory 15.4 GB
Available Physical Memory 641 MB
Total Virtual Memory 28.4 GB
Available Virtual Memory 7.33 GB
Page File Space 13.0 GB
Page File C:\pagefile.sys
Kernel DMA Protection Off
Virtualization-based security Not enabled
Device Encryption Support Reasons for failed automatic device encryption: PCR7 binding is not supported, Un-allowed DMA capable bus/device(s) detected, WinRE is not configured
Hyper-V - VM Monitor Mode Extensions Yes
Hyper-V - Second Level Address Translation Extensions Yes
Hyper-V - Virtualization Enabled in Firmware Yes
Hyper-V - Data Execution Protection Yes