Skip to content

Commit e78ce76

Browse files
committed
Runtime - Restoring debugging symbols
As long as the runtime is not linked into the bitcode prior to Clang, the debugging symbols can be present. #88.
1 parent 0de5e61 commit e78ce76

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

common/runtime/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
PROJECT = libct_runtime.a
22
OBJECTS = ct_runtime.o
3-
CFLAGS = -O3
3+
CFLAGS = -O3 -g
44
HEADERS = ct_runtime.h
55
BITCODE = ct_runtime.bc ct_main.bc ct_mpi.bc ct_nompi.bc
66

scripts/contech_wrapper_par.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ def main(isCpp = False, markOnly = False, minimal = False, hammer = False):
254254
# As the result of link will be instrumented, do not include RUNTIME, etc
255255
pcall(["llvm-link", ofiles, oFromAFiles, "-o", out + ".link.bc"])
256256
pcall([OPT, "-load=" + LLVMCONTECH, "-Contech", out + ".link.bc", "-o", out + "_ct.link.bc", "-ContechState", stateFile])
257-
pcall(["llvm-link", out + "_ct.link.bc", RUNTIME, "-o", out + "_ct.fin.bc"]);
257+
pcall(["llvm-link", out + "_ct.link.bc", "-o", out + "_ct.fin.bc"]);
258258
pcall(["rm", "-rf", TMPARDIR])
259259

260260
# Link in basic block table
@@ -275,7 +275,7 @@ def main(isCpp = False, markOnly = False, minimal = False, hammer = False):
275275
else:
276276
#Cilk runtime requires -ldl?
277277
#Contech runtime requires -lrt and -lpthread
278-
pcall([CC, out + "_ct.fin.bc", CFLAGS, "-o", out, "-lrt", "-ldl", "-lpthread", "contech_state.o"])
278+
pcall([CC, out + "_ct.fin.bc", RUNTIME, CFLAGS, "-o", out, "-lrt", "-ldl", "-lpthread", "contech_state.o"])
279279
else:
280280
passThrough(CC)
281281

0 commit comments

Comments
 (0)