diff --git a/src/crypto/tls/common.go b/src/crypto/tls/common.go index 15d5eaffaa7..32caa6233cb 100644 --- a/src/crypto/tls/common.go +++ b/src/crypto/tls/common.go @@ -921,7 +921,14 @@ func initDefaultCipherSuites() { // Check the cpu flags for each platform that has optimized GCM implementations. // Worst case, these variables will just all be false hasGCMAsmAMD64 := cpu.X86.HasAES && cpu.X86.HasPCLMULQDQ - hasGCMAsmARM64 := cpu.ARM64.HasAES && cpu.ARM64.HasPMULL + + // TODO: enable the arm64 HasAES && HasPMULL feature check after the + // optimized AES-GCM implementation for arm64 is merged (CL 107298). + // This is explicitly set to false for now to prevent misprioritization + // of AES-GCM based cipher suites, which will be slower than chacha20-poly1305 + hasGCMAsmARM64 := false + // hasGCMAsmARM64 := cpu.ARM64.HasAES && cpu.ARM64.HasPMULL + hasGCMAsmS390X := cpu.S390X.HasKM && (cpu.S390X.HasKMA || (cpu.S390X.HasKMCTR && cpu.S390X.HasKIMD)) hasGCMAsm := hasGCMAsmAMD64 || hasGCMAsmARM64 || hasGCMAsmS390X