Commit Graph

2018 Commits

Author SHA1 Message Date
Dan Gohman
c49c20713c Check for duplicate jump tables before performing any IR mutations.
This isn't fixing an actual bug, but it does make `add_jt` more
consistent with the other `add_*` functions.
2018-08-01 13:33:54 -07:00
Dan Gohman
63e87895eb Remove an unneeded command-line option. 2018-08-01 13:24:53 -07:00
Dan Gohman
f89cb1df64 Fix the test script to return an error if formatting diffs are found. 2018-08-01 13:24:53 -07:00
bjorn3
01729be8d7 Add comment support (#379)
* Add comment support

* Don't print empty comments

* Add nop instruction

* Add test and note

* Add FuncWriter trait

* Remove comment support

* Add write_preamble to FuncWriter

* Fix test

* Some changes
2018-08-01 11:21:05 -07:00
Dan Gohman
c42bed7452 Update paths for the meta => meta-python rename. 2018-08-01 05:05:33 -07:00
Benjamin Bouvier
3a550d185f Enhance Verifier error reporting; 2018-07-31 08:02:14 -07:00
Dan Gohman
1b42105faa Remove reserved_reg functionality. (#424)
* Remove reserved_reg functionality.

This wasn't implemented, and if we need it in the future, it seems like
it would be better to extend the concept of global values to cover this.

* Use GlobalValue::reserved_value() for sentinal values.
2018-07-31 07:57:37 -07:00
data-pup
d9d40e1cdf lib/codegen-meta moved into lib/codegen. (#423)
* lib/codegen-meta moved into lib/codegen.

* Renamed codegen-meta and existing meta.
2018-07-31 07:56:26 -07:00
Caroline Cullen
65a1a6bb28 Add serde functionality into lib. (#422)
* Adds decoration to the verifier errors.

example:

function %bad(i32) fast {
ebb0(v0: i32):
    brnz.i32 v0, ebb1
    return
    ^~~~~~

verifier inst1: Internal return not allowed with return_at_end=1

ebb1:
    trapz.i32 v0, user6
    return
}

Fixes #68

* Making it so that pretty_function_error and write_function_plain are both private.

* Changes write_ebb to decorate_ebb.
Adds documentation line to decorate_function.

* Removing Cargo.toml lib/serde addition

* Add serde functionality into lib.

* Fix so code is compatible with Rust version 1.25.0.

* Move ser/de functions to utility file, update description, remove borrow from arms.

* Remove commented out code.
2018-07-31 07:48:12 -07:00
Aaron Power
13fea26c95 Correctly handle duplicate definitions 2018-07-28 11:48:13 -07:00
Dan Gohman
d0fbf47987 Fix rustfmt errors. 2018-07-26 11:51:12 -07:00
Dan Gohman
e0124fa82f Rename local variables to clarify their purpose. 2018-07-26 11:14:52 -07:00
Dan Gohman
15520fa961 Enable a few more clippy lints. 2018-07-26 10:10:36 -07:00
Aaron Power
cc7ba7e69a Fixed remaning clippy warnings 2018-07-25 13:05:14 -07:00
Aaron Power
952a086f32 Fixed trivially_copy_pass_by_ref warnings 2018-07-25 10:31:01 -07:00
Corey Farwell
299898d494 Add fuzz target for cranelift_reader::parse_test. 2018-07-24 12:42:11 -07:00
Aaron Power
eed861c6e1 Implemented clippy improvements 2018-07-24 12:36:34 -07:00
Dan Gohman
d6d1e7253d Bump version to 0.17.0 2018-07-23 16:57:51 -07:00
Dan Gohman
8904ec77c9 Temporarily disable use of cretonne-codegen-meta.
Once we figure out how to publish this code, we can re-enable it.
2018-07-23 16:57:51 -07:00
Dan Gohman
6cb03a873d Bump version to 0.17.0-alpha 2018-07-23 16:15:53 -07:00
Benjamin Bouvier
78b04fc8ab Promote the (Block, Inst) tuple into a PredBlock struct; 2018-07-23 15:26:11 -07:00
Benjamin Bouvier
f72ff791b4 Promote the BasicBlock tuple to a real struct;
It makes reading code that uses it easier to understand.
2018-07-23 15:26:11 -07:00
data-pup
ce177d643e Remove gen_build_deps module. 2018-07-22 13:51:23 -07:00
Benjamin Bouvier
5f3cd868cd [wasm] Rename native_pointer() to pointer_type() to make it more apparent it's a type; 2018-07-20 13:11:36 -07:00
Dan Gohman
32d657d62a Update to faerie 0.4.4 and goblin 0.0.17. 2018-07-19 11:58:08 -07:00
Dan Gohman
7f98f436f0 Add a link to the faerie github page. 2018-07-19 11:08:53 -07:00
Dan Gohman
20899d04a1 Fix "Title overline too short." warnings in more *.rst files. 2018-07-19 11:08:53 -07:00
Dan Gohman
45ef3149f1 Update hashmap_core to 0.1.9. 2018-07-19 11:08:53 -07:00
Dan Gohman
c77df6f6d9 Add a TODO about a potential optimization opportunity. 2018-07-19 11:08:53 -07:00
data-pup
06319b415a Added initial Rust codegen-meta implementation. (#403)
* Added initial Rust codegen-meta implementation.

* Replace 'Cretonne' in comments.

* Prevent iterator overflow.

* 1.25.0 compatibility changes.

* Implemented debug traits for type variants.

* Added consistent comments.

* Cleaned up a loop via clippy fix.

* Added new license to codegen-meta Cargo.toml

* Edited lane type iterator `next` method.

* Removed functions that are not needed in Rust, and edited desc.

* Debug trait derived for valuetype.

* Added comments for iterator types in the base types submodule.

* Numbering is now handled in the cdsl/types.rs file.

* Moved type number logic into cdsl/types.

* Repeating the lane change cleanup.

* Removed codegen-meta crate from codegen deps.

* Typo fix.

* Addressing a patch note.

* Addressing patch note.

* Lowercase in vector names.

* Fixing a comment bug.

* Added a copy of the license file.

* Formatting changes.

* Cleaned up the vector type numbering.

* 1.25 compatibility.

* Fixed pattern match arms.
2018-07-19 09:56:23 -07:00
Benjamin Bouvier
7b290cd900 Move the code section parsing into its own function; 2018-07-19 06:39:56 -07:00
Benjamin Bouvier
03159a9200 Misc refactorings when looking at the wasm code; 2018-07-19 06:39:56 -07:00
Dan Gohman
c068721964 Bump version to 0.16.1 2018-07-18 13:33:15 -07:00
Dan Gohman
1081d06173 Use the new realm-switching ABI in the baldrdash calling convention. 2018-07-17 22:44:00 -07:00
Dan Gohman
ce27b2a74f Bump version to 0.16.0 2018-07-17 15:49:04 -07:00
Dan Gohman
76a537e3d4 Update to wasmparser.rs 0.17.2. 2018-07-17 15:46:35 -07:00
Dan Gohman
289145e7cf Update to wasmparser.rs 0.17.1. 2018-07-17 15:43:39 -07:00
Dan Gohman
c0d5ffc380 The latest Ubuntu LTS now has Rust 1.25. 2018-07-17 15:01:08 -07:00
Dan Gohman
82ea38e4af Convert expected uses to an unnumbered list, as they aren't ordered. 2018-07-17 15:01:08 -07:00
Dan Gohman
8d0f34310f Convert top-level *.rst files to markdown.
These files don't use any Sphinx has that Markdown lacks, and Markdown
is more widely used and easier to edit.
2018-07-17 15:01:08 -07:00
Dan Gohman
4d5451ad11 Fix "Title overline too short." warnings in more *.rst files. 2018-07-17 14:45:01 -07:00
Dan Gohman
17db4e6be8 Add a LICENSE file to each crate.
The individual crates are published separately from the main repository
on crates.io. To ensure that a copy of the LICENSE file accompanies all
published copies of the code, give each crate its own LICENSE file.
2018-07-17 12:48:27 -07:00
Dan Gohman
a28a3c3ea9 Bump version to 0.15.0 2018-07-14 07:27:35 -07:00
Dan Gohman
eb98082155 Update to faerie 0.4.3.
This resolves conflicts when multiple versions of target-lexicon are
used at the same time.
2018-07-14 06:46:22 -07:00
Dan Gohman
753bb049f8 Fix "Title overline too short." warnings in *.rst files. 2018-07-13 17:23:23 -07:00
Dan Gohman
ff188042bb Update comments and formatting in test-all.sh and publish-all.sh.
In particular, we no longer use the Github Releases page, so remove the
comment about that.
2018-07-13 17:21:03 -07:00
Dan Gohman
fe1a69ac19 Simplify the README.rst entry on building Cretonne.
Include a mention of cargo workspaces, and briefly describe the
test-all.sh script.
2018-07-13 17:08:51 -07:00
Dan Gohman
96e43b366d Add more comments explaining .travis.yml contents. 2018-07-13 17:03:57 -07:00
Dan Gohman
8930cb1b5d Update dependency versions. 2018-07-13 16:34:34 -07:00
Dan Gohman
f833d25ad1 Add a comment mentioning why we're remaining at cpuid 3.x for now. 2018-07-13 16:34:34 -07:00