Samsung / ONE

On-device Neural Engine
Other
435 stars 157 forks source link

Compiler FE: List up unused projects #11814

Closed hseok-oh closed 11 months ago

hseok-oh commented 1 year ago

Let's list unused compiler frontend projects to remove or disable build.

seanshpark commented 1 year ago

remove or disable build.

+1 to disable build

@lemmaa , your opinion ?

seanshpark commented 1 year ago

I'll work on this task :) With excluding unused projects while normal build, CI build.

seanshpark commented 1 year ago

11848 Draft implementation:

@lemmaa , any comments?

seanshpark commented 12 months ago

@lemmaa PTAL

lemmaa commented 12 months ago

Let's list unused compiler frontend projects to remove or disable build.

@hseok-oh , what's the purpose of this work?

My guess is that there are many possible reasons for this, such as

In any case, the reason, purpose, etc. must be clear so that there is no confusion in the discussion and conclusion.

And, what do you think are excluded? :)

lemmaa commented 12 months ago

11848 Draft implementation:

  • exclude module (compiler/something) when there exist exclude.me file in that folder
  • if -DBUILD_WHITELIST=... is given, ignore this feature and build all modules in the list
  • if -DENABLE_EXCLUDE_ME=OFF is given, ignore this feature and build all modules
  • excluded module may fail in build in the future but we won't know that
  • we can re-enable excluded module when ever needed again
    • any build failure should be fixed at that time

@lemmaa , any comments?

@seanshpark , I agree with your draft design. However, it would be nice to check what @hseok-oh's original intention was and organize the details.

hseok-oh commented 12 months ago

Let's list unused compiler frontend projects to remove or disable build.

@hseok-oh , what's the purpose of this work?

My guess is that there are many possible reasons for this, such as

* Optimizing CI build resources,

* Reducing the difficulty of source code maintenance,

* Etc.

In any case, the reason, purpose, etc. must be clear so that there is no confusion in the discussion and conclusion.

And, what do you think are excluded? :)

Reason to remove: maybe not used any more

Reason to disable build: reduce CI build resource

lemmaa commented 12 months ago

Reason to disable build: reduce CI build resource

  • ex) coco and related, ann-api and related, etc...

In this case, isn't it necessary to automatically and regularly check the following cases among the target modules?

  • excluded module may fail in build in the future but we won't know that
  • we can re-enable excluded module when ever needed again

    • any build failure should be fixed at that time

For example, even if in frequent PR check build or commit check build are excluded, it is checked regularly on a daily or weekly basis and an issue is registered when a build break or test failure occurs.

  • if -DBUILD_WHITELIST=... is given, ignore this feature and build all modules in the list

I think this option would be appropriate for such support.

Taking this into consideration, it would be a good idea to categorize and organize the target list according to the original purpose of the issue.

seanshpark commented 12 months ago

I think this option would be appropriate for such support.

Yup, -DENABLE_EXCLUDE_ME=OFF is for regular checkup to build all modules :)

seanshpark commented 12 months ago

I'll begin posting related changes.

Modules that have `add_executable()` ``` ./caffe2circle/CMakeLists.txt ./caffegen/CMakeLists.txt ./circle2circle/CMakeLists.txt ./circlechef/tools/console/CMakeLists.txt ./circlechef/tools/file/CMakeLists.txt ./circlechef/tools/reverse/CMakeLists.txt ./circledump/CMakeLists.txt ./circle-eval-diff/CMakeLists.txt ./circle-execution-plan/CMakeLists.txt ./circle-inspect/CMakeLists.txt ./circle-interpreter/CMakeLists.txt ./circle-mpqsolver/CMakeLists.txt ./circle-operator/CMakeLists.txt ./circle-opselector/CMakeLists.txt ./circle-part-driver/CMakeLists.txt ./circle-partitioner/CMakeLists.txt ./circle-quantizer/CMakeLists.txt ./circle-tensordump/CMakeLists.txt ./circle-verify/CMakeLists.txt ./common-artifacts/CMakeLists.txt ./dalgona/CMakeLists.txt ./embedded-import-value-test/CMakeLists.txt ./enco/cli/CMakeLists.txt ./enco/core/CMakeLists.txt ./encodump/CMakeLists.txt ./enco/frontend/caffe/CMakeLists.txt ./enco/frontend/tflite/CMakeLists.txt ./hermes/CMakeLists.txt ./i5diff/CMakeLists.txt ./luci-eval-driver/CMakeLists.txt ./luci/tester/CMakeLists.txt ./minmax-embedder/CMakeLists.txt ./minmax-embedder-value-test/gen/CMakeLists.txt ./mio-circle04/CMakeLists.txt ./mio-circle05/CMakeLists.txt ./mio-circle06/CMakeLists.txt ./mio-circle/CMakeLists.txt ./mio-tflite2121/CMakeLists.txt ./mio-tflite260/CMakeLists.txt ./mio-tflite280/CMakeLists.txt ./mio-tflite/CMakeLists.txt ./moco-tf/CMakeLists.txt ./morph/CMakeLists.txt ./nest/core/CMakeLists.txt ./nnc/CMakeLists.txt ./nnc/cmake/utils.cmake ./nnc/passes/CMakeLists.txt ./nnc/tests/acl_soft_backend/artifact_cmake/CMakeLists.txt ./nnc/tests/import/CMakeLists.txt ./nnc/tests/soft_backend/CMakeLists.txt ./nnc/utils/caffe2_dot_dumper/CMakeLists.txt ./nnc/utils/caffe_dot_dumper/CMakeLists.txt ./nnc/utils/input_gen/CMakeLists.txt ./nnc/utils/tflite_dot_dumper/CMakeLists.txt ./nnkit/tools/benchmark/CMakeLists.txt ./nnkit/tools/run/CMakeLists.txt ./nnop/CMakeLists.txt ./nnsuite/conv/nnkit-caffe/CMakeLists.txt ./nnsuite/conv/nnkit-tflite/CMakeLists.txt ./one-cmds/dummy-driver/CMakeLists.txt ./oneco/CMakeLists.txt ./onnx2circle/CMakeLists.txt ./onnx2tflite/CMakeLists.txt ./onnxkit/CMakeLists.txt ./pp/CMakeLists.txt ./q-implant/CMakeLists.txt ./record-minmax/CMakeLists.txt ./tf2circle/CMakeLists.txt ./tf2nnpkg/CMakeLists.txt ./tf2tflite/CMakeLists.txt ./tfkit/CMakeLists.txt ./tflchef/tools/console/CMakeLists.txt ./tflchef/tools/file/CMakeLists.txt ./tflchef/tools/reverse/CMakeLists.txt ./tfldump/CMakeLists.txt ./tfl-inspect/CMakeLists.txt ./tflite2circle/CMakeLists.txt ./tfl-verify/CMakeLists.txt ./vconone/CMakeLists.txt ```
seanshpark commented 12 months ago

These are the candidate modules that "are"/"will be" excluded. Tool level modules are treated first and then related libraries that follows. Agreement or objection can be discussed in each PR for that module.

Tools

Libraries

seanshpark commented 12 months ago

ping @jinevening , @mhs4670go

seanshpark commented 11 months ago

tfinfo is used in tf2nnpkg v4tf has only README.md which can be ignored

seanshpark commented 11 months ago

done for now. @hseok-oh , ok to close?