sd:llvm_backend_for_sd-8516
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| sd:llvm_backend_for_sd-8516 [2026/06/11 02:53] – appledog | sd:llvm_backend_for_sd-8516 [2026/06/18 05:31] (current) – appledog | ||
|---|---|---|---|
| Line 36: | Line 36: | ||
| * [[Notes to Self from June]] | * [[Notes to Self from June]] | ||
| + | * [[Runtime Library Notes]] | ||
| + | |||
| + | === Truncating i8 stores | ||
| + | Truncating stores for i8-- STAL for char. | ||
| + | |||
| + | "If it's legal, keep it legal" says reflect what the hardware actually does and skip the legalizer' | ||
| + | |||
| + | In the end it emits STAL [ptr] either way. | ||
| + | |||
| + | === Marking things SR | ||
| + | Marking things SR does not protect against all stages of LLVM lowering. Sometimes disparate parts try to insert things between CMP and Bcc/Jcc. The solution is to fuse them in the backend. Ask yourself, does a branch instruction that relies on a CMP EVER //need// anything between the CMP and the branch? If so, since the branch is guaranteed, why not move the code into the branch? | ||
| + | |||
| + | == Meeting LLVM halfway | ||
| + | There are a lot of 'easy fixes' such as adding a LEA style instruction, | ||
| + | |||
| + | This is a hidden issue regarding C, compilers, and CPUs. The CPU has, for a long time, adapted to C. As C has adapted to the CPU. It's a symbiosis. But C won't last forever and maybe there are better ways to do things. If VAX can ship an __insque() maybe insque should be standard? | ||
| + | |||
| + | Not everything is a lowest common denominator. That's bland. C, or some language else, should be able to reflect upon what makes a CPU special and unique. That's part of the joy of assembly; exploring truly new mindscapes of architecture. Realizing why certain ideas work better than others considering the hardware. | ||
sd/llvm_backend_for_sd-8516.1781146396.txt.gz · Last modified: by appledog
