This repositorary is designed for 2018 Spring - CS255/455 Software Analysis and Improvments LLVM Project. It contains the docker with Ubuntu 16.04
and LLVM/Clang 3.9.1
.
Here is the official guide about how to install docker on different operating systems. Install Docker
$ docker build -t cs255-llvm-image /PATH/TO/THE/DOCKERFILE
# Or, you can directly pull the image from Docker Hub
$ docker pull noyafangzhou/cs255-llvm-image
Notes that the cs255-llvm-loop
is the directory that contains the code template. You have to clone it first and then add it to the docker container using the following command. Also, Capital Letters CANNOT appear on the path to cs255-llvm-pass
directory.
# build docker image through Dockerfile
$ docker run -it -v $PWD/cs255-llvm-loop:/cs255-llvm-loop --name cs255-llvm cs255-llvm-image /bin/bash
# push docker image through docker hub
$ docker run -it -v $PWD/cs255-llvm-loop:/cs255-llvm-loop --name cs255-llvm noyafangzhou/cs255-llvm-image /bin/bash
Notes that you should type the previous command under the path that contains the cs255-llvm-loop dir.
# List all the image
$ docker image ls
# List all the container
$ docker ps -a
# Exit the container
$ exit
# Restart the container after quit
$ docker start -ai #{CONTAINER_NAME}
# Remove the image
$ docker rmi #{IMAGE_NAME}
# Remove the container
$ docker container rm #{CONTAINER_NAME}
# Remove the <none> tag image
$ docker rmi $(docker images | grep "^<none>" | awk "{print $3}")
For more information about the Docker Command, please check Docker Command