From 53f857cb3cb9f49270047f5874ed728cffd76d78 Mon Sep 17 00:00:00 2001 From: Hamed Gorjiara Date: Fri, 28 Aug 2020 15:12:37 -0700 Subject: [PATCH] Resetting learning config --- smtmonitor.sh | 21 +++++++++++++++++++++ src/Makefile | 2 +- src/Scripts/perf.sh | 6 ++++++ src/common.mk | 2 +- 4 files changed, 29 insertions(+), 2 deletions(-) create mode 100755 smtmonitor.sh create mode 100755 src/Scripts/perf.sh diff --git a/smtmonitor.sh b/smtmonitor.sh new file mode 100755 index 0000000..e912785 --- /dev/null +++ b/smtmonitor.sh @@ -0,0 +1,21 @@ +#!/bin/bash + +#Terminate the script if even one command fails +#set -e + +SATSOLVER=z3 +CSOLVER=wiretap-tools +SLEEPTIME=10 +FILE=monitor.log + + +kill -9 `jobs -ps` &>$FILE + +while true; do + date >> $FILE + free >> $FILE + ps aux | grep $SATSOLVER | grep -v "grep" >> $FILE + ps aux | grep $CSOLVER | grep -v "grep" >> $FILE + echo "*************************" >> $FILE + sleep $SLEEPTIME +done diff --git a/src/Makefile b/src/Makefile index f04c58f..83f3027 100644 --- a/src/Makefile +++ b/src/Makefile @@ -16,7 +16,7 @@ OBJECTS := $(CPP_SOURCES:%.cc=$(OBJ_DIR)/%.o) $(C_SOURCES:%.c=$(OBJ_DIR)/%.o) J_OBJECTS := $(J_SOURCES:%.java=$(OBJ_DIR)/%.class) -CFLAGS := -Wall -O0 -g +CFLAGS := -Wall -O3 -g CXXFLAGS := -std=c++1y -pthread CFLAGS += -IAST -IASTTransform -IASTAnalyses -IASTAnalyses/Polarity -IASTAnalyses/Order -IASTAnalyses/Encoding -ITranslator -ICollections -IBackend -I. -IEncoders -ITuner -ISerialize -IInterpreter -I$(JAVA_INC) -I$(JAVA_INC)/linux LDFLAGS := -ldl -lrt -rdynamic -g diff --git a/src/Scripts/perf.sh b/src/Scripts/perf.sh new file mode 100755 index 0000000..63a9ec5 --- /dev/null +++ b/src/Scripts/perf.sh @@ -0,0 +1,6 @@ +#!/bin/bash +echo "Start profiling: $@" +echo 0 > /proc/sys/kernel/nmi_watchdog +perf stat -e page-faults,L1-dcache-loads:HG,L1-dcache-load-misses:HG,LLC-loads:HG,LLC-load-misses:HG $@ +perf stat -e LLC-loads:HG,LLC-load-misses:HG $@ +echo 1 > /proc/sys/kernel/nmi_watchdog diff --git a/src/common.mk b/src/common.mk index 1533d5f..df3829a 100644 --- a/src/common.mk +++ b/src/common.mk @@ -9,7 +9,7 @@ JAVA_INC := /usr/lib/jvm/default-java/include/ LIB_NAME := cons_comp LIB_SO := lib_$(LIB_NAME).so -CPPFLAGS += -Wall -g -O0 +CPPFLAGS += -Wall -g -O3 # Mac OSX options ifeq ($(UNAME), Darwin) -- 2.34.1