Skip to content

Add support for variable length shifts (wordLang + below)#1341

Merged
tanyongkiam merged 65 commits intomasterfrom
var-len-shifts
Feb 25, 2026
Merged

Add support for variable length shifts (wordLang + below)#1341
tanyongkiam merged 65 commits intomasterfrom
var-len-shifts

Conversation

@dnezam
Copy link
Copy Markdown
Contributor

@dnezam dnezam commented Feb 24, 2026

Closes #1213

myreen and others added 30 commits August 15, 2025 05:59
- Adjusted shift_rwt
- Added shift_imm_rwt (also added to arm7_encode_rwts)
One in ssa_cc_trans_correct, and the other two have something to do with the
conventions, presumably

(inst_arg_convention (Arith (Shift _ _ _ (Reg r))) ⇔ r = 8) ∧

from wordConvs.
- 3 cheats in comp_correct
- Broken starting init_code_thm
derive_corr_thm fails for some theorems.
tanyongkiam and others added 28 commits February 6, 2026 00:46
Co-authored-by: Yong Kiam <tanyongkiam@gmail.com>
Verified fixes:
- stackPropsScript: reg_bound_exp/reg_bound_inst handle both Shift subexps
- word_to_stackScript: wInst handles reg_imm Shift argument
- word_copyScript: copy_prop_inst handles Shift reg_imm
- word_to_stackProofScript: map_var/evaluate_wInst for new Shift
- word_allocProofScript: nlive_store/every_inst proofs for Shift
- stack_removeProofScript: state_rel_inst/comp_correct for Shift
- stack_allocProofScript: inst_select_exp for Shift reg_imm
- wordConvsProofScript: copy_prop for new Shift
- data_to_wordScript: ShiftN overload for assign/assign_var
- data_to_word_bignumProofScript: AnyHeader_thm ShiftVar cases
- stack_to_labProofScript: add simp[w2n_lt] for Shift assert in inst_correct

Not yet fixed:
- lab_to_targetProofScript: arith_upd_lemma needs new Shift >- block (WIP)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Magnus Myreen <myreen@chalmers.se>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…imps

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…refByte

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Once cheats are removed, this file should be done (hopefully)
Split Shift d1 definitions into Imm/Reg variants for arm7, arm8, mips,
riscv. Split shift theorem processing to handle reg_imm for arm8, mips,
riscv. Add Store16/Store32/Load16/Load32 d1 entries for mips, riscv, ag32.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@tanyongkiam tanyongkiam merged commit fab9454 into master Feb 25, 2026
1 check passed
@myreen myreen deleted the var-len-shifts branch February 25, 2026 05:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add variable-length shifts to asm and target encoders

3 participants