MCPcopy Create free account
hub / github.com/Overload-Technologies/Overload / read_uint16

Function read_uint16

Dependencies/tracy/libbacktrace/dwarf.cpp:835–846  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

833/* Read a uint16 from BUF and advance 2 bytes. */
834
835static uint16_t
836read_uint16 (struct dwarf_buf *buf)
837{
838 const unsigned char *p = buf->buf;
839
840 if (!advance (buf, 2))
841 return 0;
842 if (buf->is_bigendian)
843 return ((uint16_t) p[0] << 8) | (uint16_t) p[1];
844 else
845 return ((uint16_t) p[1] << 8) | (uint16_t) p[0];
846}
847
848/* Read a 24 bit value from BUF and advance 3 bytes. */
849

Callers 5

read_addressFunction · 0.85
read_attributeFunction · 0.85
build_address_mapFunction · 0.85
read_line_headerFunction · 0.85
read_line_programFunction · 0.85

Calls 1

advanceFunction · 0.70

Tested by

no test coverage detected