You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

fixture.h 1.1 kB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /**
  2. * \file dnn/test/naive/fixture.h
  3. * MegEngine is Licensed under the Apache License, Version 2.0 (the "License")
  4. *
  5. * Copyright (c) 2014-2021 Megvii Inc. All rights reserved.
  6. *
  7. * Unless required by applicable law or agreed to in writing,
  8. * software distributed under the License is distributed on an
  9. * "AS IS" BASIS, WITHOUT ARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  10. */
  11. #pragma once
  12. #include <gtest/gtest.h>
  13. #include "megdnn/handle.h"
  14. #include "test/common/utils.h"
  15. #include "test/cpu/fixture.h"
  16. #include <memory>
  17. namespace megdnn {
  18. namespace test {
  19. class NAIVE : public ::testing::Test {
  20. public:
  21. void SetUp() override;
  22. void TearDown() override;
  23. Handle* handle() { return m_handle.get(); }
  24. private:
  25. std::unique_ptr<Handle> m_handle;
  26. };
  27. class NAIVE_MULTI_THREADS : public ::testing::Test {
  28. public:
  29. void SetUp() override;
  30. void TearDown() override;
  31. Handle* handle() { return m_handle.get(); }
  32. private:
  33. std::unique_ptr<Handle> m_handle;
  34. };
  35. class NAIVE_BENCHMARK_MULTI_THREADS : public ::testing::Test {};
  36. } // namespace test
  37. } // namespace megdnn
  38. // vim: syntax=cpp.doxygen