Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/coreclr/interpreter/intops.h
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ inline int32_t getI4LittleEndian(const uint8_t* ptr)

inline int64_t getI8LittleEndian(const uint8_t* ptr)
{
return (int64_t)getI4LittleEndian(ptr) | ((int64_t)getI4LittleEndian(ptr + 4)) << 32;
return (int64_t)getU4LittleEndian(ptr) | ((int64_t)getI4LittleEndian(ptr + 4)) << 32;
}

inline float getR4LittleEndian(const uint8_t* ptr)
Expand Down
4 changes: 2 additions & 2 deletions src/coreclr/vm/interpexec.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,15 +143,15 @@ void InterpExecMethod(InterpreterFrame *pInterpreterFrame, InterpMethodContextFr
ip += 2;
break;
case INTOP_LDC_I8:
LOCAL_VAR(ip[1], int64_t) = (int64_t)ip[2] + ((int64_t)ip[3] << 32);
LOCAL_VAR(ip[1], int64_t) = (int64_t)(uint32_t)ip[2] + ((int64_t)ip[3] << 32);
ip += 4;
break;
case INTOP_LDC_R4:
LOCAL_VAR(ip[1], int32_t) = ip[2];
ip += 3;
break;
case INTOP_LDC_R8:
LOCAL_VAR(ip[1], int64_t) = (int64_t)ip[2] + ((int64_t)ip[3] << 32);
LOCAL_VAR(ip[1], int64_t) = (int64_t)(uint32_t)ip[2] + ((int64_t)ip[3] << 32);
ip += 4;
break;
case INTOP_LDPTR:
Expand Down
Loading