Set DataLayout from our TargetMachine (#12335)

Otherwise LLJIT's constructor will ask the LLJITBuilder's JTMB to
create a DataLayout. As we don't propagate the JTMB (yet -- we
probably should!), this will be wrong if target features influence
the DataLayout.

This should fix #12293.
This commit is contained in:
Jonas Hahnfeld 2023-02-16 20:32:44 +01:00 committed by jenkins
parent e122c6dcc6
commit 75930f9dfd

View File

@ -478,6 +478,7 @@ IncrementalJIT::IncrementalJIT(
ErrorAsOutParameter _(&Err);
LLJITBuilder Builder;
Builder.setDataLayout(m_TM->createDataLayout());
Builder.setExecutorProcessControl(std::move(EPC));
// Create ObjectLinkingLayer with our own MemoryManager.