Files
fghzxm 0989427c12 asm-parser: Recognize more dataDefn directives (#5535)
This patch adds more data definition directives to be recognized by
`AsmParser` in lib/parsers/asm-parser.ts.

Fixes #5489, as well as inappropriate filtering of `.double` directives
in test/filter-cases/diab.asm which is similar to #5489.

The list of data directives are taken from the "Assembler Directives"
chapter of the [GNU `as` manual][as]. Directives added by this patch
are:

- `.dc[size]`
- `.dcb[size]`
- `.ds[size]`
- `.double`
- `.fill`
- `.float`
- `.int`
- `.single`
- `.skip`
- `.space`
- `.string8`, `.string16`, `.string32`, `.string64`

The `.space` directive is not a data directive when assembling for the
HPPA architecture; this must be fixed if HPPA support is to be added to
Compiler Explorer.

Some of the directives such as `.string64` are pretty unlikely to be
emitted by actual compilers, but we add them because it can't break
existing input (no `as`-compatible compiler can use them as non-data
directives), and will futureproof us against future compilers that do
emit them.

Architecture-specific directives documented in the "Machine Dependent
Features" chapter are not added in this patch, even though it may be
better to add some of them (such as `.stringz`) as well. Existing
directives that are not found on the "Assembler Directives" list are not
removed.

`.sleb128` and `.uleb128` are technically data directives, but aren't
added because we assume they're only used in debuginfo.

[as]: https://sourceware.org/binutils/docs-2.41/as/index.html

<!-- 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-10-05 07:32:04 -05:00
..
2023-06-18 15:59:59 -04:00
2023-07-23 13:39:31 -05:00
2023-07-10 20:38:55 -05:00
2023-08-15 22:16:36 -05:00
2023-07-10 21:31:04 -05:00
2023-05-17 15:24:01 -04:00
2023-06-06 21:17:25 -05:00
2023-03-11 14:18:04 -06:00
2022-12-14 20:44:26 -06:00
2023-08-15 22:16:36 -05:00
2023-05-16 03:53:57 +02:00