mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-17 00:57:54 +00:00
fix memory-layout assumption which only holds on little-endian systems
llvm-svn: 117176
This commit is contained in:
parent
7a1dadd47d
commit
6e58dbc9e4
@ -505,7 +505,7 @@ void ARMCodeEmitter::emitConstPoolInstruction(const MachineInstr &MI) {
|
||||
emitGlobalAddress(GV, ARM::reloc_arm_absolute, isa<Function>(GV), false);
|
||||
emitWordLE(0);
|
||||
} else if (const ConstantInt *CI = dyn_cast<ConstantInt>(CV)) {
|
||||
uint32_t Val = *(uint32_t*)CI->getValue().getRawData();
|
||||
uint32_t Val = uint32_t(*CI->getValue().getRawData());
|
||||
emitWordLE(Val);
|
||||
} else if (const ConstantFP *CFP = dyn_cast<ConstantFP>(CV)) {
|
||||
if (CFP->getType()->isFloatTy())
|
||||
|
Loading…
x
Reference in New Issue
Block a user