Ignore:
Timestamp:
May 1, 2023, 4:19:09 PM (3 years ago)
Author:
caparsons <caparson@…>
Branches:
ADT, ast-experimental, master
Children:
c083c3d
Parents:
a50fdfb (diff), 985b624 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

resolved merge conflicts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • doc/theses/mike_brooks_MMath/benchmarks/list/Makefile

    ra50fdfb r6e1e2d0  
    11# For correctness, see test-correctness.sh.
    22# For performance:
    3 #       pushd ~/cfax
    4 #       ~/setcfa build-fast
    5 #       popd
    6 #       make perfprogs CFA=$cfa -j8 MODE=performance
    7 #       make results-latest.csv RUNARGS=5 RUN_NUM_REPS=5
    8 
     3# pushd ~/cfax
     4# . ~/setcfa build-fast
     5# popd
     6# make perfprogs CFA=$cfa -j8 MODE=performance
     7# make results-latest.csv RUN_DURATION_SEC=5 RUN_NUM_REPS=5 RUN_DATA_SIZE_MODE=common5
     8# cp results-latest.csv results-baseline.csv
     9# make results-latest.csv OP_MOVEMENTS=stack OP_POLARITIES=insfirst OP_ACCESSORS=allhead RUN_DURATION_SEC=5 RUN_NUM_REPS=5 RUN_DATA_SIZE_MODE=thorough
     10# cp results-latest.csv results-sizing.csv
    911
    1012CFA = cfa
     
    1214UXX =  ~/u++/u++-7.0.0/bin/u++
    1315
    14 MODE = performance
    15 RUNARGS=
     16MODE=performance
     17EXTRA_COMP_FLAGS=
     18RUN_NUM_REPS=3
     19RUN_DATA_SIZE_MODE=none
     20RUN_DURATION_SEC=5
     21RUN_TASKSET_CPULIST=6
    1622
    1723ifeq "$(MODE)" "performance"
    18 PERFFLAGS_CFA = -nodebug -O3
     24PERFFLAGS_CFA = -DNDEBUG -O3 -nodebug
    1925PERFFLAGS_CC  = -DNDEBUG -O3
    2026else ifeq "$(MODE)" "correctness"
    21 PERFFLAGS_CFA = -debug -O0 -g
    22 PERFFLAGS_CC = -O0 -g
     27PERFFLAGS_CFA = -O0 -g -debug
     28PERFFLAGS_CC  = -O0 -g
    2329else
    2430$(error Bad MODE ($(MODE)); should be performance or correctness)
     
    2632
    2733PERFFLAGS_CXX = $(PERFFLAGS_CC)
    28 PERFFLAGS_UXX = $(PERFFLAGS_CC)
     34PERFFLAGS_UXX = $(PERFFLAGS_CFA)
     35
     36CFLAGS=$(PERFFLAGS_CC) $(EXTRA_COMP_FLAGS)
    2937
    3038SHELL = /usr/bin/bash
     
    101109perfexp--%     driver--%.o     : COMPILER=NO-COMPILER-FOR-$(FX_COARSE)
    102110
     111# Without this %.d rule, ordinary make runs have noise about the recipe for driver--%.o being ill-formed when called on a *.d.
     112# https://stackoverflow.com/questions/3714041/why-does-this-makefile-execute-a-target-on-make-clean
     113# Whatever you -include gets called as a target first.
     114# One such example is driver--upp-upp--stack-insfirst-allhead.d
     115# Without this %.d rule, `make make driver--upp-upp--stack-insfirst-allhead.d` leads to the rule for driver--%.o firing.
     116# Though my dumb human eyes don't see the pattern as matching.
     117%.d:
     118        @touch $@
     119
    103120perfexp--% : driver--%.o observation.o
    104         $(COMPILER) $^ -o $@
     121        $(COMPILER) $(EXTRA_COMP_FLAGS) $^ -o $@
    105122
    106123driver--%.o : driver.c
    107         $(COMPILER) -c $< $(OP_DEFINES) -include op-$(OP).h -include fx-$(FX).h -o $@ -MMD
    108 
    109 
    110 
    111 
    112 RUN_NUM_REPS=3
     124        $(COMPILER) $(EXTRA_COMP_FLAGS) -c $< $(OP_DEFINES) -include op-$(OP).h -include fx-$(FX).h -o $@ -MMD
     125
     126sayhi:
     127        echo $(PERFPROGS)
     128
     129
     130ifeq "$(RUN_DATA_SIZE_MODE)" "common5"
     131RUN_DATA_SIZES=\
     132  7-1000000 \
     133  71-100000 \
     134  809-10000 \
     135  9051-1000 \
     136  72421-100
     137else ifeq "$(RUN_DATA_SIZE_MODE)" "thorough"
     138RUN_DATA_SIZES=\
     139  7-1000000 \
     140  11-100000 \
     141  13-100000 \
     142  19-100000 \
     143  29-100000 \
     144  37-100000 \
     145  53-100000 \
     146  71-100000 \
     147  101-10000 \
     148  149-10000 \
     149  211-10000 \
     150  283-10000 \
     151  401-10000 \
     152  569-10000 \
     153  809-10000 \
     154  1151-1000 \
     155  1601-1000 \
     156  2267-1000 \
     157  3203-1000 \
     158  4547-1000 \
     159  6473-1000 \
     160  9051-1000 \
     161  12809-100 \
     162  18119-100 \
     163  25601-100 \
     164  36209-100 \
     165  51203-100 \
     166  72421-100 \
     167  102407-10 \
     168  144817-10 \
     169  204803-10 \
     170  289637-10 \
     171  409609-10 \
     172  579263-10 \
     173  819229-10 \
     174  1158613-1 \
     175  1638431-1 \
     176  2317057-1 \
     177  3276803-1 \
     178  4634111-1 \
     179  6553621-1 \
     180  9268211-1
     181else ifeq "$(RUN_DATA_SIZE_MODE)" "manual"
     182ifeq "$(RUN_DATA_SIZES)" ""
     183$(error RUN_DATA_SIZE_MODE is manual but RUN_DATA_SIZES not given)
     184endif
     185else ifeq "$(RUN_DATA_SIZE_MODE)" "none"
     186# Assume user manages RUN_ARGS; empty RUN_ARGS just means run with compiled-in defaults
     187RUN_DATA_SIZES=none
     188else
     189$(error Bad RUN_DATA_SIZE_MODE ($(RUN_DATA_SIZE_MODE)); should be common5, thorough or manual)
     190endif
     191
    113192RUN_REP_IDS=$(shell echo {1..$(RUN_NUM_REPS)})              # 1 2 3
    114193RUN_REP_EXTS=$(call cross3,,run,$(RUN_REP_IDS),.1csv)       # run1.1csv run2.1cav run3.1csv
    115194
    116 RESULT1S=$(call cross,.,$(CORES),$(RUN_REP_EXTS))   # lq-tailq--stack-inslast-allhead.run2.1csv
     195RUN_LAUNCHES=$(call cross,--,$(RUN_DATA_SIZES),$(RUN_REP_EXTS))
     196
     197
     198
     199RESULT1S=$(call cross,.,$(CORES),$(RUN_LAUNCHES))   # lq-tailq--stack-inslast-allhead.run2.1csv
     200
    117201
    118202RESULT1S_SHUFD=$(shell shuf -e $(RESULT1S))
    119203
    120204%.1csv : CORE=$(basename $(basename $@))
    121 %.1csv : REP_ID=$(subst .run,,$(suffix $(basename $@)))
     205%.1csv : LAUNCH=$(subst .,,$(suffix $(basename $@)))
     206%.1csv : SIZING=$(call proj,--,$(LAUNCH),1)
     207%.1csv : NUMNODES=$(call proj,-,$(SIZING),1)
     208%.1csv : CHECKDONE=$(call proj,-,$(SIZING),2)
     209%.1csv : REP_ID=$(subst run,,$(call proj,--,$(LAUNCH),2))
     210%.1csv : RUN_ARGS=$(if $(filter none,$(SIZING)),,$(RUN_DURATION_SEC) $(CHECKDONE) $(NUMNODES) -1 $(REP_ID))  # use REP_ID as seed
    122211%.1csv : REP_TIME=$(shell date '+%F %H:%M:%S')
    123212%.1csv : perfprogs FORCE
    124         ./perfexp--$(CORE) $(RUNARGS) | xargs -n 1 printf '%s,%s,%s\n' "$(REP_TIME)" "$(REP_ID)" | tee $@
     213        taskset --cpu-list $(RUN_TASKSET_CPULIST) ./perfexp--$(CORE) $(RUN_ARGS) | xargs -n 1 printf '%s,%s,%s,%s\n' "$(REP_TIME)" "$(REP_ID)" "$(RUN_ARGS)" | tee $@
     214
    125215
    126216BATCHTIME=$(shell date '+%F--%H-%M-%S')
     
    146236.PRECIOUS: result--%.1csv driver--%.o perfexp--% %.o
    147237
    148 
    149238-include *.d
Note: See TracChangeset for help on using the changeset viewer.