anza-xyz / anza-xyz/platform-tools
r0 = 1 silently assembles to nothing on sbf-solana-solana instead of emitting an error
- Lenguaje dominante
- Shell
- Estrellas
- 87
- Forks
- 47
- Merge medio
- 9 d 25 min
- PR fusionados (30 d)
- 6
Descripción
## Problem
For the following assembly:
```asm
.globl entrypoint
entrypoint:
r0 = 0x1
exit
```
when assembled with:
```sh
clang -target sbf-solana-solana -c ...
```
the assembler does not report an error. Instead, the resulting object contains only the `exit` instruction, while `r0 = 0x1` is interpreted as a symbol assignment and ended up appearing in the `.symtab`.
For the sbpf target, `r0 = 0x1` is not valid syntax, so this input should be rejected rather than silently interpreted as a symbol assignment.
Although this syntax is supported by the bpf/llvm backend, sbpf is a specialized target with its own assembly syntax and constraints. So in this case the assembler should therefore explicitly diagnose this case as invalid input.
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Evaluación
Este issue todavía no se ha evaluado.