* Add `.llvmbc`/`.llvmir` to `ObjectFormat` for emitting unoptimized IR
* Replace `--verbose-air`, `--verbose-intern-pool`,
`--verbose-generic-instances`, `--verbose-llvm-ir`, and
`--verbose-llvm-bc` with various `--debug-log` scopes
* `--debug-log illegal-air`: pre-legalized Air
* `--debug-log legal-air`: post-legalized Air
* `--debug-log air`: final Air with liveness
* `--debug-log ip-stats`: InternPool statistics
* `--debug-log ip-values`: InternPool values
* `--debug-log ip-generic-instances`: InternPool generic instances
* `--debug-log llvm-ir`: pre-optimized LLVM IR
* `--debug-log opt-llvm-ir`: post-optimized LLVM IR
* Delete `--verbose-cimport` which does nothing
* Delete `--verbose-llvm-cpu-features` which is equivalent to looking at
the outputs of `--show-builtin` and `--debug-log llvm-ir`
serves an ErrorBundle as a configuration_failed message instead of
configuration message upon connection. at this point the protocol enters
an invalid state and the process will need to be restarted in order to
reconfigure. in the future, build server should outlive
reconfigurations.
closes#36389
Just use ZIG_DEBUG_CMD the same as the other jit commands. Originally
this was working around a CI issue but that is no longer the case.
ZIG_DEBUG_MAKER is a new env var that didn't make it to any release tag
yet. Let's revert it to keep number of env vars more minimal.
Empty enums are uninstantiable, so their backing integer should be too.
This avoids a bunch of weird special cases during semantic analysis.
If you were previously using `enum {}`, your code should continue to work
fine.
If you were previously using `enum(uN) {}` (where `uN` is any integer type),
you'll probably want to use `enum(uN) { _ }` instead.
The current AstSmith is hand-written based on the formal PEG. However,
there is a significant impedance mismatch here since PEGs are a parser
specification not a language specification like CFGs. In other words,
it is not possible to directly translate an PEG into code that
efficiently generates all possible inputs recognized by the PEG.
Requirements for a new AstSmith:
1. Must be automatically generated based on the formal grammar
specification.
2. Must have linear runtime.
The current AstSmith is handwritten and unfortunately does not exactly
match the formal grammar. Tests like this need to have a single source
of truth and also need to be maintainable so I consider automatic
generation non-negotiable.
I did attempt to write a tool that takes a PEG as input and outputs an
AstSmith implementation. However, I no longer believe it is possible
to do a direct translation from an arbitrary PEG to an efficient
AstSmith, the lookahead and ordered choice features have worst-case
exponential runtime.
Conceptually, PEGs are simple to translate into parsers while CFGs
are simple to translate in to generators or smiths. I believe the
path forward is to translate our PEG into a CFG and generate a smith
based on that. I consider that task out of scope for this branch though.
This makes all commands in the zig executable that support color
output respect the user's preference for color output based on the
NO_COLOR and CLICOLOR_FORCE environment variables. Setting color
preference via command line option still overrides preferences set via
environment variables.
There is no concept of a "build runner" any more; it has been split in two:
configurer and maker.
Users of this feature will likely want to no longer override any logic, and
instead consume the configuration file produced by configurer.
If overriding one or the other of these is desired, the feature will need to be
re-introduced (as --override-maker or --override-configurer).