Commit Graph
34 Commits
Author SHA1 Message Date
Marc Poulhiès 24693766d0 rust: HIR dump and small refactor with macro expansion (#3147)
Small refactoring for handling -Zunpretty calls:

- reuse options from main compiler invocation instead of crafting new ones.
- factor out common part.

Now also handles HIR output in a dedicated pane.
Still a lot of copy/pasting from the macro expansion.

fixes #2567

Signed-off-by: Marc Poulhiès <dkm@kataplop.net>
2021-12-05 19:04:12 +01:00
Marc Poulhiès 8a6701f3a1 Fix and refactor rustc-cg-gcc GCC dump (#3128)
Conflicting changes in #3109 and #3064 left the GCC dump of rustc broken.

Reapplied the changes and refactored how the -fdump-foo-pass= option is crafted.
Instead of using stdout, use an explicit file. Beware that this won't work with
older GCC version. Regular GCC is still using the 'dump all files' instead of
the targeted option, so it's not impacted by this limitation. Only rustc-cg-gcc
is currently using this mecanism and it's using a recent libgccjit.

Really fixes #2868

Signed-off-by: Marc Poulhiès <dkm@kataplop.net>
2021-11-22 00:08:02 +01:00
Marc PoulhièsandNico Lehmann 20ebcf7417 Honour rustc flags when emitting MIR and emit both assembly and MIR in the same execution (#3116)
* Honor compiler flags in rustc MIR output view

* Refactor rustc/MIR execution handling

Apply the same receipe as for GNAT and GCC for minimizing the number of
executions for getting extra outputs (here MIR).

After discussions in #3107, the way the output files are created is also
changed to use the syntax `--emit KIND=PATH` (see
https://doc.bccnsoft.com/docs/rust-1.36.0-docs-html/rustc/command-line-arguments.html)

Signed-off-by: Marc Poulhiès <dkm@kataplop.net>

* fixup! Refactor rustc/MIR execution handling

Co-authored-by: Nico Lehmann <nico.lehmannm@gmail.com>
2021-11-21 14:15:30 +01:00
Mats Larsen 278d28b313 Add rustc Macro Expansion view (#2932)
Adds a new pane for producing the macro expansion of Rust code compiled with rustc.
2021-09-27 00:33:09 +02:00
Mats Larsen aa431e1336 Add rustc MIR output view (#2795)
* Add Rustc MIR representation view
* Enable MIR view for rust-cg-gcc
2021-07-24 10:56:06 -05:00
Rubén Rincón Blanco 27012bb0ec Initial sketch for how we could parse Rust output (#2761)
* Initial sketch for how we could parse Rust output

It has many issues, which I need to ask about, but ey, it works!

* Fix spacing

* Add tests for the new Rust output parsing
2021-07-06 05:21:31 +02:00
Matt Godbolt f68198af9e Reassign copyright to Compiler Explorer Authors (#2233) 2020-09-26 17:50:40 -05:00
Austin Morton 044dcfbf88 Use ES6 Modules (#2132) 2020-09-26 16:59:26 -04:00
Austin Morton bac07fea6d Eliminate all dynamic require statements (#2230) 2020-09-25 11:21:30 -04:00
Rubén Rincón BlancoandAustin Morton ccff4b9ee5 Add new eslint rules (#2121)
The largest changes here are:
- enforcing single quotes for strings
- enforcing trailing commas where possible

In addition to those we have enabled several eslint plugins:
- plugin:requirejs/recommended, to enforce some conventions in require statements
- plugin:node/recommended, to enforce correct usage of various node.js APIs
- plugin:unicorn/recommended, which contains a pretty mixed bag of useful rules

This PR attempts to not change code behavior when possible.  In cases where fixing
existing code would change semantics, a linting exclusion has been placed in the 
code base to silence the error.  You can find these by searching for `eslint-disable-next-line`.

Co-authored-by: Austin Morton <austinpmorton@gmail.com>
2020-08-04 16:39:02 -04:00
Matt Godbolt 263ff0ed72 Support binary in rust.
Closes #509
2020-05-28 23:11:03 -05:00
Partouf 41f696489d fix #1552 2019-08-25 16:26:35 +02:00
Partouf fb286bd306 add custom argument parser for rust 2019-08-08 17:19:20 +02:00
Andreas Jonson 3b9e566121 Add LLVM IR view for Rust
closes #497
2019-05-20 08:17:35 +02:00
Partouf 38d004a187 Merge remote-tracking branch 'matt/master' into compilerargs 2019-01-10 23:55:04 +01:00
Kārlis Seņko 1986a80691 Enable cfg for x86 LLVM based compilers and gcc. 2019-01-09 23:04:14 +02:00
Partouf e892d3506f change argument parser for some compilers 2019-01-08 03:20:30 +01:00
RabsRincon 7c18ffe8cf Drop underscore-node in favour of underscore.js
After some suprises about how outdated the node version was compared to
	the main project, it became clear we needed to do something.
	@jaredwy suggested using the main project as there's now nothing
	stopping us from using it after the switch to webpack.

cc @mattgodbolDrop underscore-node in favour of underscore.js
2018-06-15 15:04:55 +02:00
RabsRincon 6ef87b5ef9 Fix copyright dates and normalize text 2018-02-27 14:58:21 +01:00
Partouf 457a6f5346 compiler handler calls initialise() 2018-01-28 00:46:44 +01:00
Partouf 9a76e777a7 remove return initialise, no need for unittestmode 2018-01-28 00:34:05 +01:00
RabsRincon d493dfb7cc Format code 2018-01-18 19:46:02 +01:00
RabsRincon a54faefb4c ES6fy compilers inheritance 2018-01-18 19:43:10 +01:00
RabsRincon fc75208dac New year, new date 2018-01-01 16:44:04 +01:00
Matt Godbolt d085bac708 Remove explicit langid, as it's part of the compiler config already 2017-12-22 08:01:33 -06:00
RabsRincon 63ed0e79c5 Change enough stuff as to get it running
Not saying it works, but if you hack few more things, you can start
	to use it. Commiting just in case
2017-12-02 04:01:12 +01:00
jaredwy 573ff1027f Allow options for filters to look at useroptions this allows us to add/remove options per compiler such as for rust where we need to not add the --emit argument if the user has passed us one 2017-09-01 19:46:27 +10:00
Matt Godbolt b6e9a4658b Another year, another copyright update 2017-01-02 10:14:46 -06:00
Matt Godbolt c4411ff2a1 Use -C debuglevel=1 to maybe mitigate #79 2016-12-23 14:58:38 -06:00
Matt Godbolt 8ca2b36d5e Intel fixes for rust 2016-12-19 21:16:37 -06:00
Matt Godbolt 4839c9f5e6 More fixes 2016-12-19 20:55:32 -06:00
Matt Godbolt d37dc97844 More rust fixes; should address #139 2016-12-19 20:49:32 -06:00
Matt Godbolt c82915e374 Fix rust (maybe) 2016-12-19 20:35:02 -06:00
Matt Godbolt 7990e42f7c Refactor individual compilation types into their own files 2016-12-19 18:01:27 -06:00