trpc.group/trpc-go/trpc-go@v1.0.3/docs/benchmark.md (about)

     1  English | [中文](benchmark.zh_CN.md)
     2  
     3  # Benchmark
     4  
     5  ## Environment
     6  
     7  * Tencent Cloud Standard SA2 CVM, equipped with an AMD EPYC™ Rome processor
     8    * uname -a
     9      * Linux VM-0-13-centos 3.10.0-1160.92.1.el7.x86_64 #1 SMP Tue Jun 20 11:48:01 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
    10    * cat /proc/cpuinfo
    11      * Refer to the appendix (8 cores, 2.60GHz)
    12  * Memory: 16GB
    13  * Network environment: The average ping latency between the calling and called machines is around 0.2ms
    14  * Go version used during compilation: 1.21.2
    15  * Server-side: Bound to 8 cores (taskset -c 0-7)
    16    * Logic: Using the trpc protocol to echo the string "hello"
    17      * Corresponding packet length for sending: 122
    18      * Corresponding packet length for receiving: 27
    19  * Client-side: Bound to 8 cores (taskset -c 0-7)
    20    * Using eab and a load testing script
    21    * The load testing feature of eab involves maintaining a fixed number of long connections to the server and concurrently sending and receiving packets on these connections
    22  * The built-in tnet is enabled by default
    23  * Number of pollers enabled for tnet: 4
    24  * Client-side timeout: Set to 2 seconds by eab
    25  * Server-side timeout: Set to 1 second through framework configuration
    26  
    27  ## Scenario
    28  
    29  Throughput Testing: When the P99 latency of the caller is around 10ms, measure the QPS (Queries Per Second) of the service.
    30  
    31  
    32  |Mode|	Connections|	QPS/w|	Avery Latency/ms|	P90 Latency/ms|	P99 Latency/ms|	P999 Latency/ms|
    33  |-|-|-|-|-|-|-|
    34  |Synchronous|	100|	486652|	2.67|	4.22	|10.24	|16.76|
    35  |Asynchronous|	100|	404355|	2.61|	4.33	|10.34	|16.07|
    36  
    37  ## Appendix
    38  
    39  ```shell
    40  vendor_id	: AuthenticAMD
    41  cpu family	: 23
    42  model		: 49
    43  model name	: AMD EPYC 7K62 48-Core Processor
    44  stepping	: 0
    45  microcode	: 0x1000065
    46  cpu MHz		: 2595.124
    47  cache size	: 512 KB
    48  physical id	: 0
    49  siblings	: 8
    50  core id		: 11
    51  cpu cores	: 8
    52  apicid		: 7
    53  initial apicid	: 7
    54  fpu		: yes
    55  fpu_exception	: yes
    56  cpuid level	: 13
    57  wp		: yes
    58  flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm art rep_good nopl extd_apicid eagerfpu pni pclmulqdq ssse3 fma cx16 sse4_1 sse4_2 x2apic movbe popcnt aes xsave avx f16c rdrand hypervisor lahf_lm cmp_legacy cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw topoext rsb_ctxsw ibpb vmmcall fsgsbase bmi1 avx2 smep bmi2 rdseed adx smap clflushopt sha_ni xsaveopt xsavec xgetbv1 arat
    59  bogomips	: 5190.24
    60  TLB size	: 1024 4K pages
    61  clflush size	: 64
    62  cache_alignment	: 64
    63  address sizes	: 48 bits physical, 48 bits virtual
    64  power management:
    65  ```