Skip to content

Commit be48448

Browse files
JasonGuo98jasonxjguo1a1a11a
authored
fix examples; remove dependency on yaml-cpp (#148)
Co-authored-by: jasonxjguo <[email protected]> Co-authored-by: Juncheng Yang <[email protected]>
1 parent 8884fd4 commit be48448

File tree

10 files changed

+14758
-47
lines changed

10 files changed

+14758
-47
lines changed

example/cacheCluster/README.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,7 @@ make -j;
1313

1414

1515
## Run
16-
You can run the example trace
16+
You can run the example trace
17+
```bash
18+
./cacheCluster
19+
```

example/cacheHierarchy/CMakeLists.txt

+5-12
Original file line numberDiff line numberDiff line change
@@ -18,20 +18,13 @@ if ("${ZSTD_LIBRARIES}" STREQUAL "")
1818
endif()
1919

2020

21-
# https://github.com/jbeder/yaml-cpp
22-
# wget https://github.com/jbeder/yaml-cpp/archive/refs/tags/0.8.0.tar.gz
23-
# tar -xzf 0.8.0.tar.gz; mkdir yaml-cpp-0.8.0/_build; cd yaml-cpp-0.8.0/_build;
24-
# cmake -DBUILD_SHARED_LIBS=ON ..;
25-
# make -j; sudo make install
26-
find_package(YAML-CPP REQUIRED)
27-
# set(YAML_CPP_INCLUDE_DIR /usr/local/include/)
28-
# set(YAML_CPP_LIBRARIES /usr/local/lib/)
29-
include_directories(${YAML_CPP_INCLUDE_DIR})
30-
message(STATUS ${YAML_CPP_INCLUDE_DIR} ";" ${YAML_CPP_LIBRARIES})
31-
3221

3322
file(GLOB ALL_SRC ${PROJECT_SOURCE_DIR}/*.cpp)
3423
message(STATUS "all sources " ${ALL_SRC})
3524
add_executable(layeredCache ${ALL_SRC})
36-
target_link_libraries(layeredCache yaml-cpp libCacheSim dl m ${GLib_LIBRARY} ${ZSTD_LIBRARIES} pthread)
25+
target_link_libraries(layeredCache
26+
-Wl,--whole-archive
27+
libCacheSim
28+
-Wl,--no-whole-archive
29+
dl m ${GLib_LIBRARY} ${ZSTD_LIBRARIES} pthread)
3730

example/cacheHierarchy/README.md

+1-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ It outputs the L2 miss ratio curve.
55

66
## Dependency
77
* libCacheSim: you must install libCacheSim first
8-
* libyaml: `sudo apt install -yq libyaml-dev libyaml-cpp-dev`
98

109

1110
## Build
@@ -19,5 +18,5 @@ make -j;
1918

2019

2120
## Run
22-
./layeredCache config.yaml
21+
./layeredCache ../config.yaml
2322

example/cacheHierarchy/config.yaml

+8-16
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,15 @@
11
L1:
2-
size: 8GB
2+
size: 1MB
33
path:
4-
- /home/to/l1/trace
5-
- /home/to/l1/trace2
6-
- /home/to/l1/trace3
7-
- /home/to/l1/trace4
8-
- /home/to/l1/trace5
4+
- ../../../data/cloudPhysicsIO.oracleGeneral.bin
95

106
L2:
117
size:
12-
- 2GB
13-
- 4GB
14-
- 8GB
15-
- 16GB
16-
- 32GB
17-
- 64GB
18-
- 128GB
19-
- 256GB
20-
- 512GB
21-
- 1024GB
8+
- 1MB
9+
- 3MB
10+
- 7MB
11+
- 15MB
12+
- 31MB
13+
- 63MB
2214

2315
output: result

0 commit comments

Comments
 (0)