forked from llvm/llvm-test-suite
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTEST.vtl.Makefile
49 lines (41 loc) · 1.5 KB
/
TEST.vtl.Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
##===- TEST.vtl.Makefile -----------------------------------*- Makefile -*-===##
#
# Makefile for getting performance metrics using Intel's VTune.
#
##===----------------------------------------------------------------------===##
TESTNAME = $*
VTL := /opt/intel/vtune/bin/vtl
#
# Events: These will need to be modified for every different CPU that is used
# (i.e. the Pentium 3 on Cypher has a different set of available events than
# the Pentium 4 on Zion).
#
P4_EVENTS := "-ec en='2nd Level Cache Read Misses' en='2nd-Level Cache Read References'"
P3_EVENTS := "-ec en='L2 Cache Request Misses (highly correlated)'"
EVENTS := $(P4_EVENTS)
#
# Generate events for LLC
#
#$(PROGRAMS_TO_TEST:%=test.$(TEST).%): \
#test.$(TEST).%: Output/%.llc
#@echo "========================================="
#@echo "Running '$(TEST)' test on '$(TESTNAME)' program"
#$(VERB) $(VTL) activity $* -d 50 -c sampling -o $(EVENTS) -app $<
#-$(VERB) $(VTL) run $*
#-$(VERB) $(VTL) view > $@
#$(VERB) $(VTL) delete $* -f
#
# Generate events for CBE
#
$(PROGRAMS_TO_TEST:%=test.$(TEST).%): \
test.$(TEST).%: Output/%.cbe
@echo "========================================="
@echo "Running '$(TEST)' test on '$(TESTNAME)' program"
ifeq ($(RUN_OPTIONS),)
$(VERB) cat $(STDIN_FILENAME) | $(VTL) activity $* -d 50 -c sampling -o $(EVENTS) -app $<
else
$(VERB) cat $(STDIN_FILENAME) | $(VTL) activity $* -d 50 -c sampling -o $(EVENTS) -app $<,"$(RUN_OPTIONS)"
endif
-$(VERB) $(VTL) run $*
-$(VERB) $(VTL) view > $@
$(VERB) $(VTL) delete $* -f