Fixes#8536.
Adds a new **Compile** option to the *Ctrl+S behaviour* selector in
Settings (alongside the existing Save / Short Link / Reformat / Do
nothing options).
When selected, Ctrl+S behaves identically to Ctrl+Enter: it calls
`maybeEmitChange()` and, if compile-on-change is disabled, explicitly
fires `requestCompilation`.
*(I'm Molty, an AI assistant acting on behalf of @mattgodbolt)*
---------
Co-authored-by: mattgodbolt-molty <mattgodbolt-molty@users.noreply.github.com>
Recent compilers do not allow parametric functions to be exported, so
remove the keyword. Note that this means the function now gets inlined
with default optimization levels.
## Summary
- Fixes the property parser regex to allow `+` in key names (e.g.
`abc+def=etc`)
- The regex from #8387 used `[^=+]+` for key matching, which excluded
`+` from key names entirely
- Changed to a lazy `.+?` match so `+` is only treated as the `+=`
operator when immediately before `=`
This is a small targeted fix and does not address all edge cases with
the `+=` syntax.
## Test plan
- [x] Added test: `abc+def=etc` correctly sets key `abc+def` to `etc`
- [x] Added test: `abc=def+ghi` correctly sets key `abc` to `def+ghi`
- [x] All existing `+=` append tests continue to pass
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
The `links` field in `ParsedAsmResultLine` and the `AsmResultLink` type
have been unused since 2019 when clickable address links were replaced
by the labels system. This just removes the dead code.
Closes#8251
Fixes#8273
The default NASM output format was `elf` (32-bit ELF), causing a
spurious `64-bit unsigned relocation zero-extended from 32 bits
[-w+zext-reloc]` warning when using 64-bit addressing (which is the
common case on CE's x86-64 infrastructure).
Changed the default to `elf64`. Users who explicitly need 32-bit ELF
output can still pass `-felf` to override.
*(I'm Molty, an AI assistant acting on behalf of @mattgodbolt)*
Co-authored-by: mattgodbolt-molty <mattgodbolt-molty@users.noreply.github.com>
*(I'm Molty, an AI assistant acting on behalf of @mattgodbolt)*
Closes#5178
## Problem
NVCC embeds the CUDA fat binary blob in the host-side x86 assembly
inside a `#APP`/`#NO_APP` inline-assembly block, under a label called
`fatbinData`. In a realistic kernel this can be 100+ lines of `.quad`
hex values — a wall of noise before any user-readable code.
Example: https://godbolt.org/z/W3YMcq8oY
## Fix
Per-compiler pre-processing step in `NvccCompiler.processAsm()`: before
the host assembly reaches the ASM parser, any `#APP`/`#NO_APP` block
containing a `.nv_fatbin` section is stripped out entirely.
- Only `.nv_fatbin` blocks are removed; genuine user inline-assembly
blocks (which also use `#APP`/`#NO_APP` but without `.nv_fatbin`) are
left intact.
- Intentionally NVCC-specific — no changes to the base `AsmParser`, no
false-positive risk for other compilers.
- Stripping happens before `findUsedLabels` runs, so `fatbinData`
naturally disappears as unreferenced without any special-casing in the
parser's label-filtering logic.
- Gated on the existing Labels filter: with no filters active everything
remains visible; with Labels on the blob disappears.
## Testing
**New compiler unit tests** (`test/compilers/nvcc-tests.ts`):
- Strips `#APP`/`#NO_APP` blocks containing `.nv_fatbin`
- Preserves `#APP`/`#NO_APP` blocks without `.nv_fatbin` (user inline
asm)
- Handles multiple mixed blocks correctly
- No-op when no `#APP` blocks present
- Gracefully handles malformed unclosed blocks
**New parser filter-case**
(`test/filters-cases/nvcc-x86-host-example.asm`): representative NVCC
12.0 host assembly (real 15-line fat binary, boilerplate functions,
`.nvFatBinSegment` section) with nine filter-combination snapshots
documenting parser behaviour in isolation. These correctly show that the
**base parser itself does not filter `fatbinData`** — that's the
compiler pre-processor's job.
All 767 tests pass.
Co-authored-by: mattgodbolt-molty <mattgodbolt-molty@users.noreply.github.com>
Closes#6319Closes#6320
Adds two new opt-in filter checkboxes to the LLVM IR view's **Filters**
dropdown:
### Hide Declarations (off by default)
Filters external function declaration lines (lines starting with
`declare`). These are forward declarations of external functions and are
often noise when focusing on user code.
**Off by default** — as noted in #6319, `declare` lines are part of
valid IR and are needed when copying output into other tools such as
`opt`, `llc`, `alive2`, etc.
### Hide Library Functions (off by default)
Filters compiler-generated library function thunks — specifically
function definitions whose name matches patterns like `@jfptr_*` (used
by Julia). These are boilerplate wrapper functions that aren't useful
when reading IR.
**Off by default** for the same reason — these are real function
definitions in the IR.
Both filters follow the same pattern as existing IR filters (debug info,
metadata, attributes, comments). Unit tests added in
`llvm-ir-parser-tests.ts` covering filter-on, filter-off, and
preservation of unaffected lines.
*(I'm Molty, an AI assistant acting on behalf of @mattgodbolt)*
---------
Co-authored-by: mattgodbolt-molty <mattgodbolt-molty@users.noreply.github.com>
Today we only support passing options to the codegen backend, but not
the compiler that produces IL.
This change adds a new pseudo-option `-compopt`/`--compiler-options` so
that options follow after this pseudo-option can be passed to the
compiler that produces IL.
Fixes#8006
The ex-WINE compilers were appearing at the **top** of the MSVC compiler
dropdown instead of the bottom, because they used the MSVC compiler
version (`19.xx`) for their semver while native MSVC compilers use the
toolset version (`14.xx`). Since `19.xx > 14.xx`, they sorted as
"newest".
This aligns the ex-WINE semvers to the `14.xx` toolset versioning:
- `19.00.24210` → `14.00.24210` (VS 2015 Update 3)
- `19.10.25017` → `14.10.25017` (VS 2017 RTM)
- `19.14.26423` → `14.14.26423` (VS 2017 15.7)
These now sort correctly before `14.20` (VS 2019 16.0), placing the
ex-WINE compilers at the bottom of the list where they belong.
*(I'm Molty, an AI assistant acting on behalf of @mattgodbolt)*
Co-authored-by: mattgodbolt-molty <mattgodbolt-molty@users.noreply.github.com>
Fixes#7493
OneAPI >= 2025.0.0 produces SPIR-V bitcode that clang 18.1.0's
`llvm-dis` can't read, resulting in `Invalid record` errors in the
device viewer. Updating the global `llvmDisassembler` path from clang
18.1.0 to 19.1.0 resolves this while remaining backwards compatible with
older bitcode formats.
Updated in all three properties files:
- `c++.amazon.properties`
- `c.amazon.properties`
- `objc++.amazon.properties`
*(I'm Molty, an AI assistant acting on behalf of @mattgodbolt)*
Co-authored-by: mattgodbolt-molty <mattgodbolt-molty@users.noreply.github.com>
## Summary
Refactors the Cypress test suite to extract common helpers into
`cypress/support/utils.ts`, making it simpler to add new tests.
### Changes
- **Shared helpers extracted to utils.ts**: `findPane()`,
`sourceEditor()`, `compilerOutput()`, `compilerPane()`,
`waitForEditors()`, `setupAndWaitForCompilation()`, `visitPage()`, and
many more
- **New workflow helpers**: `addCompilerFromEditor()`,
`addCompilerFromCompilerPane()`, `openConformanceView()`,
`addConformanceCompiler()`, `openDiffView()`, `allCompilerTabs()`,
`compilerEditorFromTab()`, `compilerPaneFromTab()`,
`lastCompilerContent()`
- **Template literals**: Replaced `.join('\n')` array patterns with
backtick multiline strings
- **Bug fix**: `frontend.cy.ts` hardcoded `localhost:10240` instead of
using `baseUrl` — now uses relative URL
- **Deprecated**: Marked `clearAllIntercepts()` as deprecated with
explanation of why the name is misleading
### Result
- Net reduction of ~110 lines across test files
- All 68 tests pass (7 spec files)
- Adding a new test now typically needs just 3-4 lines of well-named
helper calls
- No changes to test behaviour or coverage
*(I'm Molty, an AI assistant acting on behalf of @mattgodbolt)*
🤖 Generated by LLM (Claude, via OpenClaw)
---------
Co-authored-by: mattgodbolt-molty <mattgodbolt-molty@users.noreply.github.com>