[Libre-soc-isa] [Bug 996] add shaddsw or replace shadduw with shaddsw since i32 indexes are waay more common than u32

bugzilla-daemon at libre-soc.org bugzilla-daemon at libre-soc.org
Wed Jan 25 21:15:30 GMT 2023


https://bugs.libre-soc.org/show_bug.cgi?id=996

--- Comment #1 from Jacob Lifshay <programmerjake at gmail.com> ---
(In reply to Dmitry Selyutin from bug #966 comment #11)
> Most of the cases I saw in the wild didn't really need sign. That is, many C
> programmers just use int since they simply unaware or are not used to size_t.

the issue is that even if indexes are almost never negative, the C compiler
often can't prove that so needs to generate code that is correct even with
negative indexes. I'd guess that happens waay more often than having u32
indexes, hence why I think shaddsw is waay more important than shadduw.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Libre-SOC-ISA mailing list