MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / DecodeFixed32

Function DecodeFixed32

tensorflow/core/lib/core/raw_coding.h:41–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

39}
40
41inline uint32 DecodeFixed32(const char* ptr) {
42 if (port::kLittleEndian) {
43 // Load the raw bytes
44 uint32 result;
45 memcpy(&result, ptr, sizeof(result)); // gcc optimizes this to a plain load
46 return result;
47 } else {
48 return ((static_cast<uint32>(static_cast<unsigned char>(ptr[0]))) |
49 (static_cast<uint32>(static_cast<unsigned char>(ptr[1])) << 8) |
50 (static_cast<uint32>(static_cast<unsigned char>(ptr[2])) << 16) |
51 (static_cast<uint32>(static_cast<unsigned char>(ptr[3])) << 24));
52 }
53}
54
55inline uint64 DecodeFixed64(const char* ptr) {
56 if (port::kLittleEndian) {

Callers 10

TESTFunction · 0.85
DecodeFixed64Function · 0.85
ReadChecksummedMethod · 0.85
NumRestartsMethod · 0.85
GetRestartPointMethod · 0.85
DecodeFromMethod · 0.85
ReadBlockFunction · 0.85
LE_LOAD32Function · 0.85
Hash32Function · 0.85
Fetch32BatchFunction · 0.85

Calls

no outgoing calls

Tested by 1

TESTFunction · 0.68