Skip to content

Commit

Permalink
Add target for profiling with threadscope
Browse files Browse the repository at this point in the history
  • Loading branch information
aggelgian committed Jan 12, 2015
1 parent 990cb04 commit 15522eb
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,6 @@
*.hp
*.prof
*.ps
*.eventlog
orbit
OrbitTests
6 changes: 4 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
.PHONY: FORCE clean distclean

COMPILE_OPTS = -Wall -rtsopts -O2 -threaded

orbit: FORCE
ghc $(COMPILE_OPTS) --make Bench.hs -main-is Bench -o orbit

Expand All @@ -12,12 +11,15 @@ prof: distclean
ghc $(COMPILE_OPTS) --make Bench.hs -main-is Bench -o orbit && \
ghc $(COMPILE_OPTS) --make Bench.hs -main-is Bench -o orbit -prof -osuf p_o

threadscope:
ghc $(COMPILE_OPTS) -eventlog --make Bench.hs -main-is Bench -o orbit

prof-results:
hp2ps -e8in -c orbit && \
echo "The memory profiling graph is in orbit.ps"

clean:
$(RM) *.swp *~ *.hi *.o *.dyn_hi *.dyn_o *.p_o *.aux *.hp *.prof
$(RM) *.swp *~ *.hi *.o *.dyn_hi *.dyn_o *.p_o *.aux *.hp *.prof *.eventlog

distclean: clean
$(RM) orbit OrbitTests

0 comments on commit 15522eb

Please sign in to comment.