[enco.core] Resolve unused variable/parameter warnings (#3014)
author박종현/On-Device Lab(SR)/Staff Engineer/삼성전자 <jh1302.park@samsung.com>
Sun, 10 Feb 2019 23:43:34 +0000 (08:43 +0900)
committerGitHub Enterprise <noreply-CODE@samsung.com>
Sun, 10 Feb 2019 23:43:34 +0000 (08:43 +0900)
This commit resolves unused variable/parameter warnings in enco_core
library.

Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
contrib/enco/core/src/Transforms/FeatureUnification.cpp
contrib/enco/core/src/Transforms/GlobalDataGeneration.cpp
contrib/enco/core/src/Transforms/Split.cpp

index 56ac79f..1a7a0a8 100644 (file)
@@ -158,8 +158,6 @@ void unify_feature(enco::Code *code)
     std::vector<std::unique_ptr<FeatureGroup>> groups;
 
     auto assign_group = [&](coco::FeatureObject *feature) {
-      auto layout = feature->layout();
-
       // Find a compatible FeatureGroup
       FeatureGroup *group = nullptr;
 
index 20ac2a0..152477a 100644 (file)
@@ -147,7 +147,7 @@ void generate_global_data(std::ostream &os, enco::Code *code)
   {
     auto binder = ann_ctx->nth(n);
 
-    auto emit = [&](const ann::OperandID &id, const ann::Operand *info) {
+    auto emit = [&](const ann::OperandID & /*id*/, const ann::Operand *info) {
       if (info->weight())
       {
         auto base = info->weight()->base();
index 11ee9ca..1292bb0 100644 (file)
@@ -158,7 +158,6 @@ public:
 public:
   void append(ANNBinder *binder) const override
   {
-    auto module = enco::module(_sess);
     auto data = enco::data(_sess);
 
     auto ifm = binder->addOperand<float>(_ifm);
@@ -1032,7 +1031,6 @@ Compatibility ANNGroupBuilder::kind(const coco::Block *blk) const
 void ANNGroupBuilder::build(enco::Code *code) const
 {
   auto m = code->module();
-  auto d = code->data();
 
   // ANNGroupBuilder will construct a sequence of blocks from the original block sequence, and
   // a destination block (that dst_blk points to) is the tail of the generated sequence.