Rename signed_extend32() and signed_extend64() to
extract_signed_bitfield_32() and extract_signed_bitfield_64()
respectively, as these names more clearly describe what these functions
are doing and to make room for functions really doing sign extension.
Change implementation of extract_signed_bitfield_32() and
extract_signed_bitfield_64() to stop relying on GCC/clang-specific
implementation-defined behavior on right shifts of negative integers.
They now rely on two-complement arithmetic, which all machines we
support do, and which is the future direction for C (it is a requirement
since C23).
While here, separate the sign bit extension into sign_extend_32() and
sign_extend_64() respectively, as these could be useful on their own in
addition to serving to implement extract_signed_bitfield_32() and
extract_signed_bitfield_64().