OSDN Git Service

Subzero: Fix build errors from upgrading to clang 3.9 .
authorJim Stichnoth <stichnot@chromium.org>
Wed, 9 Mar 2016 06:46:19 +0000 (22:46 -0800)
committerJim Stichnoth <stichnot@chromium.org>
Wed, 9 Mar 2016 06:46:19 +0000 (22:46 -0800)
BUG= none
TBR=jpp@chromium.org

Review URL: https://codereview.chromium.org/1778663003 .

Makefile.standalone
src/IceTargetLoweringX86Base.h

index b101f4a..95f3093 100644 (file)
@@ -413,6 +413,7 @@ $(UNITTEST_OBJS): $(OBJDIR)/unittest/%.o: unittest/%.cpp unittest/*.h \
           -I$(LLVM_SRC_PATH)/utils/unittest/googletest/include \
           -I$(LLVM_SRC_PATH) \
           -DGTEST_HAS_RTTI=0 -DGTEST_USE_OWN_TR1_TUPLE \
+          -Wno-expansion-to-defined \
           $< -o $@
 
 $(OBJS): | $(OBJDIR)
index 18a69fd..01298eb 100644 (file)
@@ -80,6 +80,9 @@ public:
 
   static void staticInit(GlobalContext *Ctx);
   static TargetX86Base *create(Cfg *Func) { return new TargetX86Base(Func); }
+  std::unique_ptr<::Ice::Assembler> createAssembler() const override {
+    return nullptr;
+  }
 
   static FixupKind getPcRelFixup() { return PcRelFixup; }
   static FixupKind getAbsFixup() { return AbsFixup; }
@@ -353,10 +356,17 @@ protected:
   }
   /// Emit just the call instruction (without argument or return variable
   /// processing), sandboxing if needed.
-  virtual Inst *emitCallToTarget(Operand *CallTarget, Variable *ReturnReg) = 0;
+  virtual Inst *emitCallToTarget(Operand *CallTarget, Variable *ReturnReg) {
+    (void)CallTarget;
+    (void)ReturnReg;
+    return nullptr;
+  }
   /// Materialize the moves needed to return a value of the specified type.
-  virtual Variable *moveReturnValueToRegister(Operand *Value,
-                                              Type ReturnType) = 0;
+  virtual Variable *moveReturnValueToRegister(Operand *Value, Type ReturnType) {
+    (void)Value;
+    (void)ReturnType;
+    return nullptr;
+  }
 
   /// Emit a jump table to the constant pool.
   void emitJumpTable(const Cfg *Func,