| Index: src/IceTargetLowering.cpp
|
| diff --git a/src/IceTargetLowering.cpp b/src/IceTargetLowering.cpp
|
| index 71788dfc8dd011b03b5ab8f1bccdea0ff181370f..8e3d56b309e2a2d08767c4169435eb9b41d606f1 100644
|
| --- a/src/IceTargetLowering.cpp
|
| +++ b/src/IceTargetLowering.cpp
|
| @@ -15,6 +15,7 @@
|
| //
|
| //===----------------------------------------------------------------------===//
|
|
|
| +#include "assembler_ia32.h"
|
| #include "IceCfg.h" // setError()
|
| #include "IceCfgNode.h"
|
| #include "IceOperand.h"
|
| @@ -98,6 +99,15 @@ TargetLowering *TargetLowering::createLowering(TargetArch Target, Cfg *Func) {
|
| return NULL;
|
| }
|
|
|
| +Assembler *TargetLowering::createAssembler(TargetArch Target, Cfg *Func) {
|
| + // These statements can be #ifdef'd to specialize the assembler
|
| + // to a subset of the available targets. TODO: use CRTP.
|
| + if (Target == Target_X8632)
|
| + return new x86::AssemblerX86();
|
| + Func->setError("Unsupported target");
|
| + return NULL;
|
| +}
|
| +
|
| void TargetLowering::doAddressOpt() {
|
| if (llvm::isa<InstLoad>(*Context.getCur()))
|
| doAddressOptLoad();
|
|
|