| ... | @@ -42,33 +42,71 @@ clarity. | ... | @@ -42,33 +42,71 @@ clarity. |
| 42 | * In addition to creating executables, creating a C library is a primary use | 42 | * In addition to creating executables, creating a C library is a primary use |
| 43 | case. You can export an auto-generated .h file. | 43 | case. You can export an auto-generated .h file. |
| 44 | | 44 | |
| 45 | ### Support Table | 45 | ### Supported Targets |
| 46 | | 46 | |
| 47 | Freestanding means that you do not directly interact with the OS | 47 | #### Tier 1 Support |
| 48 | or you are writing your own OS. | 48 | |
| 49 | | 49 | * Not only can Zig generate machine code for these targets, but the standard |
| 50 | Note that if you use libc or other libraries to interact with the OS, | 50 | library cross-platform abstractions have implementations for these targets. |
| 51 | that counts as "freestanding" for the purposes of this table. | 51 | Thus it is practical to write a pure Zig application with no dependency on |
| 52 | | 52 | libc. |
| 53 | | | freestanding | linux | macosx | windows | other | | 53 | * The CI server automatically tests these targets on every commit to master |
| 54 | |-------------|--------------|---------|---------|---------|---------| | 54 | branch, and updates ziglang.org/download with links to pre-built binaries. |
| 55 | |i386 | OK | planned | OK | planned | planned | | 55 | * These targets have debug info capabilities and therefore produce stack |
| 56 | |x86_64 | OK | OK | OK | OK | planned | | 56 | traces on failed assertions. |
| 57 | |arm | OK | planned | planned | planned | planned | | 57 | |
| 58 | |bpf | OK | planned | N/A | N/A | planned | | 58 | #### Tier 2 Support |
| 59 | |hexagon | OK | planned | N/A | N/A | planned | | 59 | |
| 60 | |mips | OK | planned | N/A | N/A | planned | | 60 | * There may be some standard library implementations, but many abstractions |
| 61 | |powerpc | OK | planned | N/A | N/A | planned | | 61 | will give an "Unsupported OS" compile error. One can link with libc or other |
| 62 | |r600 | OK | planned | N/A | N/A | planned | | 62 | libraries to fill in the gaps in the standard library. |
| 63 | |amdgcn | OK | planned | N/A | N/A | planned | | 63 | * These targets are known to work, but are not automatically tested, so there |
| 64 | |sparc | OK | planned | N/A | N/A | planned | | 64 | are occasional regressions. |
| 65 | |s390x | OK | planned | N/A | N/A | planned | | 65 | * Some tests may be disabled for these targets as we work toward Tier 1 |
| 66 | |spir | OK | planned | N/A | N/A | planned | | 66 | support. |
| 67 | |lanai | OK | planned | N/A | N/A | planned | | 67 | |
| 68 | |wasm32 | planned | N/A | N/A | N/A | N/A | | 68 | #### Tier 3 Support |
| 69 | |wasm64 | planned | N/A | N/A | N/A | N/A | | 69 | |
| 70 | |riscv32 | planned | planned | N/A | N/A | planned | | 70 | * The standard library has little to no knowledge of the existence of this |
| 71 | |riscv64 | planned | planned | N/A | N/A | planned | | 71 | target. |
| | 72 | * Because Zig is based on LLVM, it has the capability to build for these |
| | 73 | targets, and LLVM has the target enabled by default. |
| | 74 | * These targets are not frequently tested; one will likely need to contribute |
| | 75 | to Zig in order to build for these targets. |
| | 76 | * The Zig compiler might need to be updated with a few things such as |
| | 77 | - what sizes are the C integer types |
| | 78 | - C ABI calling convention for this target |
| | 79 | - bootstrap code and default panic handler |
| | 80 | |
| | 81 | #### Tier 4 Support |
| | 82 | |
| | 83 | * Support for these targets is entirely experimental. |
| | 84 | * LLVM may have the target as an experimental target, which means that you |
| | 85 | need to use Zig-provided binaries for the target to be available, or |
| | 86 | build LLVM from source with special configure flags. |
| | 87 | |
| | 88 | #### Support Table |
| | 89 | |
| | 90 | | | freestanding | linux | macosx | windows | freebsd | other | |
| | 91 | |--------|--------------|--------|--------|---------|---------|--------| |
| | 92 | |x86_64 | Tier 2 | Tier 1 | Tier 1 | Tier 1 | Tier 3 | Tier 3 | |
| | 93 | |i386 | Tier 2 | Tier 2 | Tier 2 | Tier 2 | Tier 3 | Tier 3 | |
| | 94 | |arm | Tier 2 | Tier 3 | Tier 3 | Tier 3 | Tier 3 | Tier 3 | |
| | 95 | |arm64 | Tier 2 | Tier 2 | Tier 3 | Tier 3 | Tier 3 | Tier 3 | |
| | 96 | |bpf | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 97 | |hexagon | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 98 | |mips | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 99 | |powerpc | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 100 | |r600 | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 101 | |amdgcn | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 102 | |sparc | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 103 | |s390x | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 104 | |spir | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 105 | |lanai | Tier 3 | Tier 3 | N/A | N/A | Tier 3 | Tier 3 | |
| | 106 | |wasm32 | Tier 4 | N/A | N/A | N/A | N/A | N/A | |
| | 107 | |wasm64 | Tier 4 | N/A | N/A | N/A | N/A | N/A | |
| | 108 | |riscv32 | Tier 4 | Tier 4 | N/A | N/A | Tier 4 | Tier 4 | |
| | 109 | |riscv64 | Tier 4 | Tier 4 | N/A | N/A | Tier 4 | Tier 4 | |
| 72 | | 110 | |
| 73 | ## Community | 111 | ## Community |
| 74 | | 112 | |