Commit Graph
65 Commits
Author SHA1 Message Date
Patrick Quist 07236628bb minimal ts conv of llvm-ir (#4477) 2022-12-24 19:45:47 +01:00
Matt Godbolt 57a647b8a3 Add the result inside the CompilationResult (#4475) 2022-12-20 08:15:39 -06:00
Matt Godbolt 6348917e15 Separate shareable tool type from server ITool (#4472)
* Separate shareable tool type from server ITool

I realised we were using the "Tool" on both client and server, but the client only has the JSON-able data of Tool, not the interface/object Tool (now renamed to `ITool`).

* Fix tests
2022-12-19 22:40:27 -06:00
Matt Godbolt cad5227756 Don't try and hack the compilation results (#4429)
* Don't try and hack the compilation results

Carbon tried to synthesize "having run" by overriding and hacking a result routine...but did so _after_ it had been cached. So cached results were broken, but live results not.

This "fixes" by adding a post-compilation, but pre-cache hook and uses that instead. Naming is terrible.

I also took the time to fix the `CompilationResult`'s `buildResult`

Closes #4426
2022-12-12 21:38:22 -06:00
Patrick Quist 67f71f2b51 Support patched clang for faster opt-view (#4416) 2022-12-10 18:17:51 +01:00
Jeremy Rifkin e7b10519f7 Tsify options-handler (#4396)
* First pass conversion of options-handler to ts

* Small tweaks

* Fix tests
2022-12-03 19:37:57 -05:00
Patrick Quist ae0fee1095 first bits of compiler interface (#4378) 2022-12-02 13:42:47 +01:00
Jeremy Rifkin 1294c3f949 Control flow graph tool rework (#3899)
* Removed old code

* Base functionality

* Work on edge offsets

* Setup interval trees for edges

* linter things

* Formatting

* Added syntax highlighting

* Cleanup and simplification. Improved handling of direct dropdown edges.

* Basic zoom/pan

* Remove old blocks from output

* Fix distance calculation

* Added function selector

* Improved zoom behavior

* figue 8 logic

* Canvas scaling / repainting, updated colors

* Don't truncate output, also removed some console.logs

* Tweak to zoom system

* Replaced canvas stuff with svg

* Experimenting with adding shadows to edges

* Removed shadows, was causing problems. Improved how blocks with lots of incident edges are handled.

* Slightly improved edge system

* some work on implementing segment priority system from cutter

* Optimization to rendering process. I was worried the graph layout algorithm was causing the page to hang but it turns out it was adding elements to the page with +=

* Removed need for storing the previous segment

* refactor, splitting up some logic

* Cleaned up logic and got horizontal edges working better

* Remove vis-network dependency

* Updated package-lock, removed @import vis-network css stuff, added a todo for myself

* Cleaned up notes and error messages. Added comments. Clear the pane if there's no function to display

* Added layout time information, implemented .resize

* Light theme

* State work and bug fix for dragiing

* Re-dading lost dark theme changes

* Added jquery import

* Cleaned up console.logs

* Added basic block count

* Incorporated PR review comments; Fixed cypress (hopefully), added documentation, improved the dropdown, and fixed dropdown items not being cleared with an empty result.cfg

* Ran format
2022-11-29 22:28:10 -05:00
Marc Poulhiès 2fa2bbb16a refactor: renames the CompilerFilters type (#4346)
The type which probably started as a real enum of possible post filtering
options now also includes options used for compilers' invocations.

The type was already split, but the naming was not reflecting this in the other
part of the code.

This changes tries to apply a simple renaming to the type only (corresponding
variables are left as 'filters').

While doing so, some typing error were discovered around the GccDump feature.
A fix for this will follow in a different PR.

Signed-off-by: Marc Poulhiès <dkm@kataplop.net>
2022-11-28 21:37:15 +01:00
Patrick Quist 189d445363 store compilationOptions so that we can debug buildsteps better (#4288) 2022-11-13 19:39:17 +01:00
Jeremy Rifkin 1b37402cd9 Added llvm opt pipeline timing info (#4284)
* Added llvm opt pipeline timing info

* Fix naming

* Tweak timing pane and use exec's timing if possible

* Added timing info for processExecutionResult
2022-11-12 11:37:47 -05:00
Patrick Quist 17a56af696 Bugfix Map usage (#4265) 2022-11-09 14:08:19 +01:00
Rubén Rincón Blanco e962c3ef8b Fix errorResponse return value (#4248) 2022-11-09 03:12:01 +01:00
Rubén Rincón Blanco c7cfda6a3f Add language tooltips (#4237) 2022-11-09 02:53:04 +01:00
Ofek db9b4f48b0 Add Hide metadata option to LLVM pipeline (#4243) 2022-11-06 12:22:47 -05:00
Patrick Quist 0212779a74 CC65 Binary + NES support (#4139) 2022-10-29 17:01:44 +02:00
Patrick Quist 1e0543fbbb Change auto-open device-view to only when there's device asm (#4202) 2022-10-25 23:11:49 +02:00
Paul Taylor 1476937e82 Add split host/device views for CUDA C++ (#4177)
* make nvcc show the device asm view button, stop after compiling host assembly
* keep and extract ptx device code
* paper over some typescript compile errors (maybe mitigating orchidjs/tom-select#500, orchidjs/tom-select#501)
* await on promise-returning methods
* use gcc objdump for nvcc host code, add nvdisasm to disassemble SASS .cubin
* append device ASM lines to result ASM so they're also colourized
* append device ASM to all ASM
* automatically open the device pane if the compiler supports emitting device ASM
* save device view open boolean in compiler state
* make the nvcc compiler return all PTX and SASS results as separate devices
* ensure line hover highlights propagate from editor to compiler panes, and are re-applied when the user changes the selected device
* update cuda properties
2022-10-24 20:28:01 -05:00
Matt Godbolt c5f50d603c Fix typing and usage of tools (#4180)
* Fix typing and usage of tools
* Fix tests and break cycle
* More improvements
2022-10-22 17:16:23 -05:00
ddafb32feb Try to fix main (#4173)
* Fix Editor not being able to load full links
* Better type for this.filename in compiler.ts
* Updates editor.ts and improves compilation types
* Fix some of the type issues, lots still remain
* fixes to language selection & refactoring of hub and some inits
* fix flow of events
* Fix llvm opt handling (cc @jeremy-rifkin)

Co-authored-by: partouf <partouf@gmail.com>
Co-authored-by: Matt Godbolt <matt@godbolt.org>
2022-10-22 13:59:51 -05:00
Rubén Rincón Blanco b25e443bbb Improve event-map types (#4135) 2022-10-10 13:39:18 +02:00
Romaric Jodin 72a19da538 asm-mode: better tokenization for spirv (#4024) 2022-10-10 13:02:50 +02:00
J. Ryan Stinnett 80dd763985 Add basic Racket support (#4098) 2022-10-05 09:32:45 +02:00
Fábio de Souza Villaça Medeiros c2e9aabfd7 Add basic support for Hook programming language (#4075)
* Add basic support for Hook programming language
2022-09-25 15:06:02 -05:00
Patrick QuistandRubén Rincón Blanco 8205573365 add compilationinfo and related types (#4051)
* add compilationinfo and related types

* fix mtime type

* Add rest of compiler keys

* Make it compile

* Rename Compiler type to CompilerInfo as per Partouf's suggestion

* Get ready for #4077

* Linter fixes

Co-authored-by: Rubén Rincón Blanco <ruben@rinconblanco.es>
2022-09-20 08:00:24 -05:00
Matt Godbolt a8a666aeac Fixes for cppfront (#4076)
* Rename cppx_cppfront to cpp2_cppfront
* Add some blurb about the compiler
* Some syntax highlighting
* Better output highlighting
* Some form of line tracking and filtering
2022-09-20 07:42:41 -05:00
Matt Godbolt cf2da5f9b3 cppfront (#4069) 2022-09-16 18:27:48 -05:00
Rubén Rincón Blanco 366cd5527c Adds llvm-cov tool (#4044) 2022-09-15 08:12:27 +02:00
Patrick Quist 8334d96bf3 tsify exec.js (#4026) 2022-09-06 20:22:28 +02:00
Patrick Quist 96e15d6630 Unbundle and disassemble device code (#4019) 2022-09-03 19:13:31 +02:00
Jeremy Rifkin 15007d3244 Refactored the LLVM Optimization Pipeline to provide better diagnostics, added timeout indication to exec.js (#4016) 2022-09-03 01:15:21 +02:00
Rubén Rincón Blanco 105b814acf Fixes wrong types in libraries.interfaces.ts (#3982)
* Fix getLibrary functions

* Fix library.path usage in Zig compiler
2022-08-25 21:45:59 +02:00
J. Ryan Stinnett 44aa191cad Add debug info filter option to LLVM opt pipeline viewer (#3987)
* Add debug info filter option to LLVM opt pipeline viewer

* Add MIR debug info pseudo-instructions to filters

* Use mixin for LLVM opt pipeline options

This fixes a few templating errors from the more verbose version.

* Add name to contributors

* Generalise dbg call filter
2022-08-24 20:16:48 -04:00
Rubén Rincón Blanco 16b176235a JBOF: Just a Bunch of Fixes (#3957)
- Renames orphancompiler.py script to propscheck.py, the name fits better
- Fixes Go props to make them easier to maintain
- Alphabetically sorts some listings in the code
- Adds tests to the props checker script (No idea how to integrate those so it's manual for now)
- Adds 2 missing limit cases for Motd filtering
2022-08-13 01:39:41 +02:00
Jeremy Ong d928bccf5a Add preliminary HLSL support (#3932)
* Add preliminary HLSL support

- Adds a new language mode to monaco, extending the base C++ layer with
  HLSL intrinsics and types
- Adds a new `HLSLCompiler` class
- Adds a sample pixel shader

The compiler used to test this locally is the [DirectX Shader
Compiler](https://github.com/microsoft/DirectXShaderCompiler) (aka DXC),
which needs to also be added to the
[infra](https://github.com/compiler-explorer/infra) project.

Some guidance is needed before this PR can be merged:

1. While DXC can run on Linux, there are no binaries available so this
   compiler must be built. Are there examples that show how we should do
   this as part of the infra CI/CD? Should we build and host it
   separately instead? The build process for DXC on Linux is relatively
   straightforward and documented
   [here](https://github.com/microsoft/DirectXShaderCompiler/blob/main/docs/DxcOnUnix.rst).
2. The example code doesn't compile unless the user also supplies
   additional compiler flags `-T ps_6_6 -E PSMain`. Is there a way to
   load these flags conditionally only if the sample is loaded?
3. Technically, DXC emits DXIL IR (based on LLVM IR) and I am wondering
   if it's possible to extend an existing LLVM backend. In addition, the
   `-spirv` compiler flag could be emitted to target the SPIR-V backend
   instead, so I'm curious if there is a good way to express the target
   backend.

Signed-off-by: Jeremy Ong <jeremycong@gmail.com>

* Fix copyright dates, remove unnecessary strict usage, and remove
placeholder logo

Signed-off-by: Jeremy Ong <jeremycong@gmail.com>

* Rebase and remove unneeded HLSL logo

Signed-off-by: Jeremy Ong <jeremycong@gmail.com>

* Fix lint errors

Signed-off-by: Jeremy Ong <jeremycong@gmail.com>

* Simply HLSL sample and remove default config

Signed-off-by: Jeremy Ong <jeremycong@gmail.com>
2022-08-09 07:32:19 -05:00
Rubén Rincón Blanco c8ce581266 Makes language logo optional in all cases (#3934) 2022-08-04 10:26:18 +02:00
Mike UrbachandPatrick Quist 16b06027f5 Add basic CIRCT compiler support. (#3917)
* Add basic CIRCT compiler support.

This adds basic support for CIRCT as requested in #3825. The addition
is based on the similar additions for MLIR in #3733 and #3770.

* Update path and rename compiler in circt.amazon.properties.

* Update circt.amazon.properties

Co-authored-by: Patrick Quist <partouf@gmail.com>
2022-07-28 23:29:10 +02:00
Fred TingaudandRubén Rincón Blanco ea3b66df11 Add possibility for tools to generate an artifact (#3893)
* Add possibility for tools to generate an artifact

* Add button to download the artifact instead of downloading it automatically.

* Add better description on artifact button.

* Apply recommendations

* Update static/panes/tool.js

Co-authored-by: Rubén Rincón Blanco <ruben@rinconblanco.es>

* Use a download icon rather than save

* Introduce correct type for artifact.

Co-authored-by: Rubén Rincón Blanco <ruben@rinconblanco.es>
2022-07-28 09:57:03 -05:00
Fred Tingaud 96326148e7 Introduce quick-fixes. (#3895) 2022-07-26 17:18:09 +02:00
Fred Tingaud 2e0c8c140a Add a concept of flow on ResultLines. (#3854) 2022-07-20 20:20:56 +02:00
Matt Godbolt 50a1eedf01 Add support for Carbon (#3885)
Add support for the Carbon language prototype.
2022-07-19 09:42:25 -05:00
Christopher Smyth a5c45b6f0b Pony Lang Config (#3855) 2022-07-10 21:58:19 +02:00
TrMen ed4c5814ae Add the jakt programming language (#3845) 2022-07-09 17:03:23 +02:00
Fred Tingaud b0135723bc Make it possible to display a URL in marker tooltips. (#3828) 2022-07-05 23:56:37 +01:00
Jeremy Rifkin edf3fadfe5 Add -fno-discard-value-names support for the llvm opt viewer (#3836)
* Added -fno-discard-value-names support for the llvm opt viewer

* Added -Z fewer-names=no for rustc
2022-07-04 11:32:21 -04:00
Fred Tingaud a513bfd780 Add a way to trigger model markers on a range instead of a single token. (#3826) 2022-07-01 07:34:25 -05:00
Jeremy Rifkin ed1a4e6b27 LLVM Optimization Pass Viewer (#3769) 2022-07-01 01:53:02 +02:00
Fred Tingaud 02ef879986 Move severity parsing with the rest of the output parsing. (#3821) 2022-07-01 00:30:57 +02:00
Patrick Quist 5452166ae1 Toit (#3808) 2022-06-24 22:07:40 +02:00
partouf 8a0a77d2b6 format 2022-06-24 14:19:24 +02:00