MCPcopy Create free account
hub / github.com/GJDuck/e9patch / sendLoadValueMetadata

Function sendLoadValueMetadata

src/e9tool/e9metadata.cpp:442–450  ·  view source on GitHub ↗

* Emits an instruction to load the given value into the corresponding * argno register. */

Source from the content-addressed store, hash-verified

440 * argno register.
441 */
442static void sendLoadValueMetadata(FILE *out, intptr_t value, int regno)
443{
444 if (value >= INT32_MIN && value <= INT32_MAX)
445 sendSExtFromI32ToR64(out, value, regno);
446 else if (value >= 0 && value <= UINT32_MAX)
447 sendZExtFromI32ToR64(out, value, regno);
448 else
449 sendMovFromI64ToR64(out, value, regno);
450}
451
452/*
453 * Emits an instruction to load a pointer into the corresponding argno

Callers 3

sendLoadPointerMetadataFunction · 0.85
sendLoadOperandMetadataFunction · 0.85
sendLoadArgumentMetadataFunction · 0.85

Calls 3

sendSExtFromI32ToR64Function · 0.85
sendZExtFromI32ToR64Function · 0.85
sendMovFromI64ToR64Function · 0.85

Tested by

no test coverage detected