Fix the operand-size/prefix bug class reported by the sigil backend, then close every failure a whole-ISA encode->decode->re-encode audit surfaced -- 247 -> 0 over the 1165 round-trippable legacy forms. Encode/decode: - MOVSX/MOVZX take 66h from the destination, not the source (CRC32, whose r/m source drives 66h, is unchanged) - operand-less 16-bit forms (CBW/CWD, MOVSW/CMPSW/SCASW/LODSW/STOSW, IRET/PUSHF/POPF) emit 66h via a new opsize_16 flag - CRC32/MOVBE and POPCNT/LZCNT/TZCNT: mandatory F2/F3 beats 66h on decode - mandatory-prefix REP double-encode: F2/F3 no longer re-emitted as REP - fixed-ModR/M decode: x87 (FNOP/FCHS/FADD ST(i)/...) and the 0F 01/AE/C7/1E system-op groups (VMCALL/RDTSCP/LFENCE/ENDBR/...); gen.odin preserves the fixed ModR/M byte, the decoder matches and consumes it - implicit-operand round-trip (accumulator short forms, x87 ST(i), xchg) via a positional matcher + emit path; accumulators stay implicit so hand-built `add eax, imm` keeps the general form (typed-builder consistency) - MOV to/from CR/DR/segment (were decoding as GPRs); reg-vs-mem disambiguation (RDRAND vs VMPTRLD, MOVLHPS vs MOVHPS); x87 M80 operand size; PINSRW; NOP vs XCHG at 0x90 - LOCK standalone; ENTER two immediates; PUSH/POP FS/GS (segment fixed by the opcode + non-cacheable); BOUND marked 32-bit-only; RDRAND/RDSEED r16 (66 is operand-size, resolved against the mandatory-66 VMCLEAR by ModR/M) Tools/tests: - revive dump_verify_input + verify_against_llvm (stale Result API; drop the aliases that were masking the fixed bugs); align verify_tables with the preserved fixed-ModR/M ext - new tests/test_narrow_widths.odin: byte-exact vs llvm-mc + round-trip guards - fold the bit-rotted tests32 package into the main suite (i386 Mode._32 paths) 248 tests pass; verify_tables passes. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01115ktMoX5qGAfp1VemBzCP
The Data-Oriented Language for Sane Software Development.
The Odin Programming Language
Odin is a general-purpose programming language with distinct typing, built for high performance, modern systems, and built-in data-oriented data types. The Odin Programming Language, the C alternative for the joy of programming.
Website: https://odin-lang.org/
package main
import "core:fmt"
main :: proc() {
program := "+ + * 😃 - /"
accumulator := 0
for token in program {
switch token {
case '+': accumulator += 1
case '-': accumulator -= 1
case '*': accumulator *= 2
case '/': accumulator /= 2
case '😃': accumulator *= accumulator
case: // Ignore everything else
}
}
fmt.printf("The program \"%s\" calculates the value %d\n",
program, accumulator)
}
Documentation
Getting Started
Instructions for downloading and installing the Odin compiler and libraries.
Nightly Builds
Get the latest nightly builds of Odin.
Learning Odin
Overview of Odin
An overview of the Odin programming language.
Frequently Asked Questions (FAQ)
Answers to common questions about Odin.
Packages
Documentation for all the official packages part of the core and vendor library collections.
Examples
Examples on how to write idiomatic Odin code. Shows how to accomplish specific tasks in Odin, as well as how to use packages from core and vendor.
Odin Documentation
Documentation for the Odin language itself.
Odin Discord
Get live support and talk with other Odin programmers on the Odin Discord.
Articles
The Odin Blog
The official blog of the Odin programming language, featuring announcements, news, and in-depth articles by the Odin team and guests.
Warnings
- The Odin compiler is still in development.