rems-project / sail

Sail architecture definition language
Other
622 stars 116 forks source link

Add count_trailing_zero primop #792

Closed nwf closed 4 days ago

nwf commented 4 days ago

To go along with count_leading_zeros

This at least shows up in the riscv and CHERIoT models, and it'd be nice to have as a primop. (As it might bitvector reversal, as that'd have given a different spelling, but that seemed like more work and I didn't, at a glance, see it in the GNU mp library.)

github-actions[bot] commented 4 days ago

Test Results

   12 files  ±0     24 suites  ±0   0s ⏱️ ±0s   724 tests +1    724 ✅ +1  0 💤 ±0  0 ❌ ±0  2 435 runs  +2  2 434 ✅ +2  1 💤 ±0  0 ❌ ±0 

Results for commit 3a628528. ± Comparison against base commit ac83f8c4.

:recycle: This comment has been updated with latest results.

Alasdair commented 4 days ago

Thanks! There's a script in test/typecheck/ that fixes the type error messages for cases like that, hopefully you didn't go and adjust them by hand!