Mike Gerwitz

Activist for User Freedom

aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [DEV-7085] Create `SortableAsg` traitJoseph Frazer2020-03-134-59/+205
| | | | | | Create a trait that sorts a graph into `Sections` that can then be used as an IR. The `BaseAsg` should implement the trait using what was originally in the POC.
* [DEV-7085] Implement `PartialEq` for `Sections`Joseph Frazer2020-03-131-2/+2
| | | | | | We want to be able to easily compare `Sections` in tests, so implementing `PartialEq` (and `Debug`) for both `Sections` and `Section` is required.
* [DEV-7085] Move sections to IR moduleJoseph Frazer2020-03-136-265/+287
| | | | | We need to use `Sections` in both the writer and the ASG so it needs to be in a place that makes sense.
* Allow yaml tests to evaluate assertions and prohibitsAustin Schaffer2020-03-123-9/+28
|\
| * [DEV-7160] Do not allow terminating classifications for test runnerAustin Schaffer2020-03-123-9/+27
| |
| * [DEV-7160] Set neg-yields param in retry templateAustin Schaffer2020-03-121-1/+2
|/
* [DEV-7134] Propagate errorsJoseph Frazer2020-03-097-62/+171
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge branch 'jira-7134' * jira-7134: [DEV-7134] Remove unnecessary node replacement [DEV-7134] Propagate errors from the writer [DEV-7134] Propagate sorting errors [DEV-7134] Propagate errors setting fragments [DEV-7134] Pass read event errors up the stack [DEV-7134] Return error for XmloEvent::SymDecl [DEV-7134] Add alias for LoadResult [DEV-7134] Remove unwrap so we can bubble up error messages [DEV-7134] Escalate the error from finding the absolute path
| * [DEV-7134] Remove unnecessary node replacementJoseph Frazer2020-03-091-20/+4
| | | | | | | | | | The node was being replaced before we were catching errors properly. Now that they are propagated, we should not need the replacement.
| * [DEV-7134] Propagate errors from the writerJoseph Frazer2020-03-092-15/+36
| | | | | | | | | | When an error occurs during the XML writing, they should be shown to the user.
| * [DEV-7134] Propagate sorting errorsJoseph Frazer2020-03-093-7/+18
| | | | | | | | | | If a node is found while sorting that is not expected, we should show the error to the user.
| * [DEV-7134] Propagate errors setting fragmentsJoseph Frazer2020-03-093-12/+106
| | | | | | | | | | | | | | | | If we cannot set a fragment, we need to display the error to the user. We are currently ignoring "___head", "___tail", and objects that are both virtual and overridden. Those will be corrected in with future changes.
| * [DEV-7134] Pass read event errors up the stackJoseph Frazer2020-03-061-5/+1
| |
| * [DEV-7134] Return error for XmloEvent::SymDeclJoseph Frazer2020-03-061-2/+1
| | | | | | | | | | We want more than warnings when a XmloEvent::SymDecl symbol has an unknown "kind".
| * [DEV-7134] Add alias for LoadResultJoseph Frazer2020-03-061-1/+4
| | | | | | | | It looks better and was recommended by Rust's linter.
| * [DEV-7134] Remove unwrap so we can bubble up error messagesJoseph Frazer2020-03-061-1/+1
| |
| * [DEV-7134] Escalate the error from finding the absolute pathJoseph Frazer2020-03-062-1/+2
|/ | | | | We do not want to have a panic here. The error should be displayed properly.
* Copyright year 2020 updateMike Gerwitz2020-03-06213-213/+275
|
* [DEV-7081] Add options to tameldJoseph Frazer2020-03-068-12/+553
|\ | | | | | | | | | | | | Merge branch 'jira-7081' * jira-7081: [DEV-7081] Add options to tameld
| * [DEV-7081] Add options to tameldJoseph Frazer2020-03-068-12/+553
| | | | | | | | | | | | | | We want to add an option to set the output file to the linker so we do not need to redirect output to awk any longer. This also adds integration tests for tameld.
* | configure.ac: Missing cargo-doc error=>warningMike Gerwitz2020-03-051-3/+4
|/ | | | | Documentation does not need to be built by most users, who are simply trying to bootstrap the system.
* TAMER linker (still partly proof-of-concept)Mike Gerwitz2020-03-0341-1601/+7058
|\ | | | | | | | | | | We will continue to finalize this as we go. It is currently used in production, both for performance and because it fixes a bug in the XSLT-based linker.
| * [DEV-7083] TAMER: xmle writerJoseph Frazer2020-03-038-271/+1252
| | | | | | | | This introduces the writer for xmle files.
| * TAMER: Additional crate::ld documentationMike Gerwitz2020-03-021-7/+69
| |
| * Replace XSLT-based linker with errorMike Gerwitz2020-03-022-1156/+7
| | | | | | | | | | | | | | | | | | | | All systems should be using the provided Makefile, so this shouldn't be invoked anymore. The new linker is still considered a proof-of-concept, but bugs have been encountered in the old one that are not worth investing the time into fixing. The new linker has been used in production for nearly a couple months and is functioning properly.
| * TAMER: Extract quick_xml event-related mocksMike Gerwitz2020-02-264-110/+149
| |
| * TAMER: Separate static xmle sectionMike Gerwitz2020-02-263-3/+7
| |
| * TAMER: Virtual symbol overrideMike Gerwitz2020-02-267-10/+165
| |
| * TAMER: POC: Use FxHash to remove nondeterminismMike Gerwitz2020-02-261-7/+7
| | | | | | | | | | The default SipHash is a cryptographic hash and causes ordering to change between runs.
| * TAMER: xmle output changes to support Summary PageMike Gerwitz2020-02-2610-89/+415
| | | | | | | | Co-Authored-By: Joseph Frazer <joseph.frazer@ryansg.com>
| * TAMER: POC: Output xmleMike Gerwitz2020-02-269-84/+598
| | | | | | | | This is a working proof-of-concept that will be finalized in future commits.
| * TAMER: Symbol source data and metadataMike Gerwitz2020-02-268-29/+311
| |
| * TAMER: Initial abstract semantic graph (ASG)Mike Gerwitz2020-02-2611-249/+1433
| | | | | | | | | | | | | | This begins to introduce the ASG, backed by Petgraph. The API will continue to evolve, and Petgraph will likely be encapsulated so that our implementation can vary independently from it (or even remove it in the future).
| * configure.ac: Rust 1.{39>41}.0 version bumpMike Gerwitz2020-02-251-2/+3
| | | | | | | | | | | | Relaxes orphan rules for foreign traits. This also modifies the error to suggest how to update using rustup.
| * TAMER: Fail on empty fragment ids (and fix underlying problem)Mike Gerwitz2020-02-252-0/+23
| |
| * TAMER: xmlo: Add Package eventMike Gerwitz2020-02-253-3/+196
| |
| * TAMER: poc: Use xmlo readerMike Gerwitz2020-02-251-125/+44
| | | | | | | | TODO: More information
| * TAMER: xmlo readerMike Gerwitz2020-02-257-1/+1704
| | | | | | | | | | | | This introduces the reader for xmlo files produced by the XSLT-based compiler. It is an initial implementation but is not complete; see future commits.
| * Makefile.am (html-am): Add --document-private-itemsMike Gerwitz2020-02-251-1/+1
| | | | | | | | | | This generated documenation is only going to be read be developers, and the private information is very useful to them.
| * TAMER (sym::Interner::intern_utf8_unchecked): New functionMike Gerwitz2020-02-252-0/+34
| | | | | | | | This removes boilerplate for reading xmlo files. See next commit.
| * TAMER: Display for SymbolMike Gerwitz2020-02-241-0/+18
| | | | | | | | | | | | One of the benefits of storing a reference to the interned string on the symbol itself is that we get to get its underlying value essentially for free.
| * Order symtable, sym-dep, fragmentsMike Gerwitz2020-02-245-17/+66
| | | | | | | | | | | | | | | | | | | | | | | | This ordering will simplify streaming processing of xmlo files in TAMER. Specifically, we know that symbols will have been declared by the time dependencies are added to the graph (and so we should only be creating edges to existing nodes); and we can halt reading as soon as the closing fragments tag is encountered, avoiding parsing the entirety of these massive XML files. On one particularly large program, this cuts time down from ~0.333s to ~0.300 in the POC linker.
| * TAMER: Arena-based string internerMike Gerwitz2020-02-244-828/+375
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Contrary to what I said previously, this replaces the previous implementation with an arena-backed internment system. The motivation for this change was investigating how Rustc performed its string interning, and why they chose to associate integer identifiers with symbols. The intent was originally to use Rustc's arena allocator directly, but that create pulled in far too many dependencies and depended on nightly Rust. Bumpalo provides a very similar implementation to Rustc's DroplessArena, so I went with that instead. Rustc also relies on a global, singleton interner. I do not do that here. Instead, the returned Symbol carries a lifetime of the underlying arena, as well as a pointer to the interned string. Now that this is put to rest, it's time to move on.
| * tamer::sym: FNV => Fx HashMike Gerwitz2020-02-244-60/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For strings of any notable length, Fx Hash outperforms FNV. Rustc also moved to this hash function and noticed performance improvements. Fortunately, as was accounted for in the design, this was a trivial switch. Here are some benchmarks to back up that claim: test hash_set::fnv::with_all_new_1000 ... bench: 133,096 ns/iter (+/- 1,430) test hash_set::fnv::with_all_new_1000_with_capacity ... bench: 82,591 ns/iter (+/- 592) test hash_set::fnv::with_all_new_rc_str_1000_baseline ... bench: 162,073 ns/iter (+/- 1,277) test hash_set::fnv::with_one_new_1000 ... bench: 37,334 ns/iter (+/- 256) test hash_set::fnv::with_one_new_rc_str_1000_baseline ... bench: 18,263 ns/iter (+/- 261) test hash_set::fx::with_all_new_1000 ... bench: 85,217 ns/iter (+/- 1,111) test hash_set::fx::with_all_new_1000_with_capacity ... bench: 59,383 ns/iter (+/- 752) test hash_set::fx::with_all_new_rc_str_1000_baseline ... bench: 98,802 ns/iter (+/- 1,117) test hash_set::fx::with_one_new_1000 ... bench: 42,484 ns/iter (+/- 1,239) test hash_set::fx::with_one_new_rc_str_1000_baseline ... bench: 15,000 ns/iter (+/- 233) test hash_set::with_all_new_1000 ... bench: 137,645 ns/iter (+/- 1,186) test hash_set::with_all_new_rc_str_1000_baseline ... bench: 163,129 ns/iter (+/- 1,725) test hash_set::with_one_new_1000 ... bench: 59,051 ns/iter (+/- 1,202) test hash_set::with_one_new_rc_str_1000_baseline ... bench: 37,986 ns/iter (+/- 771)
| * Makefile.am (clean): New targetMike Gerwitz2020-02-241-0/+3
| | | | | | | | Not sure how I missed this one.
| * tameld: Move documentation to tamer::ldMike Gerwitz2020-02-242-13/+32
| |
| * HashMapInterner: New interner, docs, and benchmarksMike Gerwitz2020-02-242-23/+473
| | | | | | | | | | This interner will be suitable for providing an index to look up nodes in the ASG.
| * TAMER: sym::tests: Generate with macroMike Gerwitz2020-02-241-9/+27
| | | | | | | | | | | | | | | | | | | | This will be used for generating the common tests between HashSet and HashMap implementations. This is my first macro in Rust. There does not seem to be a way to concatenate identifiers (!), so I'm placing them within modules instead. That ended up working out just fine, since then I can use a type to provide the SUT.
| * TAMER: Initial string interning abstractionMike Gerwitz2020-02-246-2/+910
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is missing two key things that I'll add shortly: a HashMap-based one for use in the ASG for node mapping, and an entry-based system for manipulations. This has been a nice start for exploring various aspects of Rust development, as well as conventions that I'd like to implement. In particular: - Robust documentation intended to guide people through learning the necessary material about the compiler, as well as related work to rationalize design decisions; - Benchmarks; - TDD; - And just getting used to Rust in general. I've beat this one to death, so I'll commit this and make smaller changes going forward to show how easily it can evolve. (This module was originally named `intern` but this commit and those that follow rewrote it to `sym`.)
| * Makefile.am (html-am): Run doc testsMike Gerwitz2020-02-241-0/+1
| | | | | | | | Ensure that we have good examples before generating docs.
| * Makefile.am (doc, html): Use intra_rustdoc_linksMike Gerwitz2020-02-243-1/+43
| | | | | | | | | | | | | | This is enabled by default in nightly, and is not available at all in stable. Considering the PITA that it will be to go back and rewrite docs to use the new format, and how important of a feature this is, we will just make use of it now.