Skip to content
Commit 4561352f authored by Jay Foad's avatar Jay Foad
Browse files

[CodeEmitter] Fix encoding wide instructions on big-endian hosts

For instructions wider than 64 bits the InstBits table is initialized in
64-bit chunks from APInt::getRawData, but it was being read with
LoadIntFromMemory which is byte-based.

Fix this by reading the table with the APInt constructor that takes an
ArrayRef to the raw data instead.

This is currently NFC for in-tree targets but fixes AMDGPU failures on
big-endian hosts that were caused by D126483 until it was reverted.

Differential Revision: https://reviews.llvm.org/D127195
parent bccbf527
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment