Update README.md

This commit is contained in:
nihui 2024-02-20 22:53:57 +08:00 committed by GitHub
parent 2d6e09dedf
commit 3ae3a44c74
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -2,7 +2,25 @@
detect cpu isa features with single-file
<table>
<tr><td>CPU arch</td><td> &#9989; x86, x86-64<br/>&#9989; arm, aarch64</td></tr>
<tr><td>CPU arch</td><td> &#9989; x86, x86-64<br/>&#9989; arm, aarch64</td><td rowspan=3>
```c
#define RUAPU_IMPLEMENTATION
#include "ruapu.h"
int main()
{
// initialize ruapu once
ruapu_cpu_init();
// now, tell me if this cpu has avx2
int has_avx2 = ruapu_cpu_supports("avx2");
return 0;
}
```
</td></tr>
<tr><td>OS</td><td>&#9989; Windows<br/>&#9989; Linux<br/>&#9989; macOS<br/>&#9989; Android<br/>&#9989; iOS</td></tr>
<tr><td>Compiler</td><td>&#9989; GCC<br/>&#9989; Clang<br/>&#9989; MSVC</td></tr>
</table>