Skip to content

[Flang][Docs] Fix lexer issue in Driver and Trampoline doc #72322

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions flang/docs/FlangDriver.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,15 @@ Note that similarly to `-Xclang` in `clang`, you can use `-Xflang` to forward a
frontend specific flag from the _compiler_ directly to the _frontend_ driver,
e.g.:

```lang=bash
```bash
flang-new -Xflang -fdebug-dump-parse-tree input.f95
```

In the invocation above, `-fdebug-dump-parse-tree` is forwarded to `flang-new
-fc1`. Without the forwarding flag, `-Xflang`, you would see the following
warning:

```lang=bash
```bash
flang-new: warning: argument unused during compilation:
```

Expand Down
12 changes: 6 additions & 6 deletions flang/docs/InternalProcedureTrampolines.md
Original file line number Diff line number Diff line change
Expand Up @@ -170,15 +170,15 @@ as an actual argument to `foo()`.

The trampoline has the following structure:

```assembly
```asm
callee_trampoline:
MOV <static-chain-address>, R#
JMP <callee-address>
Comment on lines -175 to -176
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There was a warning without this change.

MOV static-chain-address, R#
JMP callee-address
```

Where:
- `<callee-address>` is the address of function `callee()`.
- `<static-chain-address>` - the address of the static chain
- `callee-address` is the address of function `callee()`.
- `static-chain-address` - the address of the static chain
object created inside `host()`.
- `R#` is a target specific register.

Expand Down Expand Up @@ -249,7 +249,7 @@ One of the options is to use separate allocations for the trampoline code
and the trampoline "data".

The trampolines may be located in non-writeable executable memory:
```assembly
```asm
trampoline0:
MOV (TDATA[0].static_chain_address), R#
JMP (TDATA[0].callee_address)
Expand Down