bitops

package
v3.0.0-alpha.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 17, 2022 License: MIT Imports: 0 Imported by: 0

Documentation

Overview

Package bitops defines commonly used bit operations

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExtractBitsFromU32

func ExtractBitsFromU32(num uint32, loInclude, hiInclude int) uint32

ExtractBitsFromU32 will get the bits from loInclude to hiInclude.

func ExtractBitsFromU64

func ExtractBitsFromU64(num uint64, loInclude, hiInclude int) uint64

ExtractBitsFromU64 will get the bits from loInclude to hiInclude.

func SignExt

func SignExt(in uint64, signBit int) (out uint64)

SignExt updates all the bits beyond the signBit to be the same as the sign bit.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL