From 4b70161b69ab4d038bee38970fafcb00d0a6b03b Mon Sep 17 00:00:00 2001 From: Reid Spencer Date: Thu, 18 Jan 2007 23:24:24 +0000 Subject: For PR761: Implement reading and writing of the Module's data layout string. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33346 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Bytecode/Reader/Reader.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'lib/Bytecode/Reader/Reader.cpp') diff --git a/lib/Bytecode/Reader/Reader.cpp b/lib/Bytecode/Reader/Reader.cpp index efdb4f1..355fc1d 100644 --- a/lib/Bytecode/Reader/Reader.cpp +++ b/lib/Bytecode/Reader/Reader.cpp @@ -2013,6 +2013,13 @@ void BytecodeReader::ParseModuleGlobalInfo() { TheModule->setTargetTriple(triple); if (Handler) Handler->handleTargetTriple(triple); + + // Read the data layout string and place into the module. + std::string datalayout = read_str(); + TheModule->setDataLayout(datalayout); + // FIXME: Implement + // if (Handler) + // Handler->handleDataLayout(datalayout); if (At != BlockEnd) { // If the file has section info in it, read the section names now. -- cgit v1.1