1This directory contains a mix of tests integrated with kselftest and 2standalone stress tests. 3 4kselftest tests 5=============== 6 7sve-probe-vls - Checks the SVE vector length enumeration interface 8sve-ptrace - Checks the SVE ptrace interface 9 10Running the non-kselftest tests 11=============================== 12 13sve-stress performs an SVE context switch stress test, as described 14below. 15 16(The fpsimd-stress test works the same way; just substitute "fpsimd" for 17"sve" in the following commands.) 18 19 20The test runs until killed by the user. 21 22If no context switch error was detected, you will see output such as 23the following: 24 25$ ./sve-stress 26(wait for some time) 27^C 28Vector length: 512 bits 29PID: 1573 30Terminated by signal 15, no error, iterations=9467, signals=1014 31Vector length: 512 bits 32PID: 1575 33Terminated by signal 15, no error, iterations=9448, signals=1028 34Vector length: 512 bits 35PID: 1577 36Terminated by signal 15, no error, iterations=9436, signals=1039 37Vector length: 512 bits 38PID: 1579 39Terminated by signal 15, no error, iterations=9421, signals=1039 40Vector length: 512 bits 41PID: 1581 42Terminated by signal 15, no error, iterations=9403, signals=1039 43Vector length: 512 bits 44PID: 1583 45Terminated by signal 15, no error, iterations=9385, signals=1036 46Vector length: 512 bits 47PID: 1585 48Terminated by signal 15, no error, iterations=9376, signals=1039 49Vector length: 512 bits 50PID: 1587 51Terminated by signal 15, no error, iterations=9361, signals=1039 52Vector length: 512 bits 53PID: 1589 54Terminated by signal 15, no error, iterations=9350, signals=1039 55 56 57If an error was detected, details of the mismatch will be printed 58instead of "no error". 59 60Ideally, the test should be allowed to run for many minutes or hours 61to maximise test coverage. 62 63 64KVM stress testing 65================== 66 67To try to reproduce the bugs that we have been observing, sve-stress 68should be run in parallel in two KVM guests, while simultaneously 69running on the host. 70 711) Start 2 guests, using the following command for each: 72 73$ lkvm run --console=virtio -pconsole=hvc0 --sve Image 74 75(Depending on the hardware GIC implementation, you may also need 76--irqchip=gicv3. New kvmtool defaults to that if appropriate, but I 77can't remember whether my branch is new enough for that. Try without 78the option first.) 79 80Kvmtool occupies the terminal until you kill it (Ctrl+A x), 81or until the guest terminates. It is therefore recommended to run 82each instance in separate terminal (use screen or ssh etc.) This 83allows multiple guests to be run in parallel while running other 84commands on the host. 85 86Within the guest, the host filesystem is accessible, mounted on /host. 87 882) Run the sve-stress on *each* guest with the Vector-Length set to 32: 89guest$ ./vlset --inherit 32 ./sve-stress 90 913) Run the sve-stress on the host with the maximum Vector-Length: 92host$ ./vlset --inherit --max ./sve-stress 93 94 95Again, the test should be allowed to run for many minutes or hours to 96maximise test coverage. 97 98If no error is detected, you will see output from each sve-stress 99instance similar to that illustrated above; otherwise details of the 100observed mismatches will be printed. 101