- don't generate "&& true" when generating instruction eq() fn;
- use more Self;
- use subsec_millis instead of subsec_nanos and divide;
- coalesce two ifs;
* Don't implement Eq and Hash for EntityList
* Generate eq and hash methods for InstructionData
* Use the eq() and hash() methods of InstructionData in simple_gvn
* Now diagnosing missing vmctx arguments (fixes#376).
* Added filetest for fix of #376.
* Respect formatting rules in verifier/mod.rs.
* Added parameters for each use of vmctx in test files.
* Added comments on additions on vmctx verifications.
This requires splitting X86PCRel4 into two separate relocations, to
distinguish the case where the instruction is a call, as Mach-O uses a
different relocation in that case.
This also makes it explicit that only x86-64 relocations are supported
currently.
Make cretonne-codegen's `result` module private, and instead just export
`CodegenError` and `CodegenResult` at the top level of the
cretonne-codegen crate. This makes them more consistent with Result and
Error types in other cretonne crates.
In the text format, allow aliases to be defined multiple times, as long
as they're always aliasing the same value.
write.rs is already emitting redundant aliases, because it emits them at
their uses, so this change allows the parser to be able to parse such
code.
This switches from a custom list of architectures to use the
target-lexicon crate.
- "set is_64bit=1; isa x86" is replaced with "target x86_64", and
similar for other architectures, and the `is_64bit` flag is removed
entirely.
- The `is_compressed` flag is removed too; it's no longer being used to
control REX prefixes on x86-64, ARM and Thumb are separate
architectures in target-lexicon, and we can figure out how to
select RISC-V compressed encodings when we're ready.
* Update to rustfmt-preview.
* Run "cargo fmt --all" with rustfmt 0.4.1.
rustfmt 0.4.1 is the latest release of rustfmt-preview available on the
stable channel.
* Fix a long line that rustfmt 0.4.1 can't handle.
* Remove unneeded commas left behind by rustfmt.
* Optimize 0.0 floating point constants. Rather than using the existing
process of emitting bit patterns and moving them into floating point
registers, use the `xorps` instruction to zero out the register.
* is_zero predicate function will not accept negative zero. Fixed formatting for encoding recipe and filetests.
Define `WasmError` (and an accompanying `WasmResult`) to represent
errors translating WebAssembly functions. Make `translate_call` and
related functions return `WasmResult`s so that embedders have the
flexibility to reject features they don't support.
Move `InvalidInput` out of `CtonError` and into `WasmError`, where it's
now named `InvalidWebAssembly`, as it's a WebAssembly-specific error
condition. Also extend it to preserve the original error message and
bytecode offset.
* Use FxHashMap instead of HashMap for better performance
* Replace the binary search in the coalescing pass with a FxHashMap
This speeds up coalescing by up to 16% and overall compilation by 9%
* Generate debug symbols in optimized builds.
This allows profiling tools to provide more accurate information,
especially details about inlined functions.
* Rewrite and optimize partition_slice
This improves the performance of the register allocation passes
which use LiveValueTracker.