mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 04:02:41 +01:00
Update Kaleidoscope tutorial inline code
Reported on IRC, the tutorial code at the bottom of the page correctly namespaces the FunctionPassManager, but the as-you-go code does not. This patch adds the namespace to those.
This commit is contained in:
parent
d1a0fd3633
commit
3960ffe231
@ -142,7 +142,7 @@ for us:
|
||||
TheModule = std::make_unique<Module>("my cool jit", TheContext);
|
||||
|
||||
// Create a new pass manager attached to it.
|
||||
TheFPM = std::make_unique<FunctionPassManager>(TheModule.get());
|
||||
TheFPM = std::make_unique<legacy::FunctionPassManager>(TheModule.get());
|
||||
|
||||
// Do simple "peephole" optimizations and bit-twiddling optzns.
|
||||
TheFPM->add(createInstructionCombiningPass());
|
||||
@ -275,7 +275,7 @@ We also need to setup the data layout for the JIT:
|
||||
TheModule->setDataLayout(TheJIT->getTargetMachine().createDataLayout());
|
||||
|
||||
// Create a new pass manager attached to it.
|
||||
TheFPM = std::make_unique<FunctionPassManager>(TheModule.get());
|
||||
TheFPM = std::make_unique<legacy::FunctionPassManager>(TheModule.get());
|
||||
...
|
||||
|
||||
The KaleidoscopeJIT class is a simple JIT built specifically for these
|
||||
|
Loading…
Reference in New Issue
Block a user