Commit Graph
32 Commits
Author SHA1 Message Date
Jacob Panov 534e1428fa Update AVR instruction documentation for 2024 manual (#7947) 2025-07-27 13:53:03 +02:00
Rupert Tombs afccba613e Quash some warnings in tests (#7415)
- Prevent some warnings in the `test-and-deploy` action; see, for
example, `Run checks` at
https://github.com/compiler-explorer/compiler-explorer/actions/runs/13421609790/job/37495341332:
  - Await a result to avoid:
```text
Promise returned by `expect(actual).toMatchFileSnapshot(expected)` was not awaited. Vitest currently auto-awaits hanging assertions at the end of the test, but this will cause the test to fail in Vitest 3. Please remember to await the assertion.
    at it.timeout(/home/runner/work/compiler-explorer/compiler-explorer/test/filter-tests.ts:91:50)
```
- Remove duplicated `AVRrc` entries in
`lib/asm-docs/generated/asm-docs-avr.ts`. `AVRrc` is a [reduced core
AVR](https://ww1.microchip.com/downloads/en/DeviceDoc/AVR-InstructionSet-Manual-DS40002198.pdf#page=18),
not an opcode. This avoids a warning beginning `[vite] warning: This
case clause will never be evaluated because it duplicates an earlier
case clause`.
    - Update generator script to also filter `AVRe`.
- Deduplicate `RLDICL` in `lib/asm-docs/generated/asm-docs-power.ts`.
IBM document this instruction both
[here](https://www.ibm.com/docs/en/aix/7.3?topic=is-rldicl-rotate-left-double-word-immediate-then-clear-left-instruction)
and
[here](https://www.ibm.com/docs/en/aix/7.3?topic=is-rldicl-rotate-left-double-word-immediate-then-clear-left-instruction-1).
I choose the neater-looking one, which is also more similar to their
[`RLDICR`](https://www.ibm.com/docs/en/aix/7.3?topic=is-rldicr-rotate-left-double-word-immediate-then-clear-right-instruction)
documentation. This avoids warnings beginning `[vite] warning: This case
clause will never be evaluated because it duplicates an earlier case
clause`.
2025-02-24 10:05:31 -06:00
Stephen HeumannandMatt Godbolt 5a72fa0659 Add support for ORCA/C (#7368)
[ORCA/C](https://github.com/byteworksinc/ORCA-C) is a C compiler that
natively runs on and targets the Apple IIGS. ORCA/C and the programs it
generates can be run on modern Linux systems by using an emulation tool
called [Golden Gate](https://goldengate.gitlab.io).

This adds support for ORCA/C (run via Golden Gate) in Compiler Explorer.
It uses its own assembly format and objdumper (provided by Golden Gate),
so support for those is added. An extra configuration option was also
added to support execution via an emulator, bypassing the usual check
that executables can run natively. Asm docs for the WDC 65C816 processor
were also added.

ORCA/C and Golden Gate are not Free Software, but their rights holders
have given permission for them to be used on Compiler Explorer. Tarballs
for them can be supplied privately. See infra PR:
compiler-explorer/infra#1521

---------

Co-authored-by: Matt Godbolt <matt@godbolt.org>
2025-02-18 10:28:10 -06:00
Mats Jun Larsen 5eea63328f Migrate to Biome for linting and formatting (#7033) 2025-02-02 17:54:31 +00:00
Mats Jun Larsen d9093faf18 Replace ts-node with tsx (#7205)
Migrates tooling to TSX (as advised by nodejs) until we are on Node 22
where we can `--watch --experimental-strip-types`
2024-12-10 00:18:46 +09:00
Matt Godbolt 0d2fc74419 Deduplicate ARM opcodes (#7067)
Prevents us generating duplicate case statements, though this doesn't
mean we correctly collate things. This has no functional change (as the
duplicate switches the first one wins) but reduces the amount of code
generated.
2024-11-05 07:31:20 -06:00
Ofek 93f75efc55 Update nvidia docenizer and docs (#6952)
<!-- THIS COMMENT IS INVISIBLE IN THE FINAL PR, BUT FEEL FREE TO REMOVE
IT
Thanks for taking the time to improve CE. We really appreciate it.
Before opening the PR, please make sure that the tests & linter pass
their checks,
  by running `make check`.
In the best case scenario, you are also adding tests to back up your
changes,
  but don't sweat it if you don't. We can discuss them at a later date.
Feel free to append your name to the CONTRIBUTORS.md file
Thanks again, we really appreciate this!
-->
2024-10-16 18:11:54 +03:00
Ofek f3b14d1e1b Small build/docz fixes (#6951)
<!-- THIS COMMENT IS INVISIBLE IN THE FINAL PR, BUT FEEL FREE TO REMOVE
IT
Thanks for taking the time to improve CE. We really appreciate it.
Before opening the PR, please make sure that the tests & linter pass
their checks,
  by running `make check`.
In the best case scenario, you are also adding tests to back up your
changes,
  but don't sweat it if you don't. We can discuss them at a later date.
Feel free to append your name to the CONTRIBUTORS.md file
Thanks again, we really appreciate this!
-->
2024-10-09 23:12:09 +03:00
Ofek 9dd45914aa Tooltips for llvm ir (#6937)
The docenizer was there - just needed some updating.

There is some duplicity created between `ir-view` and `compiler` that I
hope to address in a future PR.
2024-10-07 08:37:10 +03:00
Jan KühleandMatt Godbolt f4619aa8c6 Update Python asm docs (#6903)
When playing with Python 3.12 in the compiler explorer, I noticed some
instructions don't have documentation. I think that's true for new
instructions in 3.12. This PR updates the asm docs and the docenizer.

Update Python docenizer to handle new dis.html formatting:

- The JUMP bytecode has no description (i.e. no `<p>` elements).

- Docs now often include code snippets in `<code>` or `<pre>` tags.
Sanitize HTML but keep some known tags.

- Exit when failing to parse dis.html rather than emitting new file
without any instructions.

- Fix check for existing dis.html file.

Not sure if HTML markup is desired. It feels easier to read to me. But
I'm happy to revert that, too.

Docs updated using:

./etc/scripts/docenizers/docenizer-python.py -o
lib/asm-docs/generated/asm-docs-python.ts

---

Here's a preview:

| Before | After |
| --- | --- |
|
![image](https://github.com/user-attachments/assets/b1ae4c5e-5854-46e5-8f36-4e692566d85d)
|
![image](https://github.com/user-attachments/assets/278d4e34-377f-4301-b7e2-01226c14ddc3)
|


---

`make check` passes. But I had to commit using `--no-verify`. The
precommit hook failed on line-files with one warning:

```
/usr/local/google/home/jankuehle/Code/compiler-explorer/lib/asm-docs/generated/asm-docs-python.ts
  0:0  warning  File ignored because of a matching ignore pattern. Use "--no-ignore" to override
```



<!-- THIS COMMENT IS INVISIBLE IN THE FINAL PR, BUT FEEL FREE TO REMOVE
IT
Thanks for taking the time to improve CE. We really appreciate it.
Before opening the PR, please make sure that the tests & linter pass
their checks,
  by running `make check`.
In the best case scenario, you are also adding tests to back up your
changes,
  but don't sweat it if you don't. We can discuss them at a later date.
Feel free to append your name to the CONTRIBUTORS.md file
Thanks again, we really appreciate this!
-->

Co-authored-by: Matt Godbolt <matt@godbolt.org>
2024-09-30 22:11:04 -05:00
Nicholas Hubbard a9257430f3 Add assembly documentation for PowerPC platform (#6665)
<!-- THIS COMMENT IS INVISIBLE IN THE FINAL PR, BUT FEEL FREE TO REMOVE
IT
Thanks for taking the time to improve CE. We really appreciate it.
Before opening the PR, please make sure that the tests & linter pass
their checks,
  by running `make check`.
In the best case scenario, you are also adding tests to back up your
changes,
  but don't sweat it if you don't. We can discuss them at a later date.
Feel free to append your name to the CONTRIBUTORS.md file
Thanks again, we really appreciate this!
-->

Hello all, I've added assembly documentation for the PowerPC platform
with this PR.

There's a couple of notes to keep in mind, mostly regarding automatic
processing:

1. Unfortunately, IBM made their documentation site very difficult to
automatically scrape. It uses dynamic rendering with a documentation API
that's protected by cookies, requiring the use of Selenium to scrape it.
2. While it is possible to scrape the documentation pages, it's
maddeningly difficult to do so, because the structure of the pages is
not guaranteed.
- Some pages have invisible elements in their headers that make matching
elements very difficult.
     - Some pages are missing entire sections.
- Some pages are written without an introduction for the instruction
mnemonic, making the resulting documentation impossible to understand.
- Some pages, specifically for instructions without arguments, are
missing the table that lists the mnemonics out in order.
- I could go on, but I abandoned trying to do automatic processing after
running into this many roadblocks.
3. The automatic processing script is available in the docenizers
directory, but since it's not complete, feel free to ask to remove it.
4. I couldn't test the actual mnemonics appearing the editor, because my
local test setup kept trying to map the PowerPC instructions into AMD64
documentation, with predictably unusual results.
5. I didn't include AltiVec instructions, because there isn't any
webpage that documents them; they are only documented in a PDF file
provided by NXP.

Please let me know if there's anything else I need to do for this to
work. Thank you so much for your wonderful service!
2024-07-01 14:52:10 +02:00
standstaff 45ef23c940 chore: remove repetitive words (#6247)
<!-- THIS COMMENT IS INVISIBLE IN THE FINAL PR, BUT FEEL FREE TO REMOVE
IT
Thanks for taking the time to improve CE. We really appreciate it.
Before opening the PR, please make sure that the tests & linter pass
their checks,
  by running `make check`.
In the best case scenario, you are also adding tests to back up your
changes,
  but don't sweat it if you don't. We can discuss them at a later date.
Feel free to append your name to the CONTRIBUTORS.md file
Thanks again, we really appreciate this!
-->

Signed-off-by: standstaff <zhengxingru@yeah.net>
2024-03-16 09:22:15 +02:00
Phil @ RISC-V Embedded Blog "Five Embeddev fcb8513f7f RISCV64 assembly opcode documentation - update (#5598) 2023-11-07 14:52:43 +01:00
Matt Godbolt 5d776aaae3 Replace ts-node-esm with direct calls to node to support node 20 (#5521)
- works both v18 and v20
- see https://github.com/TypeStrong/ts-node/issues/1997
2023-09-27 21:57:18 -05:00
Jeremy Rifkin 42ea9cc128 General work on solidifying the instruction set system (#5156)
Mainly type work
2023-06-17 19:41:26 -04:00
Guo Ci 79bba4c1d1 Add PTX and SASS docs (#5129)
For CUDA C++, add PTX and SASS docs.
2023-06-11 17:00:38 -04:00
Jeremy d9d6307f60 Fix docenizer makefile and committing changes from regenerating the docs 2023-06-03 01:28:22 -04:00
Matt Godbolt beec3b51d4 Refactor; rename arm64 to aarch64 2023-05-30 21:06:54 -05:00
Serval Martinot-Lagarde b904ddf48a asm-docs: Add arm64 and update arm32 documentations 2023-05-08 11:40:23 +02:00
Mats Jun LarsenandMatt Godbolt 633eb82d18 Transition to ECMAScript Modules (#4780)
Makes the Compiler Explorer app, and all the tooling ESM compatible.
Things that have been done:

1. The package.json has `type: module` now
2. All relative imports have a .js ending
3. All directory imports are now directory/index.js to comply with ESM
standards
4. Dependency node-graceful is now imported into tree, because the
package is broken under esm
5. Dependency p-queue has been bumped to 7.x with ESM support
6. Dependency profanities has been bumped to 3.x with ESM support
7. Webpack config is now both ESM and CommonJS compatible
8. Non-ESM compatible imports have been rewritten
9. ESLint configuration has been tweaked to not fail on .js imports
10. Mocha is now hacked together and ran with ts-node-esm
11. Webpack is now hacked together and ran with ts-node-esm
12. Webpack config is now ESM compatible, so that it can be used in the
dev server
13. Cypress code still runs commonjs, and has been excluded from the
tsconfig
14. All sinon mock tests have been commented out, because sinon module
mocks do not work with ESModules (because ESModules are immutable)

A lot of tests are now giving warnings/errors to stdout, yet still pass.
Docenizer codegenerator scripts have been updated, but I did not re-run
them, and instead just changed their code.

---------

Co-authored-by: Matt Godbolt <matt@godbolt.org>
2023-02-27 18:06:38 -06:00
Jeremy Rifkin f801481582 Tsify the java docenizer (#4710)
<!-- THIS COMMENT IS INVISIBLE IN THE FINAL PR, BUT FEEL FREE TO REMOVE
IT
Thanks for taking the time to improve CE. We really appreciate it.
Before opening the PR, please make sure that the tests & linter pass
their checks,
  by running `make check`.
In the best case scenario, you are also adding tests to back up your
changes,
  but don't sweat it if you don't. We can discuss them at a later date.
Feel free to append your name to the CONTRIBUTORS.md file
Thanks again, we really appreciate this!
-->
2023-02-10 14:10:53 -05:00
Jeremy Rifkin 4a1b5a85c5 Add make asm-docs (#4590) 2023-01-16 19:46:26 -05:00
谭九鼎 b0de7de3e9 chore: use https for links (#4532) 2023-01-13 10:49:07 -05:00
谭九鼎 02060bddfe update some py scripts (#4533) 2023-01-09 07:34:03 -06:00
Jeremy Rifkin 836a2d7005 Tsify generated asm docs (#4388)
* Converted amd64 docs to ts

* 6502

* 6502 part 2

* arm

* avr

* evm

* java

* llvm

* python

* Fix bug with only getting the first paragraph

* Updated help messages
2022-12-02 14:36:10 -05:00
Jeremy Rifkin 2e844e9ef5 Make docenizer naming more consistent (#4387) 2022-12-02 12:16:42 -05:00
marcosmartinezfco fcb7683019 Add support for evm opcode documentation (#4319) 2022-11-21 17:16:15 +01:00
Rubén Rincón Blanco 61ff341caf Add Python instruction docs (#4290) 2022-11-16 00:51:37 +01:00
Mats Larsen ad5ece867a Bump jvms version to 18 and fix find-node path (#4192)
* fix: bump jvms version to 18 and fix find-node path
2022-10-24 20:28:55 -05:00
Mats Larsen a1d6f453e3 Assembly documentation for LLVM IR (#3737) 2022-05-31 14:47:48 +02:00
Jeremy Rifkin 16b071b9f0 Updated x86 docenizer to read adjacent tables (#3541)
* Updated x86 docenizer to read adjacent tables

* Added regression test
2022-04-23 22:04:09 +02:00
Rubén Rincón Blanco 48eee26d2c Group some files to their own folders (#3384)
* Group some files to their own folders

In etc/scripts/, added disasms/, docenizers/, and util/ folders
In lib/, added mapfiles/, and parsers/ folders (+moved google.js to
shortener)
In static/, added widgets/ folder

Added cypress folder to .gitignore

* Address Matt's PR reviews

* Move new Pane renaming to folder
2022-02-22 00:18:21 +01:00