Skip to content

Commit

Permalink
Merge pull request #633 from sogartar/refactor-out-env-iface
Browse files Browse the repository at this point in the history
Refactor out Env interface from CompilerEnv
  • Loading branch information
ChrisCummins committed Mar 29, 2022
2 parents 6cf4926 + 3b9518a commit 3c21aee
Show file tree
Hide file tree
Showing 39 changed files with 1,777 additions and 1,266 deletions.
5 changes: 3 additions & 2 deletions benchmarks/bench_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import examples.example_compiler_gym_service as dummy
from compiler_gym.envs import CompilerEnv, LlvmEnv, llvm
from compiler_gym.service import CompilerGymServiceConnection
from compiler_gym.service.client_service_compiler_env import ClientServiceCompilerEnv
from tests.pytest_plugins.llvm import OBSERVATION_SPACE_NAMES, REWARD_SPACE_NAMES
from tests.test_main import main

Expand Down Expand Up @@ -56,8 +57,8 @@ def test_make_local(benchmark, env_id):
"args",
[
(llvm.LLVM_SERVICE_BINARY, LlvmEnv),
(dummy.EXAMPLE_CC_SERVICE_BINARY, CompilerEnv),
(dummy.EXAMPLE_PY_SERVICE_BINARY, CompilerEnv),
(dummy.EXAMPLE_CC_SERVICE_BINARY, ClientServiceCompilerEnv),
(dummy.EXAMPLE_PY_SERVICE_BINARY, ClientServiceCompilerEnv),
],
ids=["llvm", "dummy-cc", "dummy-py"],
)
Expand Down
2 changes: 1 addition & 1 deletion compiler_gym/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ py_library(
deps = [
":validation_error",
":validation_result",
"//compiler_gym/envs:compiler_env",
"//compiler_gym/service:client_service_compiler_env",
"//compiler_gym/spaces",
"//compiler_gym/util",
],
Expand Down
2 changes: 1 addition & 1 deletion compiler_gym/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ cg_py_library(
DEPS
::validation_error
::validation_result
compiler_gym::envs::compiler_env
compiler_gym::service::client_service_compiler_env
compiler_gym::spaces::spaces
compiler_gym::util::util
PUBLIC
Expand Down
2 changes: 0 additions & 2 deletions compiler_gym/envs/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ py_library(
"//compiler_gym:compiler_env_state",
"//compiler_gym:validation_result",
"//compiler_gym/datasets",
"//compiler_gym/service",
"//compiler_gym/service/proto",
"//compiler_gym/spaces",
"//compiler_gym/util",
"//compiler_gym/views",
Expand Down
8 changes: 3 additions & 5 deletions compiler_gym/envs/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,11 @@ cg_py_library(
SRCS
"compiler_env.py"
DEPS
compiler_gym::compiler_env_state
compiler_gym::datasets::datasets
compiler_gym::service::service
compiler_gym::service::proto::proto
compiler_gym::spaces::spaces
compiler_gym::util::util
compiler_gym::validation_result
compiler_gym::views::views
compiler_gym::compiler_env_state
compiler_gym::validation_result
compiler_gym::datasets::datasets
PUBLIC
)
Loading

0 comments on commit 3c21aee

Please sign in to comment.