diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/.gitignore b/hpvm/test/hpvm-cava/.gitignore similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/.gitignore rename to hpvm/test/hpvm-cava/.gitignore diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/CREDITS.TXT b/hpvm/test/hpvm-cava/CREDITS.TXT similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/CREDITS.TXT rename to hpvm/test/hpvm-cava/CREDITS.TXT diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/LICENSE b/hpvm/test/hpvm-cava/LICENSE similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/LICENSE rename to hpvm/test/hpvm-cava/LICENSE diff --git a/hpvm/test/hpvm-cava/Makefile b/hpvm/test/hpvm-cava/Makefile new file mode 100644 index 0000000000000000000000000000000000000000..5ec91833ea9de6a2ff49d8c4e5571184ccb61145 --- /dev/null +++ b/hpvm/test/hpvm-cava/Makefile @@ -0,0 +1,132 @@ +# This Makefile compiles the HPVM-CAVA pilot project. +# It builds HPVM-related dependencies, then the native camera pipeline ISP code. +# +# Paths to some dependencies (e.g., HPVM, LLVM) must exist in Makefile.config, +# which can be copied from Makefile.config.example for a start. + +CONFIG_FILE := Makefile.config + +ifeq ($(wildcard $(CONFIG_FILE)),) + $(error $(CONFIG_FILE) not found. See $(CONFIG_FILE).example) +endif +include $(CONFIG_FILE) + +# Compiler Flags + +LFLAGS += -lm -lrt + +# Build dirs +ifeq ($(VERSION),) + VERSION = Default +endif +SRC_DIR = src/ +CAM_PIPE_SRC_DIR = $(SRC_DIR) +BUILD_DIR = build/$(TARGET)_$(VERSION) +CURRENT_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) + + +INCLUDES += -I$(SRC_DIR) \ + -I$(CAM_PIPE_SRC_DIR) \ + +ifneq ($(CONFUSE_ROOT),) +INCLUDES += -I$(CONFUSE_ROOT)/include +LFLAGS += -L$(CONFUSE_ROOT)/lib +endif + +EXE = cava-visc-$(VERSION)-$(TARGET) + +LFLAGS += -pthread + +## BEGIN HPVM MAKEFILE +LANGUAGE=visc +SRCDIR_OBJS= load_cam_model.ll cam_pipe_utility.ll dma_interface.ll utility.ll +OBJS_SRC=src/cam_pipe.c src/pipe_stages.c src/load_cam_model.c src/cam_pipe_utility.c src/dma_interface.c src/utility.c +VISC_OBJS=main.visc.ll +APP = $(EXE) +APP_CUDALDFLAGS=-lm -lstdc++ +APP_CFLAGS= $(INCLUDES) -DDMA_MODE -DDMA_INTERFACE_V3 +APP_CXXFLAGS=-ffast-math -O0 -I/opt/opencv/include +APP_LDFLAGS=$(LFLAGS) + +CFLAGS = -O1 $(APP_CFLAGS) $(PLATFORM_CFLAGS) +OBJS_CFLAGS = -O1 $(APP_CFLAGS) $(PLATFORM_CFLAGS) +CXXFLAGS = $(APP_CXXFLAGS) $(PLATFORM_CXXFLAGS) +LDFLAGS= $(APP_LDFLAGS) $(PLATFORM_LDFLAGS) + +VISC_RT_PATH = $(LLVM_SRC_ROOT)/tools/hpvm/projects/visc-rt + +VISC_RT_LIB = $(VISC_RT_PATH)/visc-rt.ll + + +TESTGEN_OPTFLAGS = -load LLVMGenVISC.so -genvisc -globaldce + +ifeq ($(TARGET),seq) + DEVICE = CPU_TARGET + VISC_OPTFLAGS = -load LLVMBuildDFG.so -load LLVMDFG2LLVM_X86.so -load LLVMClearDFG.so -dfg2llvm-x86 -clearDFG + VISC_OPTFLAGS += -visc-timers-x86 +else + DEVICE = GPU_TARGET + VISC_OPTFLAGS = -load LLVMBuildDFG.so -load LLVMLocalMem.so -load LLVMDFG2LLVM_NVPTX.so -load LLVMDFG2LLVM_X86.so -load LLVMClearDFG.so -localmem -dfg2llvm-nvptx -dfg2llvm-x86 -clearDFG + VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-ptx +endif + TESTGEN_OPTFLAGS += -visc-timers-gen + +CFLAGS += -DDEVICE=$(DEVICE) +CXXFLAGS += -DDEVICE=$(DEVICE) + +# Add BUILDDIR as a prefix to each element of $1 +INBUILDDIR=$(addprefix $(BUILD_DIR)/,$(1)) + +.PRECIOUS: $(BUILD_DIR)/%.ll + +OBJS = $(call INBUILDDIR,$(SRCDIR_OBJS)) +TEST_OBJS = $(call INBUILDDIR,$(VISC_OBJS)) +KERNEL = $(TEST_OBJS).kernels.ll + +ifeq ($(TARGET),seq) +else + KERNEL_LINKED = $(BUILD_DIR)/$(APP).kernels.linked.ll + KERNEL_OCL = $(TEST_OBJS).kernels.cl +endif + +HOST_LINKED = $(BUILD_DIR)/$(APP).linked.ll +HOST = $(BUILD_DIR)/$(APP).host.ll + +ifeq ($(OPENCL_PATH),) +FAILSAFE=no_opencl +else +FAILSAFE= +endif + +# Targets +default: $(FAILSAFE) $(BUILD_DIR) $(KERNEL_OCL) $(EXE) +#default: $(FAILSAFE) $(BUILD_DIR) $(KERNEL_OCL) $(SPIR_ASSEMBLY) $(AOC_CL) $(AOCL_ASSEMBLY) $(EXE) + +$(KERNEL_OCL) : $(KERNEL) + $(OCLBE) --debug $< -o $@ + +$(EXE) : $(HOST_LINKED) + $(CXX) -O3 $(LDFLAGS) $< -o $@ + +$(HOST_LINKED) : $(HOST) $(OBJS) $(VISC_RT_LIB) + $(LLVM_LINK) $^ -S -o $@ + +$(VISC_RT_LIB) : $(VISC_RT_PATH)/visc-rt.cpp + make -C $(LLVM_LIB_PATH) + +$(HOST) $(KERNEL): $(BUILD_DIR)/$(VISC_OBJS) + $(OPT) -debug $(VISC_OPTFLAGS) -S $< -o $(HOST) + +$(BUILD_DIR): + mkdir -p $(BUILD_DIR) + +$(BUILD_DIR)/%.ll : $(SRC_DIR)/%.c + $(CC) $(OBJS_CFLAGS) -emit-llvm -S -o $@ $< + +$(BUILD_DIR)/main.ll : $(SRC_DIR)/main.c + $(CC) $(CFLAGS) -emit-llvm -S -o $@ $< + +$(BUILD_DIR)/main.visc.ll : $(BUILD_DIR)/main.ll + $(OPT) -debug-only=genvisc $(TESTGEN_OPTFLAGS) $< -S -o $@ + +## END HPVM MAKEFILE diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/Makefile.config.example b/hpvm/test/hpvm-cava/Makefile.config.example similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/Makefile.config.example rename to hpvm/test/hpvm-cava/Makefile.config.example diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/README.md b/hpvm/test/hpvm-cava/README.md similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/README.md rename to hpvm/test/hpvm-cava/README.md diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/README.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/README.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/README.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/README.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_coefs.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_coefs.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_coefs.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_coefs.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_ctrlPoints.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_ctrlPoints.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_ctrlPoints.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_ctrlPoints.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_destPoints.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_destPoints.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_destPoints.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_destPoints.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_respFcns.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_respFcns.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_respFcns.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_respFcns.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_transform.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_transform.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_transform.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_transform.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_validRange.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_validRange.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/jpg2raw_validRange.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/jpg2raw_validRange.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_coefs.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_coefs.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_coefs.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_coefs.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_coefs_debug.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_coefs_debug.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_coefs_debug.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_coefs_debug.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_ctrlPoints.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_ctrlPoints.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_ctrlPoints.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_ctrlPoints.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_ctrlPoints_debug.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_ctrlPoints_debug.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_ctrlPoints_debug.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_ctrlPoints_debug.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_destPoints.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_destPoints.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_destPoints.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_destPoints.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_respFcns.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_respFcns.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_respFcns.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_respFcns.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_transform.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_transform.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_transform.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_transform.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_validRange.txt b/hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_validRange.txt similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/cam_models/NikonD7000/raw2jpg_validRange.txt rename to hpvm/test/hpvm-cava/cam_models/NikonD7000/raw2jpg_validRange.txt diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/convert.sh b/hpvm/test/hpvm-cava/convert.sh similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/convert.sh rename to hpvm/test/hpvm-cava/convert.sh diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/docs/hpvm-cava_single-node.png b/hpvm/test/hpvm-cava/docs/hpvm-cava_single-node.png similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/docs/hpvm-cava_single-node.png rename to hpvm/test/hpvm-cava/docs/hpvm-cava_single-node.png diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-face/README.md b/hpvm/test/hpvm-cava/example-face/README.md similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-face/README.md rename to hpvm/test/hpvm-cava/example-face/README.md diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulip-small/raw_tulip-small.bin b/hpvm/test/hpvm-cava/example-tulip-small/raw_tulip-small.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulip-small/raw_tulip-small.bin rename to hpvm/test/hpvm-cava/example-tulip-small/raw_tulip-small.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._raw_tulips.bin b/hpvm/test/hpvm-cava/example-tulips/._raw_tulips.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._raw_tulips.bin rename to hpvm/test/hpvm-cava/example-tulips/._raw_tulips.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._raw_tulips.png b/hpvm/test/hpvm-cava/example-tulips/._raw_tulips.png similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._raw_tulips.png rename to hpvm/test/hpvm-cava/example-tulips/._raw_tulips.png diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips.bin b/hpvm/test/hpvm-cava/example-tulips/._tulips.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips.bin rename to hpvm/test/hpvm-cava/example-tulips/._tulips.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips.png b/hpvm/test/hpvm-cava/example-tulips/._tulips.png similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips.png rename to hpvm/test/hpvm-cava/example-tulips/._tulips.png diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_demosaic.bin b/hpvm/test/hpvm-cava/example-tulips/._tulips_demosaic.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_demosaic.bin rename to hpvm/test/hpvm-cava/example-tulips/._tulips_demosaic.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_demosaic.png b/hpvm/test/hpvm-cava/example-tulips/._tulips_demosaic.png similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_demosaic.png rename to hpvm/test/hpvm-cava/example-tulips/._tulips_demosaic.png diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_denoise.bin b/hpvm/test/hpvm-cava/example-tulips/._tulips_denoise.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_denoise.bin rename to hpvm/test/hpvm-cava/example-tulips/._tulips_denoise.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_denoise.png b/hpvm/test/hpvm-cava/example-tulips/._tulips_denoise.png similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_denoise.png rename to hpvm/test/hpvm-cava/example-tulips/._tulips_denoise.png diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_gamut.bin b/hpvm/test/hpvm-cava/example-tulips/._tulips_gamut.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_gamut.bin rename to hpvm/test/hpvm-cava/example-tulips/._tulips_gamut.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_gamut.png b/hpvm/test/hpvm-cava/example-tulips/._tulips_gamut.png similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_gamut.png rename to hpvm/test/hpvm-cava/example-tulips/._tulips_gamut.png diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_tone.bin b/hpvm/test/hpvm-cava/example-tulips/._tulips_tone.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_tone.bin rename to hpvm/test/hpvm-cava/example-tulips/._tulips_tone.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_tone.png b/hpvm/test/hpvm-cava/example-tulips/._tulips_tone.png similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_tone.png rename to hpvm/test/hpvm-cava/example-tulips/._tulips_tone.png diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_transform.bin b/hpvm/test/hpvm-cava/example-tulips/._tulips_transform.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_transform.bin rename to hpvm/test/hpvm-cava/example-tulips/._tulips_transform.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_transform.png b/hpvm/test/hpvm-cava/example-tulips/._tulips_transform.png similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/._tulips_transform.png rename to hpvm/test/hpvm-cava/example-tulips/._tulips_transform.png diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/raw_tulips.bin b/hpvm/test/hpvm-cava/example-tulips/raw_tulips.bin similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/example-tulips/raw_tulips.bin rename to hpvm/test/hpvm-cava/example-tulips/raw_tulips.bin diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/run-camera-pipeline.sh b/hpvm/test/hpvm-cava/run-camera-pipeline.sh similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/run-camera-pipeline.sh rename to hpvm/test/hpvm-cava/run-camera-pipeline.sh diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/Makefile b/hpvm/test/hpvm-cava/scripts/Makefile similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/Makefile rename to hpvm/test/hpvm-cava/scripts/Makefile diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/cmodule.py b/hpvm/test/hpvm-cava/scripts/cmodule.py similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/cmodule.py rename to hpvm/test/hpvm-cava/scripts/cmodule.py diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/convert_image.py b/hpvm/test/hpvm-cava/scripts/convert_image.py similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/convert_image.py rename to hpvm/test/hpvm-cava/scripts/convert_image.py diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/gamut_map.cc b/hpvm/test/hpvm-cava/scripts/gamut_map.cc similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/gamut_map.cc rename to hpvm/test/hpvm-cava/scripts/gamut_map.cc diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/gamut_map.h b/hpvm/test/hpvm-cava/scripts/gamut_map.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/gamut_map.h rename to hpvm/test/hpvm-cava/scripts/gamut_map.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/gamut_map.i b/hpvm/test/hpvm-cava/scripts/gamut_map.i similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/gamut_map.i rename to hpvm/test/hpvm-cava/scripts/gamut_map.i diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/gamut_map_wrap.cc b/hpvm/test/hpvm-cava/scripts/gamut_map_wrap.cc similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/gamut_map_wrap.cc rename to hpvm/test/hpvm-cava/scripts/gamut_map_wrap.cc diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/load_and_convert.py b/hpvm/test/hpvm-cava/scripts/load_and_convert.py similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/load_and_convert.py rename to hpvm/test/hpvm-cava/scripts/load_and_convert.py diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/numpy.i b/hpvm/test/hpvm-cava/scripts/numpy.i similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/numpy.i rename to hpvm/test/hpvm-cava/scripts/numpy.i diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/scripts/split_trace.py b/hpvm/test/hpvm-cava/scripts/split_trace.py similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/scripts/split_trace.py rename to hpvm/test/hpvm-cava/scripts/split_trace.py diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/cam-vision-native b/hpvm/test/hpvm-cava/src/cam-vision-native similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/cam-vision-native rename to hpvm/test/hpvm-cava/src/cam-vision-native diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/cam_pipe.c b/hpvm/test/hpvm-cava/src/cam_pipe.c similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/cam_pipe.c rename to hpvm/test/hpvm-cava/src/cam_pipe.c diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/cam_pipe.h b/hpvm/test/hpvm-cava/src/cam_pipe.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/cam_pipe.h rename to hpvm/test/hpvm-cava/src/cam_pipe.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/cam_pipe_utility.c b/hpvm/test/hpvm-cava/src/cam_pipe_utility.c similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/cam_pipe_utility.c rename to hpvm/test/hpvm-cava/src/cam_pipe_utility.c diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/cam_pipe_utility.h b/hpvm/test/hpvm-cava/src/cam_pipe_utility.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/cam_pipe_utility.h rename to hpvm/test/hpvm-cava/src/cam_pipe_utility.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/defs.h b/hpvm/test/hpvm-cava/src/defs.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/defs.h rename to hpvm/test/hpvm-cava/src/defs.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/dma_interface.c b/hpvm/test/hpvm-cava/src/dma_interface.c similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/dma_interface.c rename to hpvm/test/hpvm-cava/src/dma_interface.c diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/dma_interface.h b/hpvm/test/hpvm-cava/src/dma_interface.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/dma_interface.h rename to hpvm/test/hpvm-cava/src/dma_interface.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/gem5_harness.h b/hpvm/test/hpvm-cava/src/gem5_harness.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/gem5_harness.h rename to hpvm/test/hpvm-cava/src/gem5_harness.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/load_cam_model.c b/hpvm/test/hpvm-cava/src/load_cam_model.c similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/load_cam_model.c rename to hpvm/test/hpvm-cava/src/load_cam_model.c diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/load_cam_model.h b/hpvm/test/hpvm-cava/src/load_cam_model.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/load_cam_model.h rename to hpvm/test/hpvm-cava/src/load_cam_model.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/main.c b/hpvm/test/hpvm-cava/src/main.c similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/main.c rename to hpvm/test/hpvm-cava/src/main.c diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/pipe_stages.c b/hpvm/test/hpvm-cava/src/pipe_stages.c similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/pipe_stages.c rename to hpvm/test/hpvm-cava/src/pipe_stages.c diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/pipe_stages.h b/hpvm/test/hpvm-cava/src/pipe_stages.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/pipe_stages.h rename to hpvm/test/hpvm-cava/src/pipe_stages.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/rename.sh b/hpvm/test/hpvm-cava/src/rename.sh similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/rename.sh rename to hpvm/test/hpvm-cava/src/rename.sh diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/utility.c b/hpvm/test/hpvm-cava/src/utility.c similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/utility.c rename to hpvm/test/hpvm-cava/src/utility.c diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/utility.h b/hpvm/test/hpvm-cava/src/utility.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/utility.h rename to hpvm/test/hpvm-cava/src/utility.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/src/visc.h b/hpvm/test/hpvm-cava/src/visc.h similarity index 100% rename from hpvm/test/parboil/benchmarks/hpvm-cava/src/visc.h rename to hpvm/test/hpvm-cava/src/visc.h diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/Makefile b/hpvm/test/parboil/benchmarks/hpvm-cava/Makefile deleted file mode 100644 index d51743070ca51aaed137c730b99045e94c378c36..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/hpvm-cava/Makefile +++ /dev/null @@ -1,250 +0,0 @@ -# This Makefile compiles the HPVM-CAVA pilot project. -# It builds HPVM-related dependencies, then the native camera pipeline ISP code. -# -# Paths to some dependencies (e.g., HPVM, LLVM) must exist in Makefile.config, -# which can be copied from Makefile.config.example for a start. - -CONFIG_FILE := Makefile.config - -ifeq ($(wildcard $(CONFIG_FILE)),) - $(error $(CONFIG_FILE) not found. See $(CONFIG_FILE).example) -endif -include $(CONFIG_FILE) - -# Compiler Flags - -DLEVEL ?= 0 -#CAM_CFLAGS?=-O0 \ - #-Wno-psabi \ - #-Wno-unused-label -Wno-unused-but-set-variable \ - #-Wno-maybe-uninitialized -DARCHITECTURE=SMV -DTRANSPOSE_WEIGHTS=1 \ - -DDEBUG_LEVEL=$(DLEVEL) -LFLAGS += -lm -lrt - -# Build dirs -ifeq ($(VERSION),) - VERSION = Default -endif -SRC_DIR = src/ -CAM_PIPE_SRC_DIR = $(SRC_DIR) -BUILD_DIR = build/$(TARGET)_$(VERSION) -CURRENT_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) - -# Source files for the frontend camera pipeline -COMMON_SRCS = main.c \ - utility.c - - -CAM_PIPE_SRCS = load_cam_model.c \ - cam_pipe_utility.c \ - dma_interface.c # FIXME: This is a hack until external C++ files can be included in build. - - -# NOTE: We have temporarily removed gem5 and other dependencies for simplicity. -SRCS = $(COMMON_SRCS) $(CAM_PIPE_SRCS) -#GEM5_DMA_SRC = gem5/dma_interface.c -#GEM5_SYS_SRCS = gem5/aladdin_sys_connection.cpp gem5/aladdin_sys_constants.cpp -#GEM5_UTIL_SRCS = ../../util/m5/m5op_x86.S - -# NATIVE_FULL_PATH_SRCS contains all the full path source files for the camera vision pipeline. -NATIVE_FULL_PATH_SRCS = $(patsubst %, $(SRC_DIR)/%, $(COMMON_SRCS)) -NATIVE_FULL_PATH_SRCS += $(patsubst %, $(CAM_PIPE_SRC_DIR)/%, $(CAM_PIPE_SRCS)) - -# GEM5_FULL_PATH_SRCS contains all the full path source files for the gem5 files. -#GEM5_FULL_PATH_SRCS = $(patsubst %, $(ALADDIN_HOME)/%, $(GEM5_DMA_SRC) $(GEM5_SYS_SRCS) $(GEM5_UTIL_SRCS)) - -#INCLUDES += -I$(ALADDIN_HOME) \ -# -I$(ALADDIN_HOME)/../../include \ -# -I$(ALADDIN_HOME)/gem5 -INCLUDES += -I$(SRC_DIR) \ - -I$(CAM_PIPE_SRC_DIR) \ - -ifneq ($(CONFUSE_ROOT),) -INCLUDES += -I$(CONFUSE_ROOT)/include -LFLAGS += -L$(CONFUSE_ROOT)/lib -endif - -EXE = cava-visc-$(VERSION)-$(TARGET) - -CAM_CFLAGS += -mf16c -flax-vector-conversions -LFLAGS += -pthread - -#$(DEBUG): $(NATIVE_FULL_PATH_SRCS) $(GEM5_FULL_PATH_SRCS) -# @echo Building benchmark for native machine with debug support. -# #@mkdir -p $(BUILD_DIR) -# @$(CC) $(CAM_CFLAGS) -ggdb3 $(INCLUDES) -DGEM5 -DDMA_MODE -DDMA_INTERFACE_V3 -o $(DEBUG) $^ $(LFLAGS) -# -#clean-native: -# rm -f $(NATIVE) $(DEBUG) - -## BEGIN HPVM MAKEFILE -LANGUAGE=visc -SRCDIR_OBJS= load_cam_model.ll cam_pipe_utility.ll dma_interface.ll utility.ll -OBJS_SRC=src/cam_pipe.c src/pipe_stages.c src/load_cam_model.c src/cam_pipe_utility.c src/dma_interface.c src/utility.c -VISC_OBJS=main.visc.ll -APP = $(EXE) -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS= $(INCLUDES) -DDMA_MODE -DDMA_INTERFACE_V3 -APP_CXXFLAGS=-ffast-math -O0 -I/opt/opencv/include -APP_LDFLAGS=$(LFLAGS) - -CFLAGS = -O1 $(APP_CFLAGS) $(PLATFORM_CFLAGS) -OBJS_CFLAGS = -O1 $(APP_CFLAGS) $(PLATFORM_CFLAGS) -CXXFLAGS = $(APP_CXXFLAGS) $(PLATFORM_CXXFLAGS) -LDFLAGS= $(APP_LDFLAGS) $(PLATFORM_LDFLAGS) - -LIBCLC_LIB_PATH = $(LLVM_SRC_ROOT)/../libclc/built_libs -VISC_RT_PATH = $(LLVM_SRC_ROOT)/tools/hpvm/projects/visc-rt - -VISC_RT_LIB = $(VISC_RT_PATH)/visc-rt.ll -#LIBCLC_NVPTX_LIB = $(LIBCLC_LIB_PATH)/nvptx--nvidiacl.bc -LIBCLC_NVPTX_LIB = $(LIBCLC_LIB_PATH)/nvptx64--nvidiacl.bc -#LIBCLC_NVPTX_LIB = nvptx64--nvidiacl.bc - -LLVM_34_AS = $(LLVM_34_ROOT)/build/bin/llvm-as - -TESTGEN_OPTFLAGS = -load LLVMGenVISC.so -genvisc -globaldce -KERNEL_GEN_FLAGS = -O3 -target nvptx64-nvidia-nvcl - -ifeq ($(TARGET),x86) - DEVICE = SPIR_TARGET - VISC_OPTFLAGS = -load LLVMBuildDFG.so -load LLVMLocalMem.so -load LLVMDFG2LLVM_SPIR.so -load LLVMDFG2LLVM_X86.so -load LLVMClearDFG.so -localmem -dfg2llvm-spir -dfg2llvm-x86 -clearDFG - CFLAGS += -DOPENCL_CPU - VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-spir -else ifeq ($(TARGET),seq) - DEVICE = CPU_TARGET - VISC_OPTFLAGS = -load LLVMBuildDFG.so -load LLVMDFG2LLVM_X86.so -load LLVMClearDFG.so -dfg2llvm-x86 -clearDFG - VISC_OPTFLAGS += -visc-timers-x86 -else ifeq ($(TARGET),fpga) - DEVICE = FPGA_TARGET - VISC_OPTFLAGS = -load LLVMBuildDFG.so -load LLVMLocalMem.so -load LLVMDFG2LLVM_FPGA.so -load LLVMDFG2LLVM_X86.so -load LLVMClearDFG.so -localmem -dfg2llvm-fpga -dfg2llvm-x86 -clearDFG - CFLAGS += -DOPENCL_CPU - VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-fpga -else - DEVICE = GPU_TARGET - VISC_OPTFLAGS = -load LLVMBuildDFG.so -load LLVMLocalMem.so -load LLVMDFG2LLVM_NVPTX.so -load LLVMDFG2LLVM_X86.so -load LLVMClearDFG.so -localmem -dfg2llvm-nvptx -dfg2llvm-x86 -clearDFG - VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-ptx -endif - TESTGEN_OPTFLAGS += -visc-timers-gen - -CFLAGS += -DDEVICE=$(DEVICE) -CXXFLAGS += -DDEVICE=$(DEVICE) - -#ifeq ($(TIMER),x86) -# VISC_OPTFLAGS += -visc-timers-x86 -#else ifeq ($(TIMER),ptx) -# VISC_OPTFLAGS += -visc-timers-ptx -#else ifeq ($(TIMER),gen) -# TESTGEN_OPTFLAGS += -visc-timers-gen -#else ifeq ($(TIMER),spir) -# TESTGEN_OPTFLAGS += -visc-timers-spir -#else ifeq ($(TIMER),fpga) -# TESTGEN_OPTFLAGS += -visc-timers-fpga -#else ifeq ($(TIMER),no) -#else -# ifeq ($(TARGET),x86) -# VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-spir -# else ifeq ($(TARGET),seq) -# VISC_OPTFLAGS += -visc-timers-x86 -# else ifeq ($(TARGET),fpga) -# VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-fpga -# else ifeq ($(TARGET),seqx86) -# VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-spir -# else ifeq ($(TARGET),seqgpu) -# VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-ptx -# else -# VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-ptx -# endif -# TESTGEN_OPTFLAGS += -visc-timers-gen -#endif - -# Add BUILDDIR as a prefix to each element of $1 -INBUILDDIR=$(addprefix $(BUILD_DIR)/,$(1)) - -# Add SRCDIR as a prefix to each element of $1 -#INSRCDIR=$(addprefix $(SRCDIR)/,$(1)) - -PYTHON_LLVM_40_34 = ../llvm-40-34.py - -.PRECIOUS: $(BUILD_DIR)/%.ll - -OBJS = $(call INBUILDDIR,$(SRCDIR_OBJS)) -TEST_OBJS = $(call INBUILDDIR,$(VISC_OBJS)) -KERNEL = $(TEST_OBJS).kernels.ll - -ifeq ($(TARGET),x86) - SPIR_ASSEMBLY = $(TEST_OBJS).kernels.bc -else ifeq ($(TARGET),seq) -else ifeq ($(TARGET),fpga) - AOC_CL = $(TEST_OBJS).kernels.cl - AOCL_ASSEMBLY = $(TEST_OBJS).kernels.aocx - BOARD = a10gx - ifeq ($(EMULATION),1) - EXE = cava-visc-emu - AOC_EMU = -march=emulator - BUILD_DIR = build/$(TARGET)-emu - endif -else - KERNEL_LINKED = $(BUILD_DIR)/$(APP).kernels.linked.ll - #KERNEL = $(TEST_OBJS).kernels.ll - KERNEL_OCL = $(TEST_OBJS).kernels.cl -endif - -HOST_LINKED = $(BUILD_DIR)/$(APP).linked.ll -HOST = $(BUILD_DIR)/$(APP).host.ll - -ifeq ($(OPENCL_PATH),) -FAILSAFE=no_opencl -else -FAILSAFE= -endif - -# Targets -default: $(FAILSAFE) $(BUILD_DIR) $(KERNEL_OCL) $(EXE) -#default: $(FAILSAFE) $(BUILD_DIR) $(KERNEL_OCL) $(SPIR_ASSEMBLY) $(AOC_CL) $(AOCL_ASSEMBLY) $(EXE) - -$(KERNEL_OCL) : $(KERNEL) - $(OCLBE) --debug $< -o $@ - -$(SPIR_ASSEMBLY) : $(KERNEL) - python $(PYTHON_LLVM_40_34) $< $(BUILD_DIR)/kernel_34.ll - $(LLVM_34_AS) $(BUILD_DIR)/kernel_34.ll -o $@ - -$(AOCL_ASSEMBLY) : $(AOC_CL) - aoc --report $(AOC_EMU) $(AOC_CL) -o $(AOCL_ASSEMBLY) -board=$(BOARD) - -$(AOC_CL) : $(KERNEL) - llvm-cbe --debug $(KERNEL) - -$(EXE) : $(HOST_LINKED) - $(CXX) -O3 $(LDFLAGS) $< -o $@ - -$(HOST_LINKED) : $(HOST) $(OBJS) $(VISC_RT_LIB) - $(LLVM_LINK) $^ -S -o $@ - -$(VISC_RT_LIB) : $(VISC_RT_PATH)/visc-rt.cpp - make -C $(LLVM_LIB_PATH) - -$(HOST) $(KERNEL): $(BUILD_DIR)/$(VISC_OBJS) - $(OPT) -debug $(VISC_OPTFLAGS) -S $< -o $(HOST) -# mv *.ll $(BUILD_DIR) -# $(OPT) -debug-only=DFG2LLVM_SPIR,DFG2LLVM_X86,DFG2LLVM_FPGA,GENVISC $(VISC_OPTFLAGS) -S $< -o $(HOST) -#$(OBJS): $(OBJS_SRC) -# $(CC) $(OBJS_CFLAGS) -emit-llvm -S -o $@ $< - -$(BUILD_DIR): - mkdir -p $(BUILD_DIR) - -$(BUILD_DIR)/%.ll : $(SRC_DIR)/%.c - $(CC) $(OBJS_CFLAGS) -emit-llvm -S -o $@ $< - -$(BUILD_DIR)/main.ll : $(SRC_DIR)/main.c - $(CC) $(CFLAGS) -emit-llvm -S -o $@ $< - -#$(BUILD_DIR)/main.opt.ll : $(BUILD_DIR)/main.ll -# $(OPT) $(OPT_FLAGS) $< -S -o $@ - -$(BUILD_DIR)/main.visc.ll : $(BUILD_DIR)/main.ll - $(OPT) -debug-only=genvisc $(TESTGEN_OPTFLAGS) $< -S -o $@ - -## END HPVM MAKEFILE diff --git a/hpvm/test/parboil/benchmarks/hpvm-cava/Makefile.config b/hpvm/test/parboil/benchmarks/hpvm-cava/Makefile.config deleted file mode 100644 index 9ece12fe0eade697640611f2810afd42d17727cf..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/hpvm-cava/Makefile.config +++ /dev/null @@ -1,29 +0,0 @@ -CUDA_PATH=/usr/local/cuda -CUDA_LIB_PATH=/usr/local/cuda/lib64 -#OPENCL_PATH=/opt/intelFPGA_pro/18.0/hld/host/linux64 -#OPENCL_LIB_PATH=$(OPENCL_PATH)/lib -OPENCL_PATH=/opt/intel/opencl-sdk/ -OPENCL_LIB_PATH=$(OPENCL_PATH)/lib64 - -LLVM_SRC_ROOT=/home/aejjeh/work_dir/hpvm-reorg-9/hpvm/llvm/ -# NOTE: You may need to configure this based on your root path. -VISC_SRC_ROOT=$(LLVM_SRC_ROOT) - -VISC_BUILD_DIR =$(VISC_SRC_ROOT)/../build -CC = $(VISC_BUILD_DIR)/bin/clang -PLATFORM_CFLAGS = -I$(LLVM_SRC_ROOT)/include -I$(VISC_BUILD_DIR)/include -OCLBE = $(VISC_BUILD_DIR)/bin/llvm-cbe - -CXX = $(VISC_BUILD_DIR)/bin/clang++ -PLATFORM_CXXFLAGS = -I$(LLVM_SRC_ROOT)/include -I$(VISC_BUILD_DIR)/include - -LINKER = $(VISC_BUILD_DIR)/bin/clang++ -PLATFORM_LDFLAGS = -lm -lpthread -lrt -lOpenCL -L$(OPENCL_LIB_PATH) - -LLVM_LIB_PATH = $(VISC_BUILD_DIR)/lib -LLVM_BIN_PATH = $(VISC_BUILD_DIR)/bin - -OPT = $(LLVM_BIN_PATH)/opt -LLVM_LINK = $(LLVM_BIN_PATH)/llvm-link -LLVM_AS = $(LLVM_BIN_PATH)/llvm-as -LIT = $(LLVM_BIN_PATH)/llvm-lit \ No newline at end of file diff --git a/hpvm/test/parboil/benchmarks/pipeline/Makefile b/hpvm/test/parboil/benchmarks/pipeline/Makefile deleted file mode 100644 index 5f0fd5b73066b1ebfc9211fa628d7f326c88ca5e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/Makefile +++ /dev/null @@ -1,55 +0,0 @@ -PARBOIL_ROOT = $(LLVM_SRC_ROOT)/tools/hpvm/test/parboil - -APP = pipeline - -#TARGET=x86 -# Default compile visc -ifeq ($(VERSION),) - VERSION = visc_parallel -endif - -# Default use small test case -ifeq ($(TEST),) - TEST = small -endif - -ifeq ($(PLATFORM),) -PLATFORM=default -endif - -ifeq ($(POS),) - POS = left -endif - -ifeq ($(POS),middle) - APP_CXXFLAGS+=-DMIDDLE -DNAME=$(NAME) -else ifeq ($(POS),right) - APP_CXXFLAGS+=-DRIGHT -DNAME=$(NAME) -endif - -BIN = $(addsuffix -$(VERSION), $(APP)) - -SRCDIR = src/$(VERSION) -BUILDDIR = build/$(VERSION)_$(PLATFORM) -DATASET_DIR ?= $(PARBOIL_ROOT)/datasets/$(APP) - -IMAGE = $(DATASET_DIR)/$(TEST)/input/edgetest_10.png -VIDEO1 = $(DATASET_DIR)/$(TEST)/input/taxi/taxi01.pgm -VIDEO = $(DATASET_DIR)/$(TEST)/input/bear/frame1.jpg -VIDEO3 = $(DATASET_DIR)/big/input/ski/frame1.jpg -VIDEO4 = $(DATASET_DIR)/big/input/formula1_scaled.mp4 -#VIDEO = $(DATASET_DIR)/$(TEST)/input/bird.avi -MATRIX = $(DATASET_DIR)/$(TEST)/input/matrix1.txt -REF_OUTPUT = $(DATASET_DIR)/$(TEST)/output/output.txt -RUNDIR = run/$(VERSION)/$(TEST) -OUTPUT = $(RUNDIR)/output.txt - -#ARGS = -i $(IMAGE) -o $(OUTPUT) -#ARGS = -i $(VIDEO1) -o $(OUTPUT) -#ARGS = -i $(VIDEO) -#ARGS = -i $(VIDEO3) -ARGS = -i $(VIDEO4) -#ARGS = -i $(MATRIX) -o $(OUTPUT) -#TOOL = tools/compare-output -TOOL=echo -include $(PARBOIL_ROOT)/common/mk/Makefile diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/Gradient/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/Gradient/Makefile deleted file mode 100644 index 6dc39540f209760564005b51d7fcbdd046eaac4b..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/Gradient/Makefile +++ /dev/null @@ -1,13 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=`pkg-config ${OpenCV_DIR}/lib/pkgconfig/opencv.pc --libs` -#APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/Gradient/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/Gradient/main.cc deleted file mode 100755 index 6d3a0fabdaa9503e692bc4a46f00d07e36fc66e3..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/Gradient/main.cc +++ /dev/null @@ -1,570 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 10000 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "GPU Pipeline - Input Video"; -std::string output_window = "GPU Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - float* Gx; - size_t bytesGx; - float* Gy; - size_t bytesGy; - float* G; - size_t bytesG; - long m; - long n; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - float* Gx, size_t bytesGx, - float* Gy, size_t bytesGy, - float* G, size_t bytesG, - long m, long n) { - args->I = I; - args->bytesI = bytesI; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->Gx = Gx; - args->bytesGx = bytesGx; - args->Gy = Gy; - args->bytesGy = bytesGy; - args->G = G; - args->bytesG = bytesG; - args->m = m; - args->n = n; -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void horizontal(float* Is, size_t bytesIs, - float* Sx, size_t bytesSx, - float* Gx, size_t bytesGx, - long m, long n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, Sx, 1, Gx); - - void* thisNode = __visc__getNode(); - long gx = __visc__getNodeInstanceID_x(thisNode); - long gy = __visc__getNodeInstanceID_y(thisNode); - - long gloc = gx + gy*n; - - float Val = 0; - - float gval; - long loadOffset; - - if ((gx < n) && (gy < m)) { - for (long i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) { - for (long j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Val += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - //Gy[gloc] += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - } - - //G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - Gx[gloc] = Val; - //__visc__return(m); - __visc__return(bytesSx); -} - -void WrapperHorizontal(float* Is, size_t bytesIs, - float* Sx, size_t bytesSx, - float* Gx, size_t bytesGx, - long m, long n) { - - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, Sx, 1, Gx); - - void* Node = __visc__createNode2D(horizontal, m, n); - __visc__bindIn(Node, 0, 0, 0); // Bind Is - __visc__bindIn(Node, 1, 1, 0); // Bind bytesIs - __visc__bindIn(Node, 2, 2, 0); // Bind Sx - __visc__bindIn(Node, 3, 3, 0); // Bind bytesSx - __visc__bindIn(Node, 4, 4, 0); // Bind Gx - __visc__bindIn(Node, 5, 5, 0); // Bind bytesGx - __visc__bindIn(Node, 6, 6, 0); // Bind m - __visc__bindIn(Node, 7, 7, 0); // Bind n - - __visc__bindOut(Node, 0, 0, 0); // bind output m - - -} - -void vertical(float* Is, size_t bytesIs, - float* Sy, size_t bytesSy, - float* Gy, size_t bytesGy, - long m, long n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, Sy, 1, Gy); - - void* thisNode = __visc__getNode(); - long gx = __visc__getNodeInstanceID_x(thisNode); - long gy = __visc__getNodeInstanceID_y(thisNode); - - long gloc = gx + gy*n; - - float Val = 0; - - float gval; - long loadOffset; - - if ((gx < n) && (gy < m)) { - for (long i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) { - for (long j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - //Val += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Val += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - } - - //G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - Gy[gloc] = Val; - //__visc__return(n); - __visc__return(bytesSy); -} - -void WrapperVertical(float* Is, size_t bytesIs, - float* Sy, size_t bytesSy, - float* Gy, size_t bytesGy, - long m, long n) { - - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, Sy, 1, Gy); - - void* Node = __visc__createNode2D(vertical, m, n); - __visc__bindIn(Node, 0, 0, 0); // Bind Is - __visc__bindIn(Node, 1, 1, 0); // Bind bytesIs - __visc__bindIn(Node, 2, 2, 0); // Bind Sy - __visc__bindIn(Node, 3, 3, 0); // Bind bytesSy - __visc__bindIn(Node, 4, 4, 0); // Bind Gy - __visc__bindIn(Node, 5, 5, 0); // Bind bytesGy - __visc__bindIn(Node, 6, 6, 0); // Bind m - __visc__bindIn(Node, 7, 7, 0); // Bind n - - __visc__bindOut(Node, 0, 0, 0); // bind output n - - -} - -void squareRoot(float* Gx, size_t bytesGx, - float* Gy, size_t bytesGy, - float* G, size_t bytesG, - long m, long n, - size_t bytesSx, size_t bytesSy) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Gx, Gy, 1, G); - - void* thisNode = __visc__getNode(); - long gx = __visc__getNodeInstanceID_x(thisNode); - long gy = __visc__getNodeInstanceID_y(thisNode); - - if ((gx < n) && (gy < m)) { - long index = gy*n+gx; - G[index] = __visc__sqrt(Gx[index]*Gx[index]+Gy[index]*Gy[index]); - } - - //__visc__return(m); - __visc__return(bytesG); -} - -void WrapperSquareRoot(float* Gx, size_t bytesGx, - float* Gy, size_t bytesGy, - float* G, size_t bytesG, - long m, long n, - size_t bytesSx, size_t bytesSy) { - - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Gx, Gy, 1, G); - - void* Node = __visc__createNode2D(squareRoot, m, n); - __visc__bindIn(Node, 0, 0, 0); // Bind Gx - __visc__bindIn(Node, 1, 1, 0); // Bind bytesGx - __visc__bindIn(Node, 2, 2, 0); // Bind Gy - __visc__bindIn(Node, 3, 3, 0); // Bind bytesGy - __visc__bindIn(Node, 4, 4, 0); // Bind G - __visc__bindIn(Node, 5, 5, 0); // Bind bytesG - __visc__bindIn(Node, 6, 6, 0); // Bind m - __visc__bindIn(Node, 7, 7, 0); // Bind n - __visc__bindIn(Node, 8, 8, 0); // Bind dummy 1 - __visc__bindIn(Node, 9, 9, 0); // Bind dummy 2 - - __visc__bindOut(Node, 0, 0, 0); // bind output m - - -} - -void Gradient(float* Is, size_t bytesIs,// 0 - float* Sx, size_t bytesSx, // 2 - float* Sy, size_t bytesSy, // 4 - float* Gx, size_t bytesGx, // 6 - float* Gy, size_t bytesGy, // 8 - float* G, size_t bytesG, // 10 - long m, long n) { // 12 - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 3, Gx, Gy, G); - void* HNode = __visc__createNode(WrapperHorizontal); - void* VNode = __visc__createNode(WrapperVertical); - void* SNode = __visc__createNode(WrapperSquareRoot); - - // Horizontal - __visc__bindIn(HNode, 0, 0, 1); // Bind Is - __visc__bindIn(HNode, 1, 1, 1); // Bind bytesIs - __visc__bindIn(HNode, 2, 2, 1); // Bind Sx - __visc__bindIn(HNode, 3, 3, 1); // Bind bytesSx - __visc__bindIn(HNode, 6, 4, 1); // Bind Gx - __visc__bindIn(HNode, 7, 5, 1); // Bind bytesGx - __visc__bindIn(HNode, 12, 6, 1); // Bind m - __visc__bindIn(HNode, 13, 7, 1); // Bind n - - // Erode - __visc__bindIn(VNode, 0, 0, 1); // Bind Is - __visc__bindIn(VNode, 1, 1, 1); // Bind bytesIs - __visc__bindIn(VNode, 4, 2, 1); // Bind Sy - __visc__bindIn(VNode, 5, 3, 1); // Bind bytesSy - __visc__bindIn(VNode, 8, 4, 1); // Bind Gy - __visc__bindIn(VNode, 9, 5, 1); // Bind bytesGy - __visc__bindIn(VNode, 12, 6, 1); // Bind m - __visc__bindIn(VNode, 13, 7, 1); // Bind n - - // Linear combination - __visc__bindIn(SNode, 6, 0, 1); // Bind Gx - __visc__bindIn(SNode, 7, 1, 1); // Bind bytesGx [Alt: Pass as edge from horizontal] - __visc__bindIn(SNode, 8, 2, 1); // Bind Gy - __visc__bindIn(SNode, 9, 3, 1); // Bind bytesGy [Alt: Pass as edge from vertical] - __visc__bindIn(SNode, 10, 4, 1); // Bind G - __visc__bindIn(SNode, 11, 5, 1); // Bind bytesG - __visc__bindIn(SNode, 12, 6, 1); // Bind m [Alt: Pass as edge from horizontal] - __visc__bindIn(SNode, 13, 7, 1); // Bind n [Alt: Pass as edge from vertical] - - //__visc__edge(HNode, SNode, 0, 0, 6, 1); // Get m from horizontal - //__visc__edge(VNode, SNode, 0, 0, 7, 1); // Get n from vertical - //__visc__edge(HNode, SNode, 0, 0, 1, 1); // Get bytesGx from horizontal - //__visc__edge(VNode, SNode, 0, 0, 3, 1); // Get bytesGy from vertical - __visc__edge(HNode, SNode, 0, 0, 8, 1); // Get bytes from horizontal - __visc__edge(VNode, SNode, 0, 0, 9, 1); // Get bytesGy from vertical - - __visc__bindOut(SNode, 0, 0, 1); // bind output bytesG - -} - -} -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Gx, Gy, G; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Gx = Mat(src.size[0], src.size[1], CV_32F); - Gy = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Gx.isContinuous() && Gy.isContinuous() && G.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(G, out, Size(HEIGHT, WIDTH)); - imshow(input_window, in); - imshow(output_window, out); - waitKey(0); - - //NUM_FRAMES = 20; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - packData(args, (float*)src.data, I_sz, - Sx, bytesSx, - Sy, bytesSy, - (float*)Gx.data, I_sz, - (float*)Gy.data, I_sz, - (float*)G.data, I_sz, - src.size[0], src.size[1] - ); - // Check if the total elements is a multiple of block size - int block_x = 256; - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, Gradient, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - //std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - llvm_visc_track_mem(Gx.data, I_sz); - llvm_visc_track_mem(Gy.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - - __visc__push(DFG, args); - __visc__pop(DFG); - - llvm_visc_request_mem(G.data, I_sz); - - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(G, out, Size(HEIGHT, WIDTH)); - imshow(output_window, out); - imshow(input_window, in); - waitKey(1); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - llvm_visc_untrack_mem(Gx.data); - llvm_visc_untrack_mem(Gy.data); - llvm_visc_untrack_mem(G.data); - - getNextFrame(cap, src); - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/Makefile deleted file mode 100644 index 6dc39540f209760564005b51d7fcbdd046eaac4b..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/Makefile +++ /dev/null @@ -1,13 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=`pkg-config ${OpenCV_DIR}/lib/pkgconfig/opencv.pc --libs` -#APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/main.cc deleted file mode 100755 index 72d6ba8569a484fcd67dafcb6c7c46f6369f96b1..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/GradientMerged/main.cc +++ /dev/null @@ -1,374 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 1 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "GPU Pipeline - Input Video"; -std::string output_window = "GPU Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - float* Gx; - size_t bytesGx; - float* Gy; - size_t bytesGy; - float* G; - size_t bytesG; - long m; - long n; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - float* Gx, size_t bytesGx, - float* Gy, size_t bytesGy, - float* G, size_t bytesG, - long m, long n) { - args->I = I; - args->bytesI = bytesI; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->Gx = Gx; - args->bytesGx = bytesGx; - args->Gy = Gy; - args->bytesGy = bytesGy; - args->G = G; - args->bytesG = bytesG; - args->m = m; - args->n = n; -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *Gxs, size_t bytesGxs, - float *Gys, size_t bytesGys, - float *G, size_t bytesG, - long m, long n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - long gx = __visc__getNodeInstanceID_x(thisNode); - long gy = __visc__getNodeInstanceID_y(thisNode); - - long gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - long loadOffset; - - if ((gx < n) && (gy < m)) { - for (long i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) { - for (long j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - //__visc__return(n); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *Gxs, size_t bytesGxs, - float *Gys, size_t bytesGys, - float *G, size_t bytesG, - long m, long n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 3, Gxs, Gys, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind Gxs - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesGxs - __visc__bindIn(CGNode, 8, 8, 0); // Bind Gys - __visc__bindIn(CGNode, 9, 9, 0); // Bind bytesGys - __visc__bindIn(CGNode, 10, 10, 0); // Bind G - __visc__bindIn(CGNode, 11, 11, 0); // Bind bytesG - __visc__bindIn(CGNode, 12, 12, 0); // Bind m - __visc__bindIn(CGNode, 13, 13, 0); // Bind n - - //__visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -} -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Gx, Gy, G; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Gx = Mat(src.size[0], src.size[1], CV_32F); - Gy = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Gx.isContinuous() && Gy.isContinuous() && G.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - //resize(src, in, Size(HEIGHT, WIDTH)); - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(input_window, in); - //imshow(output_window, out); - //waitKey(0); - - NUM_FRAMES = 100; - //pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - packData(args, (float*)src.data, I_sz, - Sx, bytesSx, - Sy, bytesSy, - (float*)Gx.data, I_sz, - (float*)Gy.data, I_sz, - (float*)G.data, I_sz, - src.size[0], src.size[1] - ); - // Check if the total elements is a multiple of block size - int block_x = 256; - assert(src.size[0]*src.size[1] % block_x == 0); - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - llvm_visc_track_mem(Gx.data, I_sz); - llvm_visc_track_mem(Gy.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - args->I = (float*) src.data; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - for(unsigned j=0; j<NUM_FRAMES; j++) { - //std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(0, WrapperComputeGradient, (void*)args); - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - llvm_visc_request_mem(G.data, I_sz); - - //resize(src, in, Size(HEIGHT, WIDTH)); - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //imshow(input_window, in); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - llvm_visc_untrack_mem(Gx.data); - llvm_visc_untrack_mem(Gy.data); - llvm_visc_untrack_mem(G.data); - - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - pb_FreeParameters(params); - - return 0; -} - - diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/Makefile deleted file mode 100644 index 6dc39540f209760564005b51d7fcbdd046eaac4b..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/Makefile +++ /dev/null @@ -1,13 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=`pkg-config ${OpenCV_DIR}/lib/pkgconfig/opencv.pc --libs` -#APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/main.cc deleted file mode 100755 index 26a3c7b4a90d8395b8cf0be497e53ffe76af8866..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/Laplacian/main.cc +++ /dev/null @@ -1,641 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 1 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "GPU Pipeline - Input Video"; -std::string output_window = "GPU Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* B; - size_t bytesB; - float* D; - size_t bytesD; - float* E; - size_t bytesE; - float* L; - size_t bytesL; - long m; - long n; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* B, size_t bytesB, - float* D, size_t bytesD, - float* E, size_t bytesE, - float* L, size_t bytesL, - long m, long n) { - args->I = I; - args->bytesI = bytesI; - args->B = B; - args->bytesB = bytesB; - args->D = D; - args->bytesD = bytesD; - args->E = E; - args->bytesE = bytesE; - args->L = L; - args->bytesL = bytesL; - args->m = m; - args->n = n; -} - -void dilate(float* Is, size_t bytesIs, - float* B, size_t bytesB, - float* D, size_t bytesD, - long m, long n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, D); - - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - long gx = __visc__getNodeInstanceID_x(thisNode); - long gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - D[gy*n+gx] = dilatedPixel; - } - //__visc__return(m); - __visc__return(bytesB); -} - -void WrapperDilate(float* Is, size_t bytesIs, - float* B, size_t bytesB, - float* D, size_t bytesD, - long m, long n) { - - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, D); - - void* Node = __visc__createNode2D(dilate, m, n); - __visc__bindIn(Node, 0, 0, 0); // Bind Is - __visc__bindIn(Node, 1, 1, 0); // Bind bytesIs - __visc__bindIn(Node, 2, 2, 0); // Bind B - __visc__bindIn(Node, 3, 3, 0); // Bind bytesB - __visc__bindIn(Node, 4, 4, 0); // Bind D - __visc__bindIn(Node, 5, 5, 0); // Bind bytesD - __visc__bindIn(Node, 6, 6, 0); // Bind m - __visc__bindIn(Node, 7, 7, 0); // Bind n - - __visc__bindOut(Node, 0, 0, 0); // bind output m - - -} - -void erode( float* Is, size_t bytesIs, - float* B, size_t bytesB, - float* E, size_t bytesE, - long m, long n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, E); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - long gx = __visc__getNodeInstanceID_x(thisNode); - long gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MAX_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MAX_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MAX_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MAX_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MAX_BR; - - // Compute pixel of dilated image - float erodedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - E[gy*n+gx] = erodedPixel; - } - //__visc__return(n); - __visc__return(bytesB); - -} - -void WrapperErode(float* Is, size_t bytesIs, - float* B, size_t bytesB, - float* E, size_t bytesE, - long m, long n) { - - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, E); - - void* Node = __visc__createNode2D(erode, m, n); - __visc__bindIn(Node, 0, 0, 0); // Bind Is - __visc__bindIn(Node, 1, 1, 0); // Bind bytesIs - __visc__bindIn(Node, 2, 2, 0); // Bind B - __visc__bindIn(Node, 3, 3, 0); // Bind bytesB - __visc__bindIn(Node, 4, 4, 0); // Bind E - __visc__bindIn(Node, 5, 5, 0); // Bind bytesE - __visc__bindIn(Node, 6, 6, 0); // Bind m - __visc__bindIn(Node, 7, 7, 0); // Bind n - - __visc__bindOut(Node, 0, 0, 0); // bind output n - - -} - -void lincomb( float* Is, size_t bytesIs, - float* D, size_t bytesD, - float* E, size_t bytesE, - float* L, size_t bytesL, - long m, long n, - size_t dummy1, size_t dummy2) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, E, D, 1, L); - - void* thisNode = __visc__getNode(); - long gx = __visc__getNodeInstanceID_x(thisNode); - long gy = __visc__getNodeInstanceID_y(thisNode); - - if ((gx < n) && (gy < m)) { - long index = gy*n+gx; - L[index] = D[index] + E[index] - 2 * Is[index]; - } - - //__visc__return(m); -} - -void WrapperLincomb(float* Is, size_t bytesIs, - float* D, size_t bytesD, - float* E, size_t bytesE, - float* L, size_t bytesL, - long m, long n, - size_t dummy1, size_t dummy2) { - - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, E, D, 1, L); - - void* Node = __visc__createNode2D(lincomb, m, n); - __visc__bindIn(Node, 0, 0, 0); // Bind Is - __visc__bindIn(Node, 1, 1, 0); // Bind bytesIs - __visc__bindIn(Node, 2, 2, 0); // Bind D - __visc__bindIn(Node, 3, 3, 0); // Bind bytesD - __visc__bindIn(Node, 4, 4, 0); // Bind E - __visc__bindIn(Node, 5, 5, 0); // Bind bytesE - __visc__bindIn(Node, 6, 6, 0); // Bind L - __visc__bindIn(Node, 7, 7, 0); // Bind bytesL - __visc__bindIn(Node, 8, 8, 0); // Bind m - __visc__bindIn(Node, 9, 9, 0); // Bind n - __visc__bindIn(Node, 10, 10, 0); // Bind dummy1 - __visc__bindIn(Node, 11, 11, 0); // Bind dummy2 - - //__visc__bindOut(Node, 0, 0, 0); // bind output m - - -} - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ - -/* -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} -*/ - -void LaplacianEstimate(float* Is, size_t bytesIs,// 0 - float* B, size_t bytesB, // 2 - float* D, size_t bytesD, // 4 - float* E, size_t bytesE, // 6 - float* L, size_t bytesL, // 8 - long m, long n) { // 10 - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 3, D, E, L); - void* DNode = __visc__createNode(WrapperDilate); - void* ENode = __visc__createNode(WrapperErode); - void* LNode = __visc__createNode(WrapperLincomb); - - // Dilate - __visc__bindIn(DNode, 0, 0, 0); // Bind Is - __visc__bindIn(DNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(DNode, 2, 2, 0); // Bind B - __visc__bindIn(DNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(DNode, 4, 4, 0); // Bind D - __visc__bindIn(DNode, 5, 5, 0); // Bind bytesD - __visc__bindIn(DNode, 10, 6, 0); // Bind m - __visc__bindIn(DNode, 11, 7, 0); // Bind n - - // Erode - __visc__bindIn(ENode, 0, 0, 0); // Bind Is - __visc__bindIn(ENode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(ENode, 2, 2, 0); // Bind B - __visc__bindIn(ENode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ENode, 6, 4, 0); // Bind E - __visc__bindIn(ENode, 7, 5, 0); // Bind bytesE - __visc__bindIn(ENode, 10, 6, 0); // Bind m - __visc__bindIn(ENode, 11, 7, 0); // Bind n - - - // Linear combination - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 4, 2, 0); // Bind D - __visc__bindIn(LNode, 5, 3, 0); // Bind bytesD - __visc__bindIn(LNode, 6, 4, 0); // Bind E - __visc__bindIn(LNode, 7, 5, 0); // Bind bytesE - __visc__bindIn(LNode, 8, 6, 0); // Bind L - __visc__bindIn(LNode, 9, 7, 0); // Bind bytesL - __visc__bindIn(LNode, 10, 8, 0); // Bind m [Alt: Pass as edge from dilate] - __visc__bindIn(LNode, 11, 9, 0); // Bind n [Alt: Pass as edge from erode] - - //__visc__edge(DNode, LNode, 0, 0, 8, 0); // Get m from dilate - //__visc__edge(ENode, LNode, 0, 0, 9, 0); // Get n from erode - __visc__edge(DNode, LNode, 0, 0, 10, 0); // Get a dummy from dilate - __visc__edge(ENode, LNode, 0, 0, 11, 0); // Get a dummy from erode - - //__visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -} -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, D, E, L; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - D = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && L.isContinuous() && D.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - //resize(src, in, Size(HEIGHT, WIDTH)); - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(input_window, in); - //imshow(output_window, out); - //waitKey(0); - - //NUM_FRAMES = 20; - //pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - // Check if the total elements is a multiple of block size - int block_x = 256; - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - NUM_FRAMES = 600; - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(D.data, I_sz); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - packData(args, (float*)src.data, I_sz, - B, bytesB, - (float*)D.data, I_sz, - (float*)E.data, I_sz, - (float*)L.data, I_sz, - src.size[0], src.size[1] - ); - - - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - for(int j=0; j<NUM_FRAMES; j++) { - //std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(0, LaplacianEstimate, (void*)args); - __visc__wait(DFG); - } - - pb_SwitchToTimer( &timers, pb_TimerID_NONE ); - - llvm_visc_request_mem(L.data, I_sz); - - //resize(src, in, Size(HEIGHT, WIDTH)); - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //imshow(input_window, in); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(D.data); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(L.data); - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - pb_FreeParameters(params); - - return 0; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/Makefile deleted file mode 100644 index 6dc39540f209760564005b51d7fcbdd046eaac4b..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/Makefile +++ /dev/null @@ -1,13 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=`pkg-config ${OpenCV_DIR}/lib/pkgconfig/opencv.pc --libs` -#APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/main.cc deleted file mode 100755 index dd519522d92e1bacec6a4bc602a915fb927314aa..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/LaplacianMerged/main.cc +++ /dev/null @@ -1,382 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 1 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "GPU Pipeline - Input Video"; -std::string output_window = "GPU Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* B; - size_t bytesB; - float* D; - size_t bytesD; - float* E; - size_t bytesE; - float* L; - size_t bytesL; - long m; - long n; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* B, size_t bytesB, - float* D, size_t bytesD, - float* E, size_t bytesE, - float* L, size_t bytesL, - long m, long n) { - args->I = I; - args->bytesI = bytesI; - args->B = B; - args->bytesB = bytesB; - args->D = D; - args->bytesD = bytesD; - args->E = E; - args->bytesE = bytesE; - args->L = L; - args->bytesL = bytesL; - args->m = m; - args->n = n; -} - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ - - -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *D, size_t bytesD, - float *E, size_t bytesE, - float *L, size_t bytesL, - long m, long n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - long gx = __visc__getNodeInstanceID_x(thisNode); - long gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - //__visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *D, size_t bytesD, - float *E, size_t bytesE, - float *L, size_t bytesL, - long m, long n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 3, D, E, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind D - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesD - __visc__bindIn(LNode, 6, 6, 0); // Bind E - __visc__bindIn(LNode, 7, 7, 0); // Bind bytesE - __visc__bindIn(LNode, 8, 8, 0); // Bind L - __visc__bindIn(LNode, 9, 9, 0); // Bind bytesL - __visc__bindIn(LNode, 10, 10, 0); // Bind m - __visc__bindIn(LNode, 11, 11, 0); // Bind n - - //__visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -} -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, D, E, L; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - D = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && L.isContinuous() && D.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - //resize(src, in, Size(HEIGHT, WIDTH)); - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(input_window, in); - //imshow(output_window, out); - //waitKey(0); - - //NUM_FRAMES = 20; - //pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - // Check if the total elements is a multiple of block size - int block_x = 256; - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - //NUM_FRAMES = 600; - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(D.data, I_sz); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - packData(args, (float*)src.data, I_sz, - B, bytesB, - (float*)D.data, I_sz, - (float*)E.data, I_sz, - (float*)L.data, I_sz, - src.size[0], src.size[1] - ); - - - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - for(int j=0; j<NUM_FRAMES; j++) { - //std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(0, WrapperlaplacianEstimate, (void*)args); - __visc__wait(DFG); - } - - pb_SwitchToTimer( &timers, pb_TimerID_NONE ); - - llvm_visc_request_mem(L.data, I_sz); - - //resize(src, in, Size(HEIGHT, WIDTH)); - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //imshow(input_window, in); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(D.data); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(L.data); - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/visc/Makefile deleted file mode 100644 index f6c7ebfede0b947aad50dec89b2ecee55c1a36cd..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/visc/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc/kernel.cl b/hpvm/test/parboil/benchmarks/pipeline/src/visc/kernel.cl deleted file mode 100644 index f376a27d90003e3c7c18dafb9f64a8b459a40029..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc/kernel.cl +++ /dev/null @@ -1,25 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Kernel of dense matrix-matrix multiplication kernel. - */ - -__kernel void mysgemmNT( __global const float *A, int lda, __global const float *B, int ldb, __global float* C, int ldc, int k, float alpha, float beta ) -{ - float c = 0.0f; - int m = get_global_id(0); - int n = get_global_id(1); - - for (int i = 0; i < k; ++i) { - float a = A[m + i * lda]; - float b = B[n + i * ldb]; - c += a * b; - } - C[m+n*ldc] = C[m+n*ldc] * beta + alpha * c; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/visc/main.cc deleted file mode 100755 index f8a94d584b7bf5ada481fe95b37fe1fb9ccafaf3..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc/main.cc +++ /dev/null @@ -1,615 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/ocl/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <vector> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - -// I/O routines -extern bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v); -extern bool writeColMajorMatrixFile(const char *fn, int, int, std::vector<float>&); -extern char* readFile(const char*); - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { -//struct __attribute__((__packed__)) OutStruct { - //int m; - //int n; - //size_t bytesB; - //size_t bytesOut; -//}; - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* B; - size_t bytesB; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* E; - size_t bytesE; - int m; - int n; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* B, size_t bytesB, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* E, size_t bytesE, - int m, int n) { - args->I = I; - args->bytesI = bytesI; - args->B = B; - args->bytesB = bytesB; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->E = E; - args->bytesE = bytesE; - args->m = m; - args->n = n; -} - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* -I : imput image -m, n : dimensions -B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) -L : output (laplacian of the image) -Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *I, size_t bytesI, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::CPU_TARGET); - //__visc__hint(visc::GPU_TARGET); - __visc__attributes(2, I, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = I[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = I[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? I[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? I[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = I[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? I[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? I[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? I[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? I[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(1, m); -} - -void WrapperlaplacianEstimate(float *I, size_t bytesI, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, B, 1, L); - void* LNode = __visc__createNodeND(2, laplacianEstimate, (size_t)m, (size_t)n); - __visc__bindIn(LNode, 0, 0, 0); // Bind I - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* -L : imput image (computed Laplacian) -m, n : dimensions -B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) -S : output (sign of the image) -Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - //__visc__hint(visc::SPIR_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? L[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? L[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? L[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? L[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? L[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? L[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - // FIXME: Return bytesG instead of L. RZC nodes expects bytesG - // This is just temporary - __visc__return(1, m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNodeND(2, computeZeroCrossings, (size_t)m, (size_t)n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * S: sign of image - * G: gradient of (smoothed) image - * E: output image : edges - * theta: threshold value - * maxG: computed maximum graddient of G - */ -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *E, size_t bytesE, - //float theta, float maxG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, S, G, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - float theta = 1.0; - float maxG = 10.0; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > theta*maxG)) ? 1.0 : 0.0 ; - } - - __visc__return(1, m); - -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *E, size_t bytesE, - //float theta, float maxG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, S, G, 1, E); - void* RZCNode = __visc__createNodeND(2, rejectZeroCrossings, (size_t)m, (size_t)n); - __visc__bindIn(RZCNode, 0, 0, 0); // Bind S - __visc__bindIn(RZCNode, 1, 1, 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2, 0); // Bind G - __visc__bindIn(RZCNode, 3, 3, 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4, 0); // Bind E - __visc__bindIn(RZCNode, 5, 5, 0); // Bind bytesE - __visc__bindIn(RZCNode, 6, 6, 0); // Bind m - __visc__bindIn(RZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output bytesG - - //return {0}; -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, - float *B, size_t bytesB, - float *L, size_t bytesL, - float *S, size_t bytesS, - float *G, size_t bytesG, - float *E, size_t bytesE, - int m, int n) { - __visc__attributes(2, I, B, 4, L, S, G, E); - void* LNode = __visc__createNodeND(0, WrapperlaplacianEstimate); - void* CZCNode = __visc__createNodeND(0, WrapperComputeZeroCrossings); - void* RZCNode = __visc__createNodeND(0, WrapperRejectZeroCrossings); - - // Laplacian Inputs - __visc__bindIn(LNode, 0, 0, 1); // Bind I - __visc__bindIn(LNode, 1, 1, 1); // Bind bytesI - __visc__bindIn(LNode, 2, 2, 1); // Bind B - __visc__bindIn(LNode, 3, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 1); // Bind L - __visc__bindIn(LNode, 5, 5, 1); // Bind bytesL - __visc__bindIn(LNode, 12, 6, 1); // Bind m - __visc__bindIn(LNode, 13, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4, 0, 1); // Bind L - __visc__bindIn(CZCNode, 5, 1, 1); // Get bytesL - __visc__bindIn(CZCNode, 2, 2, 1); // Bind B - __visc__bindIn(CZCNode, 3, 3, 1); // Get bytesB - __visc__bindIn(CZCNode, 6, 4, 1); // Bind S - __visc__bindIn(CZCNode, 7, 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 12, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 1, 0, 6, 1); - __visc__bindIn(CZCNode, 13, 7, 1); // Bind n - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6, 0, 1); // Bind S - __visc__bindIn(RZCNode, 7, 1, 1); // Get bytesS - __visc__bindIn(RZCNode, 8, 2, 1); // Bind G - __visc__bindIn(RZCNode, 9, 3, 1); // Get bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind E - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 12, 6, 1); // Bind m - __visc__edge(CZCNode, RZCNode, 1, 0, 6, 1); - __visc__bindIn(RZCNode, 13, 7, 1); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} -#define NUM_RUNS 5 -#define NUM_FRAMES 2000 -using namespace cv; - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz, L_sz, S_sz, G_sz, E_sz; - int matIrow, matIcol; - std::vector<float> matI; - std::string window_name = "Edge Map"; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - //Read in data - //std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - //VideoCapture cap(params->inpFiles[0]); - //if(!cap.isOpened()) { - //std::cout << "Could not open video file" << "\n"; - //return -1; - //} - - //double count = cap.get(CV_CAP_PROP_FRAME_COUNT); - //namedWindow(window_name, CV_WINDOW_AUTOSIZE); - - //Mat src; - //while(1) { - //bool success = cap.read(src); - //if(!success) { - //std::cout << "Cannot read frame" << "\n"; - //return -1; - //} - //imshow(window_name, src); - //if(waitKey(0) == 27) break; - //} - - Mat src = imread(params->inpFiles[0]); - if( !src.data ) - { - return -1; - } - /// Create a window - namedWindow( window_name, CV_WINDOW_AUTOSIZE ); - imshow(window_name, src); - waitKey(0); - std::cout << "Image dimension = " << src.size() << "\n"; - /// Convert the image to grayscale - cvtColor( src, src, CV_BGR2GRAY ); - - src.convertTo(src, CV_32F, 1.0/255.0); - if(src.isContinuous()) { - matI.assign((float*)src.datastart, (float*)src.dataend); - std::cout << "Assigning image to float vector\n"; - std::cout << "Vector size = " << matI.size() << "\n"; - matIrow = src.size[0]; - matIcol = src.size[1]; - } - else { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - // Read data from matrix file - //readColMajorMatrixFile(params->inpFiles[0], - //matIrow, matIcol, matI); - pb_InitializeTimerSet(&timers); - __visc__init(); - - pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = matIrow*matIcol*sizeof(float); - L_sz = I_sz; - - // allocate space for C - S_sz = I_sz; - G_sz = I_sz; - E_sz = I_sz; - - // OpenCL memory allocation - std::vector<float> matL(matIrow*matIcol); - std::vector<float> matS(matIrow*matIcol); - std::vector<float> matG(matIrow*matIcol); - std::vector<float> matE(matIrow*matIcol); - - float B[] = {0, 1, 0, 1, 1, 1, 0, 1, 0}; - size_t bytesB = 9*sizeof(float); - - size_t BlockElements = 16; - size_t BlockSize = BlockElements * sizeof(float) ; - - // Copy A and B^T into device memory - pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - // TODO: Should be removed - for(size_t i=0; i<matL.size(); i++) { - matL[i] = 0.0f; - matS[i] = 0.0f; - matG[i] = 0.0f; - matE[i] = 0.0f; - } - - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - - packData(args, &matI.front(), I_sz, - B, bytesB, - &matL.front(), L_sz, - &matS.front(), S_sz, - &matG.front(), G_sz, - &matE.front(), E_sz, - matIrow, matIcol); - - assert(I_sz % BlockSize == 0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - llvm_visc_track_mem(&matI[0], I_sz); - llvm_visc_track_mem(&matL[0], L_sz); - llvm_visc_track_mem(&matS[0], S_sz); - llvm_visc_track_mem(&matG[0], G_sz); - llvm_visc_track_mem(&matE[0], E_sz); - llvm_visc_track_mem(B, bytesB); - //packData(args, &matA[0], BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - __visc__push(DFG, args); - __visc__push(DFG, args); - for(unsigned i=0; i<NUM_FRAMES-2; i++) { - __visc__push(DFG, args); - __visc__pop(DFG); - } - __visc__pop(DFG); - __visc__pop(DFG); - llvm_visc_request_mem(&matS[0], S_sz); - llvm_visc_untrack_mem(&matI[0]); - llvm_visc_untrack_mem(&matL[0]); - llvm_visc_untrack_mem(&matS[0]); - llvm_visc_untrack_mem(&matG[0]); - llvm_visc_untrack_mem(&matE[0]); - llvm_visc_untrack_mem(B); - - //for(unsigned i=0 ; i < I_sz/sizeof(float); i = i + 16) { - //llvm_visc_track_mem(&matA[i], BlockSize); - //llvm_visc_track_mem(&matB[i], BlockSize); - //llvm_visc_track_mem(&matC[i], BlockSize); - //packData(args, &matA[i], BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - //__visc__push(DFG, args); - //void* output = __visc__pop(DFG); - //llvm_visc_request_mem(&matC[i], BlockSize); - //llvm_visc_untrack_mem(&matA[i]); - //llvm_visc_untrack_mem(&matB[i]); - //llvm_visc_untrack_mem(&matC[i]); - //} - - __visc__wait(DFG); - } - pb_SwitchToTimer( &timers, pb_TimerID_COPY ); - //llvm_visc_request_mem(&matC.front(), C_sz); - - pb_SwitchToTimer( &timers, visc_TimerID_MEM_UNTRACK ); - //llvm_visc_untrack_mem(&matA.front()); - //llvm_visc_untrack_mem(&matB.front()); - //llvm_visc_untrack_mem(&matC.front()); - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - writeColMajorMatrixFile(params->outFile, - matIrow, matIcol, matS); - } - Mat output(src.size[0], src.size[1], CV_32F); - memcpy(output.data, matS.data(), matS.size()*sizeof(float)); - imshow(window_name, output); - waitKey(0); - - double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - std::cout<< "GFLOPs = " << 2.* matIrow * matIcol * matIcol/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc/main.cc.pldi b/hpvm/test/parboil/benchmarks/pipeline/src/visc/main.cc.pldi deleted file mode 100644 index f1266c1c1fa134e0940b8735a44014982bfabbc7..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc/main.cc.pldi +++ /dev/null @@ -1,693 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <vector> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> -#include <pthread.h> - -// I/O routines -extern bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v); -extern bool writeColMajorMatrixFile(const char *fn, int, int, std::vector<float>&); -extern char* readFile(const char*); - -// Definitions of sizes for edge detection kernels - - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define MIN(X,Y) ((int)(X) < (int)(Y) ? (X) : (Y)) -#define MAX(X,Y) ((int)(X) > (int)(Y) ? (X) : (Y)) - -void SeqlaplacianEstimate(float *I, size_t bytesI, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n, int gx, int gy) { - - // 3x3 image area - float imageArea[SZB][SZB]; - - int i, j; - - if ((gx < n) && (gy < m)) { - //Data copy for dilation filter - imageArea[1][1] = I[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = I[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? I[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? I[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = I[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? I[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? I[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? I[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? I[(gy + 1) * n + gx] : MIN_BR; - - //Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - //Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - //Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } -} - -void SeqcomputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n, int gx, int gy) { - - // 3x3 image area - float imageArea[SZB][SZB]; - - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? L[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? L[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? L[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? L[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? L[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? L[(gy + 1) * n + gx] : MIN_BR; - - //Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - //Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - //Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; -} - - - - - -extern "C" { - struct __attribute__((__packed__)) OutStruct { - //int m; - //int n; - size_t bytesB; - size_t bytesOut; - }; - - struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* B; - size_t bytesB; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - int m; - int n; - }; - - - //void* __visc__createNode2D(...); - //void* __visc__createNode1D(...); - //void* __visc__createNode(...); - //void __visc__bindIn(void*, unsigned, unsigned, unsigned); - //void __visc__bindOut(void*, unsigned, unsigned, unsigned); - //void* __visc__edge(void*, void*, unsigned, unsigned, unsigned); - //void __visc__push(void*, void*); - //void* __visc__pop(void*); - //void* __visc__launch(unsigned,...); - //void __visc__wait(void*); - - //void* __visc__getNode(); - //unsigned __visc__getNodeInstanceID_x(void*); - //unsigned __visc__getNodeInstanceID_y(void*); - - - void packData(struct InStruct* args, float* I, size_t bytesI, - float* B, size_t bytesB, - float* L, size_t bytesL, - float* S, size_t bytesS, - int m, int n) { - args->I = I; - args->bytesI = bytesI; - args->B = B; - args->bytesB = bytesB; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->m = m; - args->n = n; - } - - /* Compute a non-linear laplacian estimate of input image I of size m x n */ - /* - I : imput image - m, n : dimensions - B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - L : output (laplacian of the image) - Need 2D grid, a thread per pixel - */ - OutStruct laplacianEstimate(float *I, size_t bytesI, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - //__visc__hint(visc::SPIR_TARGET); - __visc__hint(visc::GPU_TARGET); - __visc__attributes(2, I, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - //Data copy for dilation filter - imageArea[1][1] = I[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = I[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? I[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? I[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = I[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? I[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? I[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? I[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? I[(gy + 1) * n + gx] : MIN_BR; - - //Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - //Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - //Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - return output; - } - - OutStruct WrapperlaplacianEstimate(float *I, size_t bytesI, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - //__visc__hint(visc::SPIR_TARGET); - __visc__hint(visc::GPU_TARGET); - __visc__attributes(2, I, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind I - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - __visc__bindOut(LNode, 1, 1, 0); // bind output n - - return {0}; - } - - /* Compute the zero crossings of input image L of size m x n */ - /* - L : imput image (computed Laplacian) - m, n : dimensions - B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - S : output (sign of the image) - Need 2D grid, a thread per pixel - */ - OutStruct computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - //__visc__hint(visc::SPIR_TARGET); - //__visc__hint(visc::GPU_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? L[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? L[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? L[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? L[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? L[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? L[(gy + 1) * n + gx] : MIN_BR; - - //Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - //Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - //Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - return output; - } - - OutStruct WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - //__visc__hint(visc::SPIR_TARGET); - //__visc__hint(visc::GPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - __visc__bindOut(ZCNode, 1, 1, 0); // bind output n - - return {0}; - } - - //Pipelined Root node - OutStruct edgeDetection(float *I, size_t bytesI, - float *B, size_t bytesB, - float *L, size_t bytesL, - float *S, size_t bytesS, - int m, int n) { - __visc__attributes(2, I, B, 2, L, S); - void* PNode = __visc__createNode(WrapperlaplacianEstimate); - void* CNode = __visc__createNode(WrapperComputeZeroCrossings); - - __visc__bindIn(PNode, 0, 0, 1); // Bind I - __visc__bindIn(PNode, 1, 1, 1); // Bind bytesI - __visc__bindIn(PNode, 2, 2, 1); // Bind B - __visc__bindIn(PNode, 3, 3, 1); // Bind bytesB - __visc__bindIn(PNode, 4, 4, 1); // Bind L - __visc__bindIn(PNode, 5, 5, 1); // Bind bytesL - __visc__bindIn(PNode, 8, 6, 1); // Bind m - __visc__bindIn(PNode, 9, 7, 1); // Bind n - - __visc__bindIn(CNode, 4, 0, 1); // Bind L - __visc__edge(PNode, CNode, 1, 1, 1); // Get bytesL - __visc__bindIn(CNode, 2, 2, 1); // Bind B - __visc__edge(PNode, CNode, 0, 3, 1); // Get bytesB - __visc__bindIn(CNode, 6, 4, 1); // Bind S - __visc__bindIn(CNode, 7, 5, 1); // Bind bytesS - - __visc__bindIn(CNode, 8, 6, 1); // Bind m - __visc__bindIn(CNode, 9, 7, 1); // Bind n - - __visc__bindOut(CNode, 0, 0, 1); // dummy bind output to get pipeline functionality - __visc__bindOut(CNode, 1, 1, 1); // dummy bind output to get pipeline functionality - return {0}; - } - // Non-pipelined Root node - //OutStruct edgeDetection(float *I, size_t bytesI, - //float *B, size_t bytesB, - //float *L, size_t bytesL, - //float *S, size_t bytesS, - //int m, int n) { - //__visc__attributes(2, I, B, 2, L, S); - //void* PNode = __visc__createNode(WrapperlaplacianEstimate); - //void* CNode = __visc__createNode(WrapperComputeZeroCrossings); - - //__visc__bindIn(PNode, 0, 0, 0); // Bind I - //__visc__bindIn(PNode, 1, 1, 0); // Bind bytesI - //__visc__bindIn(PNode, 2, 2, 0); // Bind B - //__visc__bindIn(PNode, 3, 3, 0); // Bind bytesB - //__visc__bindIn(PNode, 4, 4, 0); // Bind L - //__visc__bindIn(PNode, 5, 5, 0); // Bind bytesL - //__visc__bindIn(PNode, 8, 6, 0); // Bind m - //__visc__bindIn(PNode, 9, 7, 0); // Bind n - - //__visc__bindIn(CNode, 4, 0, 0); // Bind L - //__visc__edge(PNode, CNode, 1, 1, 0); // Get bytesL - //__visc__bindIn(CNode, 2, 2, 0); // Bind B - //__visc__edge(PNode, CNode, 0, 3, 0); // Get bytesB - //__visc__bindIn(CNode, 6, 4, 0); // Bind S - //__visc__bindIn(CNode, 7, 5, 0); // Bind bytesS - - //__visc__bindIn(CNode, 8, 6, 0); // Bind m - //__visc__bindIn(CNode, 9, 7, 0); // Bind n - - - //__visc__bindOut(CNode, 0, 0, 0); // dummy bind output to get pipeline functionality - //__visc__bindOut(CNode, 1, 1, 0); // dummy bind output to get pipeline functionality - //return {0}; - //} -} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz, L_sz, S_sz; - int matIrow, matIcol; - std::vector<float> matI; - - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] == NULL) - || (params->inpFiles[2] == NULL) - || (params->inpFiles[3] != NULL)) - { - fprintf(stderr, "Expecting three input filenames\n"); - exit(-1); - } - - /* Read in data */ - // load A - readColMajorMatrixFile(params->inpFiles[0], - matIrow, matIcol, matI); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = matIrow*matIcol*sizeof(float); - L_sz = I_sz; - - // allocate space for C - S_sz = I_sz; - - // OpenCL memory allocation - std::vector<float> matL(matIrow*matIcol); - std::vector<float> matS(matIrow*matIcol); - - float B[] = {0, 1, 0, 1, 1, 1, 0, 1, 0}; - size_t bytesB = 9*sizeof(float); - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - pb_SwitchToTimer( &timers, pb_TimerID_NONE ); - - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - - packData(args, &matI.front(), I_sz, - B, bytesB, - &matL.front(), L_sz, - &matS.front(), S_sz, - matIrow, matIcol); - -#define NUM_RUNS 1 -#define NUM_FRAMES 1 - - std::cout << "Executing Pipeline Version\n"; - // Non-Pipeline Execution Time - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - for(unsigned j=0; j< NUM_RUNS; j++) { - llvm_visc_track_mem(&matI[0], I_sz); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(&matL[0], L_sz); - llvm_visc_track_mem(&matS[0], S_sz); - - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - for(unsigned i=0 ; i < NUM_FRAMES; i++) { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - __visc__wait(DFG); - llvm_visc_untrack_mem(&matI[0]); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(&matL[0]); - llvm_visc_untrack_mem(&matS[0]); - - } - - //Pipeline - //pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - //for(unsigned j=0; j< NUM_RUNS; j++) { - //llvm_visc_track_mem(&matI[0], I_sz); - //llvm_visc_track_mem(B, bytesB); - //llvm_visc_track_mem(&matL[0], L_sz); - //llvm_visc_track_mem(&matS[0], S_sz); - - //void* DFG = __visc__launch(1, edgeDetection, (void*)args); - //__visc__push(DFG, args); - //__visc__push(DFG, args); - //for(unsigned i=0 ; i < NUM_FRAMES-2; i++) { - //__visc__push(DFG, args); - //__visc__pop(DFG); - //} - //__visc__pop(DFG); - //__visc__pop(DFG); - //__visc__wait(DFG); - - //llvm_visc_untrack_mem(&matI[0]); - //llvm_visc_untrack_mem(B); - //llvm_visc_untrack_mem(&matL[0]); - //llvm_visc_untrack_mem(&matS[0]); - - //} - //llvm_visc_request_mem(&matS[0], S_sz); - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - std::cout << "Executing Sequential Version\n"; - // Sequential Execution Time - //pb_SwitchToTimer(&timers, pb_TimerID_COMPUTE); - //for(unsigned j=0; j< NUM_RUNS; j++) { - - //for(unsigned i=0 ; i < NUM_FRAMES; i++) { - //for(int gx = 0; gx < matIrow; gx++) { - //for (int gy=0; gy < matIcol; gy++) { - //SeqlaplacianEstimate(&matI.front(), I_sz, - //B, bytesB, - //&matL.front(), L_sz, - //matIrow, matIcol, gx, gy); - //SeqcomputeZeroCrossings(&matL.front(), L_sz, - //B, bytesB, - //&matS.front(), S_sz, - //matIrow, matIcol, gx, gy); - //} - //} - //} - //} - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - std::cout << "Writing Result\n"; - if (params->outFile) { - - /* Write C to file */ - pb_SwitchToTimer(&timers, pb_TimerID_IO); - writeColMajorMatrixFile(params->outFile, - matIrow, matIcol, matS); - } - - double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - std::cout<< "GFLOPs = " << 2.* matIrow * matIcol * matIcol/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc/main_demo.cc b/hpvm/test/parboil/benchmarks/pipeline/src/visc/main_demo.cc deleted file mode 100755 index 9d2cb1def2faa130bdbcd393c23bf8ff6941e199..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc/main_demo.cc +++ /dev/null @@ -1,947 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <vector> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - -// I/O routines -extern bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v); -extern bool writeColMajorMatrixFile(const char *fn, int, int, std::vector<float>&); -extern char* readFile(const char*); - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { -//struct __attribute__((__packed__)) OutStruct { - //int m; - //int n; - //size_t bytesB; - //size_t bytesOut; -//}; - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - float theta; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - float theta, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->theta = theta; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0 , 0, 0); // Bind I - __visc__bindIn(GSNode, 1 , 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 0); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 23, 6, 0); // Bind m - __visc__bindIn(GSNode, 24, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * I : imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *I, size_t bytesI, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::GPU_TARGET); - __visc__attributes(2, I, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = I[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = I[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? I[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? I[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = I[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? I[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? I[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? I[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? I[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 2 , 0, 0); // Bind Is - __visc__bindIn(LNode, 3 , 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 0); // Bind B - __visc__bindIn(LNode, 17, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 0); // Bind L - __visc__bindIn(LNode, 5 , 5, 0); // Bind bytesL - __visc__bindIn(LNode, 23, 6, 0); // Bind m - __visc__bindIn(LNode, 24, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::SPIR_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? L[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? L[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? L[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? L[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? L[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? L[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - // FIXME: Return bytesG instead of L. RZC nodes expects bytesG - // This is just temporary - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 4 , 0, 0); // Bind L - __visc__bindIn(ZCNode, 5 , 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 16, 2, 0); // Bind B - __visc__bindIn(ZCNode, 17, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 6 , 4, 0); // Bind S - __visc__bindIn(ZCNode, 7 , 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 23, 6, 0); // Bind m - __visc__bindIn(ZCNode, 24, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - -// G[gloc] = sqrt(Gx*Gx + Gy*Gy); - G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(m); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 2 , 0, 0); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 0); // Bind G - __visc__bindIn(CGNode, 9 , 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 23, 8, 0); // Bind m - __visc__bindIn(CGNode, 24, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG - int m, int n) { - - __visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - __visc__attributes(2, G, maxG, 1, maxG); - - void* thisNode = __visc__getNode(); - void* parentNode = __visc__getParentNode(thisNode); - - int lx = __visc__getNodeInstanceID_x(thisNode); - int px = __visc__getNodeInstanceID_x(parentNode); - int dimx = __visc__getNumNodeInstances_x(thisNode); - - int gid = lx + 2*px*dimx; - - for (unsigned stride = dimx; stride > 32; stride >>= 1) { - if ((gid + stride < m*n) && (lx < stride)) - if (G[gid + stride] > G[gid]) - G[gid] = G[gid + stride]; - __visc__barrier(); - } - - for (unsigned stride = 32; stride >= 1; stride >>= 1) { - if ((gid + stride < m*n) && (lx < stride)) - if (G[gid + stride] > G[gid]) - G[gid] = G[gid + stride]; - } - - if (lx == 0) - __visc__atomic_max(maxG,G[gid]); - - __visc__return(m); -} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG - int m, int n, - int block_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 8 , 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 9 , 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 10, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 11, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 23, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 24, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 25, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - float theta, - int m, int n) { - __visc__hint(visc::DEVICE); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > theta*mG)) ? 1.0 : 0.0 ; - } - - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - float theta, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 6 , 0 , 0); // Bind S - __visc__bindIn(RZCNode, 7 , 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2 , 0); // Bind G - __visc__bindIn(RZCNode, 9 , 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 11, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 13, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 22, 8 , 0); // Bind theta - __visc__bindIn(RZCNode, 23, 9 , 0); // Bind m - __visc__bindIn(RZCNode, 24, 10, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, - float *Is, size_t bytesIs, - float *L, size_t bytesL, - float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - float *Gs, size_t bytesGs, - float *B, size_t bytesB, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float theta, - int m, - int n, - int block_x, - int grid_x) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 23, 6, 1); // Bind m - __visc__bindIn(GSNode, 24, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 23, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 24, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 23, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 24, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG -// __visc__bindIn(CGNode, 23, 8, 1); // Bind m - __visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - __visc__bindIn(CGNode, 24, 9, 1); // Bind n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1) // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1) // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1) // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1) // Bind bytesMaxG -// __visc__bindIn(CMGNode, 23, 4, 1) // Bind m - __visc__edge(CGNode, CMGNode, 0, 4, 1) // Get m - __visc__bindIn(CMGNode, 24, 5, 1) // Bind n - __visc__bindIn(CMGNode, 25, 6, 1) // Bind block_x - __visc__bindIn(CMGNode, 26, 7, 1) // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - __visc__bindIn(RZCNode, 22, 8, 1); // Bind theta - //__visc__bindIn(RZCNode, 23, 9, 1); // Bind m - __visc__edge(CMGNode, RZCNode, 0, 9, 1); - __visc__bindIn(RZCNode, 24, 10, 1); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} -#define NUM_RUNS 1 -#define NUM_FRAMES 20 -using namespace cv; - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz, L_sz, S_sz, G_sz, E_sz; - int matIrow, matIcol; - std::vector<float> matI; - std::string window_name = "Edge Map"; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - //std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - //VideoCapture cap(params->inpFiles[0]); - //if(!cap.isOpened()) { - //std::cout << "Could not open video file" << "\n"; - //return -1; - //} - - //double count = cap.get(CV_CAP_PROP_FRAME_COUNT); - //namedWindow(window_name, CV_WINDOW_AUTOSIZE); - - //Mat src; - //while(1) { - //bool success = cap.read(src); - //if(!success) { - //std::cout << "Cannot read frame" << "\n"; - //return -1; - //} - //imshow(window_name, src); - //if(waitKey(0) == 27) break; - //} - - Mat src = imread(params->inpFiles[0]); - if( !src.data ) - { - return -1; - } - /// Create a window - namedWindow( window_name, CV_WINDOW_AUTOSIZE ); - imshow(window_name, src); - waitKey(0); - std::cout << "Image dimension = " << src.size() << "\n"; - /// Convert the image to grayscale - cvtColor( src, src, CV_BGR2GRAY ); - - src.convertTo(src, CV_32F, 1.0/255.0); - if(src.isContinuous()) { - matI.assign((float*)src.datastart, (float*)src.dataend); - std::cout << "Assigning image to float vector\n"; - std::cout << "Vector size = " << matI.size() << "\n"; - matIrow = src.size[0]; - matIcol = src.size[1]; - } - else { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - pb_InitializeTimerSet(&timers); - __visc__init(); - - pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = matIrow*matIcol*sizeof(float); - L_sz = I_sz; - - // allocate space for C - S_sz = I_sz; - G_sz = I_sz; - E_sz = I_sz; - - // OpenCL memory allocation - std::vector<float> matL(matIrow*matIcol); - std::vector<float> matS(matIrow*matIcol); - std::vector<float> matG(matIrow*matIcol); - std::vector<float> matE(matIrow*matIcol); - - float B[] = {0, 1, 0, 1, 1, 1, 0, 1, 0}; - size_t bytesB = 9*sizeof(float); - - size_t BlockElements = 16; - size_t BlockSize = BlockElements * sizeof(float) ; - - // Copy A and B^T into device memory - pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - // TODO: Should be removed - for(size_t i=0; i<matL.size(); i++) { - matL[i] = 0.0f; - matS[i] = 0.0f; - matG[i] = 0.0f; - matE[i] = 0.0f; - } - - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - - packData(args, &matI.front(), I_sz, - B, bytesB, - &matL.front(), L_sz, - &matS.front(), S_sz, - &matG.front(), G_sz, - &matE.front(), E_sz, - matIrow, matIcol); - - assert(I_sz % BlockSize == 0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - llvm_visc_track_mem(&matI[0], I_sz); - llvm_visc_track_mem(&matL[0], L_sz); - llvm_visc_track_mem(&matS[0], S_sz); - llvm_visc_track_mem(&matG[0], G_sz); - llvm_visc_track_mem(&matE[0], E_sz); - llvm_visc_track_mem(B, bytesB); - //packData(args, &matA[0], BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - __visc__push(DFG, args); - __visc__push(DFG, args); - for(unsigned i=0; i<NUM_FRAMES-2; i++) { - __visc__push(DFG, args); - __visc__pop(DFG); - } - __visc__pop(DFG); - __visc__pop(DFG); - llvm_visc_request_mem(&matS[0], S_sz); - llvm_visc_untrack_mem(&matI[0]); - llvm_visc_untrack_mem(&matL[0]); - llvm_visc_untrack_mem(&matS[0]); - llvm_visc_untrack_mem(&matG[0]); - llvm_visc_untrack_mem(&matE[0]); - llvm_visc_untrack_mem(B); - - //for(unsigned i=0 ; i < I_sz/sizeof(float); i = i + 16) { - //llvm_visc_track_mem(&matA[i], BlockSize); - //llvm_visc_track_mem(&matB[i], BlockSize); - //llvm_visc_track_mem(&matC[i], BlockSize); - //packData(args, &matA[i], BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - //__visc__push(DFG, args); - //void* output = __visc__pop(DFG); - //llvm_visc_request_mem(&matC[i], BlockSize); - //llvm_visc_untrack_mem(&matA[i]); - //llvm_visc_untrack_mem(&matB[i]); - //llvm_visc_untrack_mem(&matC[i]); - //} - - __visc__wait(DFG); - } - pb_SwitchToTimer( &timers, pb_TimerID_COPY ); - //llvm_visc_request_mem(&matC.front(), C_sz); - - pb_SwitchToTimer( &timers, visc_TimerID_MEM_UNTRACK ); - //llvm_visc_untrack_mem(&matA.front()); - //llvm_visc_untrack_mem(&matB.front()); - //llvm_visc_untrack_mem(&matC.front()); - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - writeColMajorMatrixFile(params->outFile, - matIrow, matIcol, matS); - } - Mat output(src.size[0], src.size[1], CV_32F); - memcpy(output.data, matS.data(), matS.size()*sizeof(float)); - imshow(window_name, output); - waitKey(0); - - double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - std::cout<< "GFLOPs = " << 2.* matIrow * matIcol * matIcol/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/Makefile deleted file mode 100644 index f87cb91102c01826ecf87c2e698822d7caaaef5e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/main.cc deleted file mode 100755 index 836cf1a01a56e6548f0fd11b3f11df0f303b3a8e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-MaxG/main.cc +++ /dev/null @@ -1,1117 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 10000 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "GPU-CPU(No Vector)-MaxG Pipeline - Input Video"; -std::string output_window = "GPU-CPU(No Vector)-MaxG Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m, n); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0, 0, 0); // Bind I - __visc__bindIn(GSNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 2, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 3, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 4, 4, 0); // Bind Is - __visc__bindIn(GSNode, 5, 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 6, 6, 0); // Bind m - __visc__bindIn(GSNode, 7, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m - __visc__bindOut(GSNode, 1, 1, 0); // bind output n -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx] > MIN_BR? MAX_BR : MIN_BR; - - if (gx == 0) { // left most line - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][0] = (gy > 0) ? - (L[(gy - 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? - (L[(gy + 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][2] = (gy > 0) ? - (L[(gy - 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? - (L[(gy + 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? - (L[(gy - 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][1] = (gy < m - 1)? - (L[(gy + 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(n); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind G - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 8, 8, 0); // Bind m - __visc__bindIn(CGNode, 9, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -/* - * Reduction - * G : input - * maxG: output - * m, n: input size - * Needs a single thread block - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(1, G, 1, maxG); - - void* thisNode = __visc__getNode(); - - int lx = __visc__getNodeInstanceID_x(thisNode); // threadIdx.x - int dimx = __visc__getNumNodeInstances_x(thisNode); // blockDim.x - - - // Assume a single thread block - // Thread block iterates over all elements - for (int i = lx + dimx; i < m*n; i+= dimx) { - if (G[lx] < G[i]) - G[lx] = G[i]; - } - - // First thread iterates over all elements of the thread block - if (lx == 0) { - for (int i = 1; (i < dimx) && (i < m*n); i++) - if (G[lx] < G[i]) - G[lx] = G[i]; - - *maxG = G[lx]; - } - - __visc__return(n); -} - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -//void computeMaxGradientLeaf(float *G, size_t bytesG, - //float *maxG, size_t bytesMaxG, - //int m, int n) { - - //__visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - //__visc__attributes(2, G, maxG, 1, maxG); - - //void* thisNode = __visc__getNode(); - //void* parentNode = __visc__getParentNode(thisNode); - - //int lx = __visc__getNodeInstanceID_x(thisNode); - //int px = __visc__getNodeInstanceID_x(parentNode); - //int dimx = __visc__getNumNodeInstances_x(thisNode); - - //int gid = lx + 2*px*dimx; - - //for (unsigned stride = dimx; stride > 32; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //__visc__barrier(); - //} - - //for (unsigned stride = 32; stride >= 1; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //} - - //if (lx == 0) - //__visc__atomic_max(maxG,G[gid]); - - //__visc__return(m); -//} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 5, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 6, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ - -#define THETA 0.1 -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - //float mG = 1.39203; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > THETA*mG)) ? 1.0 : 0.0 ; - } - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 0, 0 , 0); // Bind S - __visc__bindIn(RZCNode, 1, 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2 , 0); // Bind G - __visc__bindIn(RZCNode, 3, 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 5, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 6, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 7, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 8, 8 , 0); // Bind m - __visc__bindIn(RZCNode, 9, 9, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, // 0 - float *Is, size_t bytesIs, // 2 - float *L, size_t bytesL, // 4 - float *S, size_t bytesS, // 6 - float *G, size_t bytesG, // 8 - float *maxG, size_t bytesMaxG, // 10 - float *E, size_t bytesE, // 12 - float *Gs, size_t bytesGs, // 14 - float *B, size_t bytesB, // 16 - float *Sx, size_t bytesSx, // 18 - float *Sy, size_t bytesSy, // 20 - int m, // 22 - int n, // 23 - int block_x, // 24 - int grid_x // 25 - ) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - __visc__hint(visc::CPU_TARGET); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 22, 6, 1); // Bind m - __visc__bindIn(GSNode, 23, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 22, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 23, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 22, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 23, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG - __visc__bindIn(CGNode, 22, 8, 1); // Bind m - //__visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - //__visc__bindIn(CGNode, 23, 9, 1); // Bind n - __visc__edge(GSNode, CGNode, 1, 9, 1); // Get n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1); // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1); // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1); // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1); // Bind bytesMaxG - __visc__bindIn(CMGNode, 22, 4, 1); // Bind m - //__visc__edge(CGNode, CMGNode, 0, 4, 1); // Get m - //__visc__bindIn(CMGNode, 23, 5, 1); // Bind n - __visc__edge(CGNode, CMGNode, 0, 5, 1); // Get n - __visc__bindIn(CMGNode, 24, 6, 1); // Bind block_x - __visc__bindIn(CMGNode, 25, 7, 1); // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 22, 8, 1); // Bind m - __visc__edge(CZCNode, RZCNode, 0, 8, 1); // Get m - //__visc__bindIn(RZCNode, 23, 9, 1); // Bind n - __visc__edge(CMGNode, RZCNode, 0, 9, 1); // Get n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} - -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - int block_x, grid_x; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Is, L, S, G, E; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Is = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - S = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - size_t bytesMaxG = sizeof(float); - float* maxG = (float*)malloc(bytesMaxG); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - float Gs [] = { - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.002291, 0.023226, 0.092651, 0.146768, 0.092651, 0.023226, 0.002291, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036 }; - size_t bytesGs = 7*7*sizeof(float); - - block_x = 256; - // grid_x should be equal to the number of SMs on GPU. FTX 680 has 8 SMs - grid_x = 1; - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(input_window, in); - imshow(output_window, out); - waitKey(0); - - //NUM_FRAMES = 20; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - packData(args, (float*)src.data, I_sz, - (float*)Is.data, I_sz, - (float*)L.data, I_sz, - (float*)S.data, I_sz, - (float*)G.data, I_sz, - maxG, bytesMaxG, - (float*)E.data, I_sz, - Gs, bytesGs, - B, bytesB, - Sx, bytesSx, - Sy, bytesSy, - src.size[0], src.size[1], - block_x, grid_x); - - // Check if the total elements is a multiple of block size - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - //std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - *maxG = 0.0; - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Is.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - llvm_visc_track_mem(S.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - llvm_visc_track_mem(maxG, bytesMaxG); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(Gs, bytesGs); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - - __visc__push(DFG, args); - __visc__pop(DFG); - - //llvm_visc_request_mem(E.data, I_sz); - //std::cout << "Show E" << "\n"; - //imshow(window_name, E); - //waitKey(0); - //llvm_visc_request_mem(src.data, I_sz); - //llvm_visc_request_mem(Is.data, I_sz); - //llvm_visc_request_mem(L.data, I_sz); - //llvm_visc_request_mem(S.data, I_sz); - //llvm_visc_request_mem(G.data, I_sz); - llvm_visc_request_mem(maxG, bytesMaxG); - llvm_visc_request_mem(E.data, I_sz); - //std::cout << "src.data = " << (float*)src.data << "\n"; - //std::cout << "Is.data = " << (float*)Is.data << "\n"; - //std::cout << "L.data = " << (float*)L.data << "\n"; - //std::cout << "S.data = " << (float*)S.data << "\n"; - //std::cout << "G.data = " << (float*)G.data << "\n"; - //std::cout << "E.data = " << (float*)E.data << "\n"; - //std::cout << "Max G = " << *maxG << "\n"; - - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - //std::cout << "Show E\n"; - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(output_window, out); - imshow(input_window, in); - waitKey(1); - //waitKey(0); - //std::cout << "Show Is\n"; - //resize(Is, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show L\n"; - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show S\n"; - //resize(S, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show G\n"; - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Is.data); - llvm_visc_untrack_mem(L.data); - llvm_visc_untrack_mem(S.data); - llvm_visc_untrack_mem(G.data); - llvm_visc_untrack_mem(maxG); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(Gs); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - - getNextFrame(cap, src); - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - //if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - //writeColMajorMatrixFile(params->outFile, - //src.size[0], src.size[1], matE); - //} - - //std::cout << "Show Is" << "\n"; - //Mat output(src.size[0], src.size[1], CV_32F); - //imshow(output_window, Is); - //waitKey(0); - - //std::cout << "Show G" << "\n"; - //imshow(output_window, L); - //waitKey(0); - - //std::cout << "Show L" << "\n"; - //imshow(output_window, S); - //waitKey(0); - - //std::cout << "Show S" << "\n"; - //imshow(output_window, G); - //waitKey(0); - - //std::cout << "Show E" << "\n"; - //imshow(output_window, E); - //waitKey(0); - - //double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - //std::cout<< "GFLOPs = " << 2.* src.size[0] * src.size[1] * src.size[1]/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/Makefile deleted file mode 100644 index f87cb91102c01826ecf87c2e698822d7caaaef5e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/main.cc deleted file mode 100755 index c77934beaedb52c020fc1d41aca3686671ab75e2..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU-Scalar-ZC/main.cc +++ /dev/null @@ -1,1117 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 10000 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "GPU-CPU(No Vector)-ZC Pipeline - Input Video"; -std::string output_window = "GPU-CPU(No Vector)-ZC Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m, n); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0, 0, 0); // Bind I - __visc__bindIn(GSNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 2, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 3, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 4, 4, 0); // Bind Is - __visc__bindIn(GSNode, 5, 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 6, 6, 0); // Bind m - __visc__bindIn(GSNode, 7, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m - __visc__bindOut(GSNode, 1, 1, 0); // bind output n -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx] > MIN_BR? MAX_BR : MIN_BR; - - if (gx == 0) { // left most line - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][0] = (gy > 0) ? - (L[(gy - 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? - (L[(gy + 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][2] = (gy > 0) ? - (L[(gy - 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? - (L[(gy + 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? - (L[(gy - 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][1] = (gy < m - 1)? - (L[(gy + 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(n); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind G - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 8, 8, 0); // Bind m - __visc__bindIn(CGNode, 9, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -/* - * Reduction - * G : input - * maxG: output - * m, n: input size - * Needs a single thread block - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(1, G, 1, maxG); - - void* thisNode = __visc__getNode(); - - int lx = __visc__getNodeInstanceID_x(thisNode); // threadIdx.x - int dimx = __visc__getNumNodeInstances_x(thisNode); // blockDim.x - - - // Assume a single thread block - // Thread block iterates over all elements - for (int i = lx + dimx; i < m*n; i+= dimx) { - if (G[lx] < G[i]) - G[lx] = G[i]; - } - - // First thread iterates over all elements of the thread block - if (lx == 0) { - for (int i = 1; (i < dimx) && (i < m*n); i++) - if (G[lx] < G[i]) - G[lx] = G[i]; - - *maxG = G[lx]; - } - - __visc__return(n); -} - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -//void computeMaxGradientLeaf(float *G, size_t bytesG, - //float *maxG, size_t bytesMaxG, - //int m, int n) { - - //__visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - //__visc__attributes(2, G, maxG, 1, maxG); - - //void* thisNode = __visc__getNode(); - //void* parentNode = __visc__getParentNode(thisNode); - - //int lx = __visc__getNodeInstanceID_x(thisNode); - //int px = __visc__getNodeInstanceID_x(parentNode); - //int dimx = __visc__getNumNodeInstances_x(thisNode); - - //int gid = lx + 2*px*dimx; - - //for (unsigned stride = dimx; stride > 32; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //__visc__barrier(); - //} - - //for (unsigned stride = 32; stride >= 1; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //} - - //if (lx == 0) - //__visc__atomic_max(maxG,G[gid]); - - //__visc__return(m); -//} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 5, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 6, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ - -#define THETA 0.1 -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - //float mG = 1.39203; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > THETA*mG)) ? 1.0 : 0.0 ; - } - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 0, 0 , 0); // Bind S - __visc__bindIn(RZCNode, 1, 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2 , 0); // Bind G - __visc__bindIn(RZCNode, 3, 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 5, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 6, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 7, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 8, 8 , 0); // Bind m - __visc__bindIn(RZCNode, 9, 9, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, // 0 - float *Is, size_t bytesIs, // 2 - float *L, size_t bytesL, // 4 - float *S, size_t bytesS, // 6 - float *G, size_t bytesG, // 8 - float *maxG, size_t bytesMaxG, // 10 - float *E, size_t bytesE, // 12 - float *Gs, size_t bytesGs, // 14 - float *B, size_t bytesB, // 16 - float *Sx, size_t bytesSx, // 18 - float *Sy, size_t bytesSy, // 20 - int m, // 22 - int n, // 23 - int block_x, // 24 - int grid_x // 25 - ) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - __visc__hint(visc::CPU_TARGET); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 22, 6, 1); // Bind m - __visc__bindIn(GSNode, 23, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 22, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 23, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 22, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 23, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG - __visc__bindIn(CGNode, 22, 8, 1); // Bind m - //__visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - //__visc__bindIn(CGNode, 23, 9, 1); // Bind n - __visc__edge(GSNode, CGNode, 1, 9, 1); // Get n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1); // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1); // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1); // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1); // Bind bytesMaxG - __visc__bindIn(CMGNode, 22, 4, 1); // Bind m - //__visc__edge(CGNode, CMGNode, 0, 4, 1); // Get m - //__visc__bindIn(CMGNode, 23, 5, 1); // Bind n - __visc__edge(CGNode, CMGNode, 0, 5, 1); // Get n - __visc__bindIn(CMGNode, 24, 6, 1); // Bind block_x - __visc__bindIn(CMGNode, 25, 7, 1); // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 22, 8, 1); // Bind m - __visc__edge(CZCNode, RZCNode, 0, 8, 1); // Get m - //__visc__bindIn(RZCNode, 23, 9, 1); // Bind n - __visc__edge(CMGNode, RZCNode, 0, 9, 1); // Get n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} - -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - int block_x, grid_x; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Is, L, S, G, E; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Is = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - S = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - size_t bytesMaxG = sizeof(float); - float* maxG = (float*)malloc(bytesMaxG); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - float Gs [] = { - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.002291, 0.023226, 0.092651, 0.146768, 0.092651, 0.023226, 0.002291, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036 }; - size_t bytesGs = 7*7*sizeof(float); - - block_x = 256; - // grid_x should be equal to the number of SMs on GPU. FTX 680 has 8 SMs - grid_x = 1; - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(input_window, in); - imshow(output_window, out); - waitKey(0); - - //NUM_FRAMES = 20; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - packData(args, (float*)src.data, I_sz, - (float*)Is.data, I_sz, - (float*)L.data, I_sz, - (float*)S.data, I_sz, - (float*)G.data, I_sz, - maxG, bytesMaxG, - (float*)E.data, I_sz, - Gs, bytesGs, - B, bytesB, - Sx, bytesSx, - Sy, bytesSy, - src.size[0], src.size[1], - block_x, grid_x); - - // Check if the total elements is a multiple of block size - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - //std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - *maxG = 0.0; - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Is.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - llvm_visc_track_mem(S.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - llvm_visc_track_mem(maxG, bytesMaxG); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(Gs, bytesGs); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - - __visc__push(DFG, args); - __visc__pop(DFG); - - //llvm_visc_request_mem(E.data, I_sz); - //std::cout << "Show E" << "\n"; - //imshow(window_name, E); - //waitKey(0); - //llvm_visc_request_mem(src.data, I_sz); - //llvm_visc_request_mem(Is.data, I_sz); - //llvm_visc_request_mem(L.data, I_sz); - //llvm_visc_request_mem(S.data, I_sz); - //llvm_visc_request_mem(G.data, I_sz); - llvm_visc_request_mem(maxG, bytesMaxG); - llvm_visc_request_mem(E.data, I_sz); - //std::cout << "src.data = " << (float*)src.data << "\n"; - //std::cout << "Is.data = " << (float*)Is.data << "\n"; - //std::cout << "L.data = " << (float*)L.data << "\n"; - //std::cout << "S.data = " << (float*)S.data << "\n"; - //std::cout << "G.data = " << (float*)G.data << "\n"; - //std::cout << "E.data = " << (float*)E.data << "\n"; - //std::cout << "Max G = " << *maxG << "\n"; - - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - //std::cout << "Show E\n"; - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(output_window, out); - imshow(input_window, in); - waitKey(1); - //waitKey(0); - //std::cout << "Show Is\n"; - //resize(Is, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show L\n"; - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show S\n"; - //resize(S, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show G\n"; - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Is.data); - llvm_visc_untrack_mem(L.data); - llvm_visc_untrack_mem(S.data); - llvm_visc_untrack_mem(G.data); - llvm_visc_untrack_mem(maxG); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(Gs); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - - getNextFrame(cap, src); - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - //if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - //writeColMajorMatrixFile(params->outFile, - //src.size[0], src.size[1], matE); - //} - - //std::cout << "Show Is" << "\n"; - //Mat output(src.size[0], src.size[1], CV_32F); - //imshow(output_window, Is); - //waitKey(0); - - //std::cout << "Show G" << "\n"; - //imshow(output_window, L); - //waitKey(0); - - //std::cout << "Show L" << "\n"; - //imshow(output_window, S); - //waitKey(0); - - //std::cout << "Show S" << "\n"; - //imshow(output_window, G); - //waitKey(0); - - //std::cout << "Show E" << "\n"; - //imshow(output_window, E); - //waitKey(0); - - //double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - //std::cout<< "GFLOPs = " << 2.* src.size[0] * src.size[1] * src.size[1]/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/Makefile deleted file mode 100644 index f87cb91102c01826ecf87c2e698822d7caaaef5e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/main.cc deleted file mode 100755 index 8f5c8451b85e2b02c8e4879e53d871002fc3b171..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscGPU/main.cc +++ /dev/null @@ -1,1117 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 10000 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "GPU Pipeline - Input Video"; -std::string output_window = "GPU Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m, n); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0, 0, 0); // Bind I - __visc__bindIn(GSNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 2, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 3, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 4, 4, 0); // Bind Is - __visc__bindIn(GSNode, 5, 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 6, 6, 0); // Bind m - __visc__bindIn(GSNode, 7, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m - __visc__bindOut(GSNode, 1, 1, 0); // bind output n -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx] > MIN_BR? MAX_BR : MIN_BR; - - if (gx == 0) { // left most line - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][0] = (gy > 0) ? - (L[(gy - 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? - (L[(gy + 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][2] = (gy > 0) ? - (L[(gy - 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? - (L[(gy + 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? - (L[(gy - 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][1] = (gy < m - 1)? - (L[(gy + 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(n); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind G - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 8, 8, 0); // Bind m - __visc__bindIn(CGNode, 9, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -/* - * Reduction - * G : input - * maxG: output - * m, n: input size - * Needs a single thread block - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(1, G, 1, maxG); - - void* thisNode = __visc__getNode(); - - int lx = __visc__getNodeInstanceID_x(thisNode); // threadIdx.x - int dimx = __visc__getNumNodeInstances_x(thisNode); // blockDim.x - - - // Assume a single thread block - // Thread block iterates over all elements - for (int i = lx + dimx; i < m*n; i+= dimx) { - if (G[lx] < G[i]) - G[lx] = G[i]; - } - - // First thread iterates over all elements of the thread block - if (lx == 0) { - for (int i = 1; (i < dimx) && (i < m*n); i++) - if (G[lx] < G[i]) - G[lx] = G[i]; - - *maxG = G[lx]; - } - - __visc__return(n); -} - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -//void computeMaxGradientLeaf(float *G, size_t bytesG, - //float *maxG, size_t bytesMaxG, - //int m, int n) { - - //__visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - //__visc__attributes(2, G, maxG, 1, maxG); - - //void* thisNode = __visc__getNode(); - //void* parentNode = __visc__getParentNode(thisNode); - - //int lx = __visc__getNodeInstanceID_x(thisNode); - //int px = __visc__getNodeInstanceID_x(parentNode); - //int dimx = __visc__getNumNodeInstances_x(thisNode); - - //int gid = lx + 2*px*dimx; - - //for (unsigned stride = dimx; stride > 32; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //__visc__barrier(); - //} - - //for (unsigned stride = 32; stride >= 1; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //} - - //if (lx == 0) - //__visc__atomic_max(maxG,G[gid]); - - //__visc__return(m); -//} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 5, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 6, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ - -#define THETA 0.1 -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - //float mG = 1.39203; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > THETA*mG)) ? 1.0 : 0.0 ; - } - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 0, 0 , 0); // Bind S - __visc__bindIn(RZCNode, 1, 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2 , 0); // Bind G - __visc__bindIn(RZCNode, 3, 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 5, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 6, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 7, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 8, 8 , 0); // Bind m - __visc__bindIn(RZCNode, 9, 9, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, // 0 - float *Is, size_t bytesIs, // 2 - float *L, size_t bytesL, // 4 - float *S, size_t bytesS, // 6 - float *G, size_t bytesG, // 8 - float *maxG, size_t bytesMaxG, // 10 - float *E, size_t bytesE, // 12 - float *Gs, size_t bytesGs, // 14 - float *B, size_t bytesB, // 16 - float *Sx, size_t bytesSx, // 18 - float *Sy, size_t bytesSy, // 20 - int m, // 22 - int n, // 23 - int block_x, // 24 - int grid_x // 25 - ) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - __visc__hint(visc::CPU_TARGET); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 22, 6, 1); // Bind m - __visc__bindIn(GSNode, 23, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 22, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 23, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 22, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 23, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG - __visc__bindIn(CGNode, 22, 8, 1); // Bind m - //__visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - //__visc__bindIn(CGNode, 23, 9, 1); // Bind n - __visc__edge(GSNode, CGNode, 1, 9, 1); // Get n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1); // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1); // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1); // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1); // Bind bytesMaxG - __visc__bindIn(CMGNode, 22, 4, 1); // Bind m - //__visc__edge(CGNode, CMGNode, 0, 4, 1); // Get m - //__visc__bindIn(CMGNode, 23, 5, 1); // Bind n - __visc__edge(CGNode, CMGNode, 0, 5, 1); // Get n - __visc__bindIn(CMGNode, 24, 6, 1); // Bind block_x - __visc__bindIn(CMGNode, 25, 7, 1); // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 22, 8, 1); // Bind m - __visc__edge(CZCNode, RZCNode, 0, 8, 1); // Get m - //__visc__bindIn(RZCNode, 23, 9, 1); // Bind n - __visc__edge(CMGNode, RZCNode, 0, 9, 1); // Get n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} - -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - int block_x, grid_x; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Is, L, S, G, E; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Is = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - S = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - size_t bytesMaxG = sizeof(float); - float* maxG = (float*)malloc(bytesMaxG); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - float Gs [] = { - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.002291, 0.023226, 0.092651, 0.146768, 0.092651, 0.023226, 0.002291, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036 }; - size_t bytesGs = 7*7*sizeof(float); - - block_x = 256; - // grid_x should be equal to the number of SMs on GPU. FTX 680 has 8 SMs - grid_x = 1; - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(input_window, in); - imshow(output_window, out); - waitKey(0); - - //NUM_FRAMES = 20; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - packData(args, (float*)src.data, I_sz, - (float*)Is.data, I_sz, - (float*)L.data, I_sz, - (float*)S.data, I_sz, - (float*)G.data, I_sz, - maxG, bytesMaxG, - (float*)E.data, I_sz, - Gs, bytesGs, - B, bytesB, - Sx, bytesSx, - Sy, bytesSy, - src.size[0], src.size[1], - block_x, grid_x); - - // Check if the total elements is a multiple of block size - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - //std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - *maxG = 0.0; - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Is.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - llvm_visc_track_mem(S.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - llvm_visc_track_mem(maxG, bytesMaxG); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(Gs, bytesGs); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - - __visc__push(DFG, args); - __visc__pop(DFG); - - //llvm_visc_request_mem(E.data, I_sz); - //std::cout << "Show E" << "\n"; - //imshow(window_name, E); - //waitKey(0); - //llvm_visc_request_mem(src.data, I_sz); - //llvm_visc_request_mem(Is.data, I_sz); - //llvm_visc_request_mem(L.data, I_sz); - //llvm_visc_request_mem(S.data, I_sz); - //llvm_visc_request_mem(G.data, I_sz); - llvm_visc_request_mem(maxG, bytesMaxG); - llvm_visc_request_mem(E.data, I_sz); - //std::cout << "src.data = " << (float*)src.data << "\n"; - //std::cout << "Is.data = " << (float*)Is.data << "\n"; - //std::cout << "L.data = " << (float*)L.data << "\n"; - //std::cout << "S.data = " << (float*)S.data << "\n"; - //std::cout << "G.data = " << (float*)G.data << "\n"; - //std::cout << "E.data = " << (float*)E.data << "\n"; - //std::cout << "Max G = " << *maxG << "\n"; - - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - //std::cout << "Show E\n"; - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(output_window, out); - imshow(input_window, in); - waitKey(1); - //waitKey(0); - //std::cout << "Show Is\n"; - //resize(Is, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show L\n"; - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show S\n"; - //resize(S, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show G\n"; - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Is.data); - llvm_visc_untrack_mem(L.data); - llvm_visc_untrack_mem(S.data); - llvm_visc_untrack_mem(G.data); - llvm_visc_untrack_mem(maxG); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(Gs); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - - getNextFrame(cap, src); - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - //if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - //writeColMajorMatrixFile(params->outFile, - //src.size[0], src.size[1], matE); - //} - - //std::cout << "Show Is" << "\n"; - //Mat output(src.size[0], src.size[1], CV_32F); - //imshow(output_window, Is); - //waitKey(0); - - //std::cout << "Show G" << "\n"; - //imshow(output_window, L); - //waitKey(0); - - //std::cout << "Show L" << "\n"; - //imshow(output_window, S); - //waitKey(0); - - //std::cout << "Show S" << "\n"; - //imshow(output_window, G); - //waitKey(0); - - //std::cout << "Show E" << "\n"; - //imshow(output_window, E); - //waitKey(0); - - //double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - //std::cout<< "GFLOPs = " << 2.* src.size[0] * src.size[1] * src.size[1]/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/Makefile deleted file mode 100644 index f87cb91102c01826ecf87c2e698822d7caaaef5e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/main.cc deleted file mode 100755 index 6d4b6e4304496ed555b52e630d80ff016a57d8e1..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscScalar/main.cc +++ /dev/null @@ -1,1117 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 10000 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "CPU(No vector) Pipeline - Input Video"; -std::string output_window = "CPU(No vector) Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m, n); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0, 0, 0); // Bind I - __visc__bindIn(GSNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 2, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 3, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 4, 4, 0); // Bind Is - __visc__bindIn(GSNode, 5, 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 6, 6, 0); // Bind m - __visc__bindIn(GSNode, 7, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m - __visc__bindOut(GSNode, 1, 1, 0); // bind output n -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx] > MIN_BR? MAX_BR : MIN_BR; - - if (gx == 0) { // left most line - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][0] = (gy > 0) ? - (L[(gy - 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? - (L[(gy + 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][2] = (gy > 0) ? - (L[(gy - 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? - (L[(gy + 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? - (L[(gy - 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][1] = (gy < m - 1)? - (L[(gy + 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(n); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind G - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 8, 8, 0); // Bind m - __visc__bindIn(CGNode, 9, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -/* - * Reduction - * G : input - * maxG: output - * m, n: input size - * Needs a single thread block - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(1, G, 1, maxG); - - void* thisNode = __visc__getNode(); - - int lx = __visc__getNodeInstanceID_x(thisNode); // threadIdx.x - int dimx = __visc__getNumNodeInstances_x(thisNode); // blockDim.x - - - // Assume a single thread block - // Thread block iterates over all elements - for (int i = lx + dimx; i < m*n; i+= dimx) { - if (G[lx] < G[i]) - G[lx] = G[i]; - } - - // First thread iterates over all elements of the thread block - if (lx == 0) { - for (int i = 1; (i < dimx) && (i < m*n); i++) - if (G[lx] < G[i]) - G[lx] = G[i]; - - *maxG = G[lx]; - } - - __visc__return(n); -} - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -//void computeMaxGradientLeaf(float *G, size_t bytesG, - //float *maxG, size_t bytesMaxG, - //int m, int n) { - - //__visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - //__visc__attributes(2, G, maxG, 1, maxG); - - //void* thisNode = __visc__getNode(); - //void* parentNode = __visc__getParentNode(thisNode); - - //int lx = __visc__getNodeInstanceID_x(thisNode); - //int px = __visc__getNodeInstanceID_x(parentNode); - //int dimx = __visc__getNumNodeInstances_x(thisNode); - - //int gid = lx + 2*px*dimx; - - //for (unsigned stride = dimx; stride > 32; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //__visc__barrier(); - //} - - //for (unsigned stride = 32; stride >= 1; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //} - - //if (lx == 0) - //__visc__atomic_max(maxG,G[gid]); - - //__visc__return(m); -//} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 5, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 6, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ - -#define THETA 0.1 -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - //float mG = 1.39203; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > THETA*mG)) ? 1.0 : 0.0 ; - } - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 0, 0 , 0); // Bind S - __visc__bindIn(RZCNode, 1, 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2 , 0); // Bind G - __visc__bindIn(RZCNode, 3, 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 5, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 6, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 7, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 8, 8 , 0); // Bind m - __visc__bindIn(RZCNode, 9, 9, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, // 0 - float *Is, size_t bytesIs, // 2 - float *L, size_t bytesL, // 4 - float *S, size_t bytesS, // 6 - float *G, size_t bytesG, // 8 - float *maxG, size_t bytesMaxG, // 10 - float *E, size_t bytesE, // 12 - float *Gs, size_t bytesGs, // 14 - float *B, size_t bytesB, // 16 - float *Sx, size_t bytesSx, // 18 - float *Sy, size_t bytesSy, // 20 - int m, // 22 - int n, // 23 - int block_x, // 24 - int grid_x // 25 - ) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - __visc__hint(visc::CPU_TARGET); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 22, 6, 1); // Bind m - __visc__bindIn(GSNode, 23, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 22, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 23, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 22, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 23, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG - __visc__bindIn(CGNode, 22, 8, 1); // Bind m - //__visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - //__visc__bindIn(CGNode, 23, 9, 1); // Bind n - __visc__edge(GSNode, CGNode, 1, 9, 1); // Get n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1); // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1); // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1); // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1); // Bind bytesMaxG - __visc__bindIn(CMGNode, 22, 4, 1); // Bind m - //__visc__edge(CGNode, CMGNode, 0, 4, 1); // Get m - //__visc__bindIn(CMGNode, 23, 5, 1); // Bind n - __visc__edge(CGNode, CMGNode, 0, 5, 1); // Get n - __visc__bindIn(CMGNode, 24, 6, 1); // Bind block_x - __visc__bindIn(CMGNode, 25, 7, 1); // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 22, 8, 1); // Bind m - __visc__edge(CZCNode, RZCNode, 0, 8, 1); // Get m - //__visc__bindIn(RZCNode, 23, 9, 1); // Bind n - __visc__edge(CMGNode, RZCNode, 0, 9, 1); // Get n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} - -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - int block_x, grid_x; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Is, L, S, G, E; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Is = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - S = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - size_t bytesMaxG = sizeof(float); - float* maxG = (float*)malloc(bytesMaxG); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - float Gs [] = { - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.002291, 0.023226, 0.092651, 0.146768, 0.092651, 0.023226, 0.002291, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036 }; - size_t bytesGs = 7*7*sizeof(float); - - block_x = 256; - // grid_x should be equal to the number of SMs on GPU. FTX 680 has 8 SMs - grid_x = 1; - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(input_window, in); - imshow(output_window, out); - waitKey(0); - - //NUM_FRAMES = 20; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - packData(args, (float*)src.data, I_sz, - (float*)Is.data, I_sz, - (float*)L.data, I_sz, - (float*)S.data, I_sz, - (float*)G.data, I_sz, - maxG, bytesMaxG, - (float*)E.data, I_sz, - Gs, bytesGs, - B, bytesB, - Sx, bytesSx, - Sy, bytesSy, - src.size[0], src.size[1], - block_x, grid_x); - - // Check if the total elements is a multiple of block size - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - //std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - *maxG = 0.0; - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Is.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - llvm_visc_track_mem(S.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - llvm_visc_track_mem(maxG, bytesMaxG); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(Gs, bytesGs); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - - __visc__push(DFG, args); - __visc__pop(DFG); - - //llvm_visc_request_mem(E.data, I_sz); - //std::cout << "Show E" << "\n"; - //imshow(window_name, E); - //waitKey(0); - //llvm_visc_request_mem(src.data, I_sz); - //llvm_visc_request_mem(Is.data, I_sz); - //llvm_visc_request_mem(L.data, I_sz); - //llvm_visc_request_mem(S.data, I_sz); - //llvm_visc_request_mem(G.data, I_sz); - llvm_visc_request_mem(maxG, bytesMaxG); - llvm_visc_request_mem(E.data, I_sz); - //std::cout << "src.data = " << (float*)src.data << "\n"; - //std::cout << "Is.data = " << (float*)Is.data << "\n"; - //std::cout << "L.data = " << (float*)L.data << "\n"; - //std::cout << "S.data = " << (float*)S.data << "\n"; - //std::cout << "G.data = " << (float*)G.data << "\n"; - //std::cout << "E.data = " << (float*)E.data << "\n"; - //std::cout << "Max G = " << *maxG << "\n"; - - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - //std::cout << "Show E\n"; - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(output_window, out); - imshow(input_window, in); - waitKey(1); - //waitKey(0); - //std::cout << "Show Is\n"; - //resize(Is, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show L\n"; - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show S\n"; - //resize(S, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show G\n"; - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Is.data); - llvm_visc_untrack_mem(L.data); - llvm_visc_untrack_mem(S.data); - llvm_visc_untrack_mem(G.data); - llvm_visc_untrack_mem(maxG); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(Gs); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - - getNextFrame(cap, src); - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - //if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - //writeColMajorMatrixFile(params->outFile, - //src.size[0], src.size[1], matE); - //} - - //std::cout << "Show Is" << "\n"; - //Mat output(src.size[0], src.size[1], CV_32F); - //imshow(output_window, Is); - //waitKey(0); - - //std::cout << "Show G" << "\n"; - //imshow(output_window, L); - //waitKey(0); - - //std::cout << "Show L" << "\n"; - //imshow(output_window, S); - //waitKey(0); - - //std::cout << "Show S" << "\n"; - //imshow(output_window, G); - //waitKey(0); - - //std::cout << "Show E" << "\n"; - //imshow(output_window, E); - //waitKey(0); - - //double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - //std::cout<< "GFLOPs = " << 2.* src.size[0] * src.size[1] * src.size[1]/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/Makefile deleted file mode 100644 index f87cb91102c01826ecf87c2e698822d7caaaef5e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/main.cc deleted file mode 100755 index 22197ad6fb4905660fedef106210d27f31543709..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-MaxG/main.cc +++ /dev/null @@ -1,1117 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 10000 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "Vector-CPU(No Vector)-MaxG Pipeline - Input Video"; -std::string output_window = "Vector-CPU(No Vector)-MaxG Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m, n); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0, 0, 0); // Bind I - __visc__bindIn(GSNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 2, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 3, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 4, 4, 0); // Bind Is - __visc__bindIn(GSNode, 5, 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 6, 6, 0); // Bind m - __visc__bindIn(GSNode, 7, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m - __visc__bindOut(GSNode, 1, 1, 0); // bind output n -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx] > MIN_BR? MAX_BR : MIN_BR; - - if (gx == 0) { // left most line - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][0] = (gy > 0) ? - (L[(gy - 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? - (L[(gy + 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][2] = (gy > 0) ? - (L[(gy - 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? - (L[(gy + 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? - (L[(gy - 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][1] = (gy < m - 1)? - (L[(gy + 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(n); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind G - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 8, 8, 0); // Bind m - __visc__bindIn(CGNode, 9, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -/* - * Reduction - * G : input - * maxG: output - * m, n: input size - * Needs a single thread block - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(1, G, 1, maxG); - - void* thisNode = __visc__getNode(); - - int lx = __visc__getNodeInstanceID_x(thisNode); // threadIdx.x - int dimx = __visc__getNumNodeInstances_x(thisNode); // blockDim.x - - - // Assume a single thread block - // Thread block iterates over all elements - for (int i = lx + dimx; i < m*n; i+= dimx) { - if (G[lx] < G[i]) - G[lx] = G[i]; - } - - // First thread iterates over all elements of the thread block - if (lx == 0) { - for (int i = 1; (i < dimx) && (i < m*n); i++) - if (G[lx] < G[i]) - G[lx] = G[i]; - - *maxG = G[lx]; - } - - __visc__return(n); -} - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -//void computeMaxGradientLeaf(float *G, size_t bytesG, - //float *maxG, size_t bytesMaxG, - //int m, int n) { - - //__visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - //__visc__attributes(2, G, maxG, 1, maxG); - - //void* thisNode = __visc__getNode(); - //void* parentNode = __visc__getParentNode(thisNode); - - //int lx = __visc__getNodeInstanceID_x(thisNode); - //int px = __visc__getNodeInstanceID_x(parentNode); - //int dimx = __visc__getNumNodeInstances_x(thisNode); - - //int gid = lx + 2*px*dimx; - - //for (unsigned stride = dimx; stride > 32; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //__visc__barrier(); - //} - - //for (unsigned stride = 32; stride >= 1; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //} - - //if (lx == 0) - //__visc__atomic_max(maxG,G[gid]); - - //__visc__return(m); -//} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 5, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 6, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ - -#define THETA 0.1 -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - //float mG = 1.39203; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > THETA*mG)) ? 1.0 : 0.0 ; - } - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 0, 0 , 0); // Bind S - __visc__bindIn(RZCNode, 1, 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2 , 0); // Bind G - __visc__bindIn(RZCNode, 3, 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 5, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 6, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 7, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 8, 8 , 0); // Bind m - __visc__bindIn(RZCNode, 9, 9, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, // 0 - float *Is, size_t bytesIs, // 2 - float *L, size_t bytesL, // 4 - float *S, size_t bytesS, // 6 - float *G, size_t bytesG, // 8 - float *maxG, size_t bytesMaxG, // 10 - float *E, size_t bytesE, // 12 - float *Gs, size_t bytesGs, // 14 - float *B, size_t bytesB, // 16 - float *Sx, size_t bytesSx, // 18 - float *Sy, size_t bytesSy, // 20 - int m, // 22 - int n, // 23 - int block_x, // 24 - int grid_x // 25 - ) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - __visc__hint(visc::CPU_TARGET); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 22, 6, 1); // Bind m - __visc__bindIn(GSNode, 23, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 22, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 23, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 22, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 23, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG - __visc__bindIn(CGNode, 22, 8, 1); // Bind m - //__visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - //__visc__bindIn(CGNode, 23, 9, 1); // Bind n - __visc__edge(GSNode, CGNode, 1, 9, 1); // Get n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1); // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1); // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1); // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1); // Bind bytesMaxG - __visc__bindIn(CMGNode, 22, 4, 1); // Bind m - //__visc__edge(CGNode, CMGNode, 0, 4, 1); // Get m - //__visc__bindIn(CMGNode, 23, 5, 1); // Bind n - __visc__edge(CGNode, CMGNode, 0, 5, 1); // Get n - __visc__bindIn(CMGNode, 24, 6, 1); // Bind block_x - __visc__bindIn(CMGNode, 25, 7, 1); // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 22, 8, 1); // Bind m - __visc__edge(CZCNode, RZCNode, 0, 8, 1); // Get m - //__visc__bindIn(RZCNode, 23, 9, 1); // Bind n - __visc__edge(CMGNode, RZCNode, 0, 9, 1); // Get n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} - -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - int block_x, grid_x; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Is, L, S, G, E; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Is = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - S = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - size_t bytesMaxG = sizeof(float); - float* maxG = (float*)malloc(bytesMaxG); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - float Gs [] = { - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.002291, 0.023226, 0.092651, 0.146768, 0.092651, 0.023226, 0.002291, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036 }; - size_t bytesGs = 7*7*sizeof(float); - - block_x = 256; - // grid_x should be equal to the number of SMs on GPU. FTX 680 has 8 SMs - grid_x = 1; - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(input_window, in); - imshow(output_window, out); - waitKey(0); - - //NUM_FRAMES = 20; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - packData(args, (float*)src.data, I_sz, - (float*)Is.data, I_sz, - (float*)L.data, I_sz, - (float*)S.data, I_sz, - (float*)G.data, I_sz, - maxG, bytesMaxG, - (float*)E.data, I_sz, - Gs, bytesGs, - B, bytesB, - Sx, bytesSx, - Sy, bytesSy, - src.size[0], src.size[1], - block_x, grid_x); - - // Check if the total elements is a multiple of block size - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - //std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - *maxG = 0.0; - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Is.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - llvm_visc_track_mem(S.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - llvm_visc_track_mem(maxG, bytesMaxG); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(Gs, bytesGs); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - - __visc__push(DFG, args); - __visc__pop(DFG); - - //llvm_visc_request_mem(E.data, I_sz); - //std::cout << "Show E" << "\n"; - //imshow(window_name, E); - //waitKey(0); - //llvm_visc_request_mem(src.data, I_sz); - //llvm_visc_request_mem(Is.data, I_sz); - //llvm_visc_request_mem(L.data, I_sz); - //llvm_visc_request_mem(S.data, I_sz); - //llvm_visc_request_mem(G.data, I_sz); - llvm_visc_request_mem(maxG, bytesMaxG); - llvm_visc_request_mem(E.data, I_sz); - //std::cout << "src.data = " << (float*)src.data << "\n"; - //std::cout << "Is.data = " << (float*)Is.data << "\n"; - //std::cout << "L.data = " << (float*)L.data << "\n"; - //std::cout << "S.data = " << (float*)S.data << "\n"; - //std::cout << "G.data = " << (float*)G.data << "\n"; - //std::cout << "E.data = " << (float*)E.data << "\n"; - //std::cout << "Max G = " << *maxG << "\n"; - - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - //std::cout << "Show E\n"; - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(output_window, out); - imshow(input_window, in); - waitKey(1); - //waitKey(0); - //std::cout << "Show Is\n"; - //resize(Is, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show L\n"; - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show S\n"; - //resize(S, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show G\n"; - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Is.data); - llvm_visc_untrack_mem(L.data); - llvm_visc_untrack_mem(S.data); - llvm_visc_untrack_mem(G.data); - llvm_visc_untrack_mem(maxG); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(Gs); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - - getNextFrame(cap, src); - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - //if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - //writeColMajorMatrixFile(params->outFile, - //src.size[0], src.size[1], matE); - //} - - //std::cout << "Show Is" << "\n"; - //Mat output(src.size[0], src.size[1], CV_32F); - //imshow(output_window, Is); - //waitKey(0); - - //std::cout << "Show G" << "\n"; - //imshow(output_window, L); - //waitKey(0); - - //std::cout << "Show L" << "\n"; - //imshow(output_window, S); - //waitKey(0); - - //std::cout << "Show S" << "\n"; - //imshow(output_window, G); - //waitKey(0); - - //std::cout << "Show E" << "\n"; - //imshow(output_window, E); - //waitKey(0); - - //double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - //std::cout<< "GFLOPs = " << 2.* src.size[0] * src.size[1] * src.size[1]/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/Makefile deleted file mode 100644 index f87cb91102c01826ecf87c2e698822d7caaaef5e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/main.cc deleted file mode 100755 index a061fc03e9e63d9dd12b2628ca3d72eeac9f8a6f..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector-Scalar-ZC/main.cc +++ /dev/null @@ -1,1117 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 10000 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "Vector-CPU(No Vector)-ZC Pipeline - Input Video"; -std::string output_window = "Vector-CPU(No Vector)-ZC Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m, n); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0, 0, 0); // Bind I - __visc__bindIn(GSNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 2, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 3, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 4, 4, 0); // Bind Is - __visc__bindIn(GSNode, 5, 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 6, 6, 0); // Bind m - __visc__bindIn(GSNode, 7, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m - __visc__bindOut(GSNode, 1, 1, 0); // bind output n -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx] > MIN_BR? MAX_BR : MIN_BR; - - if (gx == 0) { // left most line - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][0] = (gy > 0) ? - (L[(gy - 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? - (L[(gy + 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][2] = (gy > 0) ? - (L[(gy - 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? - (L[(gy + 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? - (L[(gy - 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][1] = (gy < m - 1)? - (L[(gy + 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(n); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind G - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 8, 8, 0); // Bind m - __visc__bindIn(CGNode, 9, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -/* - * Reduction - * G : input - * maxG: output - * m, n: input size - * Needs a single thread block - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(1, G, 1, maxG); - - void* thisNode = __visc__getNode(); - - int lx = __visc__getNodeInstanceID_x(thisNode); // threadIdx.x - int dimx = __visc__getNumNodeInstances_x(thisNode); // blockDim.x - - - // Assume a single thread block - // Thread block iterates over all elements - for (int i = lx + dimx; i < m*n; i+= dimx) { - if (G[lx] < G[i]) - G[lx] = G[i]; - } - - // First thread iterates over all elements of the thread block - if (lx == 0) { - for (int i = 1; (i < dimx) && (i < m*n); i++) - if (G[lx] < G[i]) - G[lx] = G[i]; - - *maxG = G[lx]; - } - - __visc__return(n); -} - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -//void computeMaxGradientLeaf(float *G, size_t bytesG, - //float *maxG, size_t bytesMaxG, - //int m, int n) { - - //__visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - //__visc__attributes(2, G, maxG, 1, maxG); - - //void* thisNode = __visc__getNode(); - //void* parentNode = __visc__getParentNode(thisNode); - - //int lx = __visc__getNodeInstanceID_x(thisNode); - //int px = __visc__getNodeInstanceID_x(parentNode); - //int dimx = __visc__getNumNodeInstances_x(thisNode); - - //int gid = lx + 2*px*dimx; - - //for (unsigned stride = dimx; stride > 32; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //__visc__barrier(); - //} - - //for (unsigned stride = 32; stride >= 1; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //} - - //if (lx == 0) - //__visc__atomic_max(maxG,G[gid]); - - //__visc__return(m); -//} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 5, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 6, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ - -#define THETA 0.1 -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - //float mG = 1.39203; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > THETA*mG)) ? 1.0 : 0.0 ; - } - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 0, 0 , 0); // Bind S - __visc__bindIn(RZCNode, 1, 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2 , 0); // Bind G - __visc__bindIn(RZCNode, 3, 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 5, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 6, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 7, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 8, 8 , 0); // Bind m - __visc__bindIn(RZCNode, 9, 9, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, // 0 - float *Is, size_t bytesIs, // 2 - float *L, size_t bytesL, // 4 - float *S, size_t bytesS, // 6 - float *G, size_t bytesG, // 8 - float *maxG, size_t bytesMaxG, // 10 - float *E, size_t bytesE, // 12 - float *Gs, size_t bytesGs, // 14 - float *B, size_t bytesB, // 16 - float *Sx, size_t bytesSx, // 18 - float *Sy, size_t bytesSy, // 20 - int m, // 22 - int n, // 23 - int block_x, // 24 - int grid_x // 25 - ) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - __visc__hint(visc::CPU_TARGET); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 22, 6, 1); // Bind m - __visc__bindIn(GSNode, 23, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 22, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 23, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 22, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 23, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG - __visc__bindIn(CGNode, 22, 8, 1); // Bind m - //__visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - //__visc__bindIn(CGNode, 23, 9, 1); // Bind n - __visc__edge(GSNode, CGNode, 1, 9, 1); // Get n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1); // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1); // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1); // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1); // Bind bytesMaxG - __visc__bindIn(CMGNode, 22, 4, 1); // Bind m - //__visc__edge(CGNode, CMGNode, 0, 4, 1); // Get m - //__visc__bindIn(CMGNode, 23, 5, 1); // Bind n - __visc__edge(CGNode, CMGNode, 0, 5, 1); // Get n - __visc__bindIn(CMGNode, 24, 6, 1); // Bind block_x - __visc__bindIn(CMGNode, 25, 7, 1); // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 22, 8, 1); // Bind m - __visc__edge(CZCNode, RZCNode, 0, 8, 1); // Get m - //__visc__bindIn(RZCNode, 23, 9, 1); // Bind n - __visc__edge(CMGNode, RZCNode, 0, 9, 1); // Get n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} - -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - int block_x, grid_x; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Is, L, S, G, E; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Is = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - S = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - size_t bytesMaxG = sizeof(float); - float* maxG = (float*)malloc(bytesMaxG); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - float Gs [] = { - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.002291, 0.023226, 0.092651, 0.146768, 0.092651, 0.023226, 0.002291, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036 }; - size_t bytesGs = 7*7*sizeof(float); - - block_x = 256; - // grid_x should be equal to the number of SMs on GPU. FTX 680 has 8 SMs - grid_x = 1; - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(input_window, in); - imshow(output_window, out); - waitKey(0); - - //NUM_FRAMES = 20; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - packData(args, (float*)src.data, I_sz, - (float*)Is.data, I_sz, - (float*)L.data, I_sz, - (float*)S.data, I_sz, - (float*)G.data, I_sz, - maxG, bytesMaxG, - (float*)E.data, I_sz, - Gs, bytesGs, - B, bytesB, - Sx, bytesSx, - Sy, bytesSy, - src.size[0], src.size[1], - block_x, grid_x); - - // Check if the total elements is a multiple of block size - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - //std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - *maxG = 0.0; - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Is.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - llvm_visc_track_mem(S.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - llvm_visc_track_mem(maxG, bytesMaxG); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(Gs, bytesGs); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - - __visc__push(DFG, args); - __visc__pop(DFG); - - //llvm_visc_request_mem(E.data, I_sz); - //std::cout << "Show E" << "\n"; - //imshow(window_name, E); - //waitKey(0); - //llvm_visc_request_mem(src.data, I_sz); - //llvm_visc_request_mem(Is.data, I_sz); - //llvm_visc_request_mem(L.data, I_sz); - //llvm_visc_request_mem(S.data, I_sz); - //llvm_visc_request_mem(G.data, I_sz); - llvm_visc_request_mem(maxG, bytesMaxG); - llvm_visc_request_mem(E.data, I_sz); - //std::cout << "src.data = " << (float*)src.data << "\n"; - //std::cout << "Is.data = " << (float*)Is.data << "\n"; - //std::cout << "L.data = " << (float*)L.data << "\n"; - //std::cout << "S.data = " << (float*)S.data << "\n"; - //std::cout << "G.data = " << (float*)G.data << "\n"; - //std::cout << "E.data = " << (float*)E.data << "\n"; - //std::cout << "Max G = " << *maxG << "\n"; - - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - //std::cout << "Show E\n"; - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(output_window, out); - imshow(input_window, in); - waitKey(1); - //waitKey(0); - //std::cout << "Show Is\n"; - //resize(Is, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show L\n"; - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show S\n"; - //resize(S, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show G\n"; - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Is.data); - llvm_visc_untrack_mem(L.data); - llvm_visc_untrack_mem(S.data); - llvm_visc_untrack_mem(G.data); - llvm_visc_untrack_mem(maxG); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(Gs); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - - getNextFrame(cap, src); - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - //if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - //writeColMajorMatrixFile(params->outFile, - //src.size[0], src.size[1], matE); - //} - - //std::cout << "Show Is" << "\n"; - //Mat output(src.size[0], src.size[1], CV_32F); - //imshow(output_window, Is); - //waitKey(0); - - //std::cout << "Show G" << "\n"; - //imshow(output_window, L); - //waitKey(0); - - //std::cout << "Show L" << "\n"; - //imshow(output_window, S); - //waitKey(0); - - //std::cout << "Show S" << "\n"; - //imshow(output_window, G); - //waitKey(0); - - //std::cout << "Show E" << "\n"; - //imshow(output_window, E); - //waitKey(0); - - //double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - //std::cout<< "GFLOPs = " << 2.* src.size[0] * src.size[1] * src.size[1]/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/Makefile deleted file mode 100644 index f87cb91102c01826ecf87c2e698822d7caaaef5e..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS+=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/main.cc deleted file mode 100755 index 9cbcf57b3d384fd96dacc7844bdff7412d8c24a3..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/viscVector/main.cc +++ /dev/null @@ -1,1117 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - - -#define NUM_RUNS 10000 -#define DEPTH 3 -#define HEIGHT 640 -#define WIDTH 480 -std::string input_window = "Vector Pipeline - Input Video"; -std::string output_window = "Vector Pipeline - Edge Mapping"; - - -#ifdef MIDDLE - #define POSX_IN 640 - #define POSY_IN 0 - #define POSX_OUT 640 - #define POSY_OUT 540 - -#elif RIGHT - #define POSX_IN 1280 - #define POSY_IN 0 - #define POSX_OUT 1280 - #define POSY_OUT 540 - -#else // LEFT - #define POSX_IN 0 - #define POSY_IN 0 - #define POSX_OUT 0 - #define POSY_OUT 540 -#endif - - -//#define NUM_FRAMES 20 - - - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m, n); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0, 0, 0); // Bind I - __visc__bindIn(GSNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 2, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 3, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 4, 4, 0); // Bind Is - __visc__bindIn(GSNode, 5, 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 6, 6, 0); // Bind m - __visc__bindIn(GSNode, 7, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m - __visc__bindOut(GSNode, 1, 1, 0); // bind output n -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx] > MIN_BR? MAX_BR : MIN_BR; - - if (gx == 0) { // left most line - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][0] = (gy > 0) ? - (L[(gy - 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? - (L[(gy + 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][2] = (gy > 0) ? - (L[(gy - 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? - (L[(gy + 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? - (L[(gy - 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][1] = (gy < m - 1)? - (L[(gy + 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(n); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind G - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 8, 8, 0); // Bind m - __visc__bindIn(CGNode, 9, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -/* - * Reduction - * G : input - * maxG: output - * m, n: input size - * Needs a single thread block - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(1, G, 1, maxG); - - void* thisNode = __visc__getNode(); - - int lx = __visc__getNodeInstanceID_x(thisNode); // threadIdx.x - int dimx = __visc__getNumNodeInstances_x(thisNode); // blockDim.x - - - // Assume a single thread block - // Thread block iterates over all elements - for (int i = lx + dimx; i < m*n; i+= dimx) { - if (G[lx] < G[i]) - G[lx] = G[i]; - } - - // First thread iterates over all elements of the thread block - if (lx == 0) { - for (int i = 1; (i < dimx) && (i < m*n); i++) - if (G[lx] < G[i]) - G[lx] = G[i]; - - *maxG = G[lx]; - } - - __visc__return(n); -} - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -//void computeMaxGradientLeaf(float *G, size_t bytesG, - //float *maxG, size_t bytesMaxG, - //int m, int n) { - - //__visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - //__visc__attributes(2, G, maxG, 1, maxG); - - //void* thisNode = __visc__getNode(); - //void* parentNode = __visc__getParentNode(thisNode); - - //int lx = __visc__getNodeInstanceID_x(thisNode); - //int px = __visc__getNodeInstanceID_x(parentNode); - //int dimx = __visc__getNumNodeInstances_x(thisNode); - - //int gid = lx + 2*px*dimx; - - //for (unsigned stride = dimx; stride > 32; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //__visc__barrier(); - //} - - //for (unsigned stride = 32; stride >= 1; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //} - - //if (lx == 0) - //__visc__atomic_max(maxG,G[gid]); - - //__visc__return(m); -//} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 5, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 6, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ - -#define THETA 0.1 -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - //float mG = 1.39203; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > THETA*mG)) ? 1.0 : 0.0 ; - } - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 0, 0 , 0); // Bind S - __visc__bindIn(RZCNode, 1, 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2 , 0); // Bind G - __visc__bindIn(RZCNode, 3, 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 5, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 6, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 7, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 8, 8 , 0); // Bind m - __visc__bindIn(RZCNode, 9, 9, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, // 0 - float *Is, size_t bytesIs, // 2 - float *L, size_t bytesL, // 4 - float *S, size_t bytesS, // 6 - float *G, size_t bytesG, // 8 - float *maxG, size_t bytesMaxG, // 10 - float *E, size_t bytesE, // 12 - float *Gs, size_t bytesGs, // 14 - float *B, size_t bytesB, // 16 - float *Sx, size_t bytesSx, // 18 - float *Sy, size_t bytesSy, // 20 - int m, // 22 - int n, // 23 - int block_x, // 24 - int grid_x // 25 - ) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - __visc__hint(visc::CPU_TARGET); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 22, 6, 1); // Bind m - __visc__bindIn(GSNode, 23, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 22, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 23, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 22, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 23, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG - __visc__bindIn(CGNode, 22, 8, 1); // Bind m - //__visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - //__visc__bindIn(CGNode, 23, 9, 1); // Bind n - __visc__edge(GSNode, CGNode, 1, 9, 1); // Get n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1); // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1); // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1); // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1); // Bind bytesMaxG - __visc__bindIn(CMGNode, 22, 4, 1); // Bind m - //__visc__edge(CGNode, CMGNode, 0, 4, 1); // Get m - //__visc__bindIn(CMGNode, 23, 5, 1); // Bind n - __visc__edge(CGNode, CMGNode, 0, 5, 1); // Get n - __visc__bindIn(CMGNode, 24, 6, 1); // Bind block_x - __visc__bindIn(CMGNode, 25, 7, 1); // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 22, 8, 1); // Bind m - __visc__edge(CZCNode, RZCNode, 0, 8, 1); // Get m - //__visc__bindIn(RZCNode, 23, 9, 1); // Bind n - __visc__edge(CMGNode, RZCNode, 0, 9, 1); // Get n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} - -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -//void showInOut(Mat& Input, Mat& Output) { - //Mat in, out; - //resize(Input, in, Size(512, 768)); - //resize(Output, out, Size(512, 768)); - //imshow(input_window, in); - //imshow(output_window, out); -//} - - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - int block_x, grid_x; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - moveWindow(input_window, POSX_IN, POSY_IN); - moveWindow(output_window, POSX_OUT, POSY_OUT); - - Mat src, Is, L, S, G, E; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(!src.isContinuous()) { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Is = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - S = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = src.size[0]*src.size[1]*sizeof(float); - - size_t bytesMaxG = sizeof(float); - float* maxG = (float*)malloc(bytesMaxG); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - float Gs [] = { - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.002291, 0.023226, 0.092651, 0.146768, 0.092651, 0.023226, 0.002291, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036 }; - size_t bytesGs = 7*7*sizeof(float); - - block_x = 256; - // grid_x should be equal to the number of SMs on GPU. FTX 680 has 8 SMs - grid_x = 1; - - // Copy A and B^T into device memory - //pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - //showInOut(src, E); - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(input_window, in); - imshow(output_window, out); - waitKey(0); - - //NUM_FRAMES = 20; - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - packData(args, (float*)src.data, I_sz, - (float*)Is.data, I_sz, - (float*)L.data, I_sz, - (float*)S.data, I_sz, - (float*)G.data, I_sz, - maxG, bytesMaxG, - (float*)E.data, I_sz, - Gs, bytesGs, - B, bytesB, - Sx, bytesSx, - Sy, bytesSy, - src.size[0], src.size[1], - block_x, grid_x); - - // Check if the total elements is a multiple of block size - assert(src.size[0]*src.size[1] % block_x == 0); - - //imshow(input_window, src); - //imshow(output_window, E); - //waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - //std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - *maxG = 0.0; - - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Is.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - llvm_visc_track_mem(S.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - llvm_visc_track_mem(maxG, bytesMaxG); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(Gs, bytesGs); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - - __visc__push(DFG, args); - __visc__pop(DFG); - - //llvm_visc_request_mem(E.data, I_sz); - //std::cout << "Show E" << "\n"; - //imshow(window_name, E); - //waitKey(0); - //llvm_visc_request_mem(src.data, I_sz); - //llvm_visc_request_mem(Is.data, I_sz); - //llvm_visc_request_mem(L.data, I_sz); - //llvm_visc_request_mem(S.data, I_sz); - //llvm_visc_request_mem(G.data, I_sz); - llvm_visc_request_mem(maxG, bytesMaxG); - llvm_visc_request_mem(E.data, I_sz); - //std::cout << "src.data = " << (float*)src.data << "\n"; - //std::cout << "Is.data = " << (float*)Is.data << "\n"; - //std::cout << "L.data = " << (float*)L.data << "\n"; - //std::cout << "S.data = " << (float*)S.data << "\n"; - //std::cout << "G.data = " << (float*)G.data << "\n"; - //std::cout << "E.data = " << (float*)E.data << "\n"; - //std::cout << "Max G = " << *maxG << "\n"; - - Mat in, out; - resize(src, in, Size(HEIGHT, WIDTH)); - //std::cout << "Show E\n"; - resize(E, out, Size(HEIGHT, WIDTH)); - imshow(output_window, out); - imshow(input_window, in); - waitKey(1); - //waitKey(0); - //std::cout << "Show Is\n"; - //resize(Is, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show L\n"; - //resize(L, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show S\n"; - //resize(S, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - //std::cout << "Show G\n"; - //resize(G, out, Size(HEIGHT, WIDTH)); - //imshow(output_window, out); - //waitKey(0); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Is.data); - llvm_visc_untrack_mem(L.data); - llvm_visc_untrack_mem(S.data); - llvm_visc_untrack_mem(G.data); - llvm_visc_untrack_mem(maxG); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(Gs); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - - getNextFrame(cap, src); - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - //if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - //writeColMajorMatrixFile(params->outFile, - //src.size[0], src.size[1], matE); - //} - - //std::cout << "Show Is" << "\n"; - //Mat output(src.size[0], src.size[1], CV_32F); - //imshow(output_window, Is); - //waitKey(0); - - //std::cout << "Show G" << "\n"; - //imshow(output_window, L); - //waitKey(0); - - //std::cout << "Show L" << "\n"; - //imshow(output_window, S); - //waitKey(0); - - //std::cout << "Show S" << "\n"; - //imshow(output_window, G); - //waitKey(0); - - //std::cout << "Show E" << "\n"; - //imshow(output_window, E); - //waitKey(0); - - //double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - //std::cout<< "GFLOPs = " << 2.* src.size[0] * src.size[1] * src.size[1]/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/Makefile b/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/Makefile deleted file mode 100644 index f6c7ebfede0b947aad50dec89b2ecee55c1a36cd..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/Makefile +++ /dev/null @@ -1,12 +0,0 @@ -# (c) 2010 The Board of Trustees of the University of Illinois. - -LANGUAGE=visc -SRCDIR_OBJS=io.ll #compute_gold.o -VISC_OBJS=main.visc.ll -APP_CUDALDFLAGS=-lm -lstdc++ -APP_CFLAGS=-ffast-math -O3 -I/opt/opencv/include -APP_CXXFLAGS=-ffast-math -O3 -I/opt/opencv/include -APP_LDFLAGS=-L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib - -#OpenCV link flags all -#/usr/bin/c++ -std=c++0x CMakeFiles/EdgeDetect.dir/EdgeDetect.cpp.o -o EdgeDetect -L/usr/local/cuda/lib64 -rdynamic /opt/opencv/lib/libopencv_videostab.so.3.0.0 /opt/opencv/lib/libopencv_videoio.so.3.0.0 /opt/opencv/lib/libopencv_video.so.3.0.0 /opt/opencv/lib/libopencv_superres.so.3.0.0 /opt/opencv/lib/libopencv_stitching.so.3.0.0 /opt/opencv/lib/libopencv_shape.so.3.0.0 /opt/opencv/lib/libopencv_photo.so.3.0.0 /opt/opencv/lib/libopencv_objdetect.so.3.0.0 /opt/opencv/lib/libopencv_ml.so.3.0.0 /opt/opencv/lib/libopencv_imgproc.so.3.0.0 /opt/opencv/lib/libopencv_imgcodecs.so.3.0.0 /opt/opencv/lib/libopencv_highgui.so.3.0.0 /opt/opencv/lib/libopencv_hal.a /opt/opencv/lib/libopencv_flann.so.3.0.0 /opt/opencv/lib/libopencv_features2d.so.3.0.0 /opt/opencv/lib/libopencv_cudev.so.3.0.0 /opt/opencv/lib/libopencv_cudawarping.so.3.0.0 /opt/opencv/lib/libopencv_cudastereo.so.3.0.0 /opt/opencv/lib/libopencv_cudaoptflow.so.3.0.0 /opt/opencv/lib/libopencv_cudaobjdetect.so.3.0.0 /opt/opencv/lib/libopencv_cudalegacy.so.3.0.0 /opt/opencv/lib/libopencv_cudaimgproc.so.3.0.0 /opt/opencv/lib/libopencv_cudafilters.so.3.0.0 /opt/opencv/lib/libopencv_cudafeatures2d.so.3.0.0 /opt/opencv/lib/libopencv_cudacodec.so.3.0.0 /opt/opencv/lib/libopencv_cudabgsegm.so.3.0.0 /opt/opencv/lib/libopencv_cudaarithm.so.3.0.0 /opt/opencv/lib/libopencv_core.so.3.0.0 /opt/opencv/lib/libopencv_calib3d.so.3.0.0 /opt/opencv/lib/libopencv_hal.a -ldl -lm -lpthread -lrt /opt/opencv/share/OpenCV/3rdparty/lib/libippicv.a -lcudart -lnpp -lcufft -lcudart -lnpp -lcufft -Wl,-rpath,/usr/local/cuda/lib64:/opt/opencv/lib diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/main.cc b/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/main.cc deleted file mode 100755 index d6744c088373f4844eba0b52cdc211838aa70748..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc_demo/main.cc +++ /dev/null @@ -1,1044 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* - * Main entry of dense matrix-matrix multiplication kernel - */ - -#include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" -#include <stdio.h> -#include <math.h> -#include <stdlib.h> -#include <string.h> -#include <sys/time.h> -#include <malloc.h> -#include <iostream> -#include <cassert> -#include <parboil.h> -#include <visc.h> - -// Definitions of sizes for edge detection kernels - -#define MIN_BR 0.0f -#define MAX_BR 1.0f - -// Code needs to be changed for this to vary -#define SZB 3 - -#define REDUCTION_TILE_SZ 1024 - -#define _MIN(X,Y) ((X) < (Y) ? (X) : (Y)) -#define _MAX(X,Y) ((X) > (Y) ? (X) : (Y)) - -extern "C" { - -struct __attribute__((__packed__)) InStruct { - float* I ; - size_t bytesI; - float* Is ; - size_t bytesIs; - float* L; - size_t bytesL; - float* S; - size_t bytesS; - float* G; - size_t bytesG; - float* maxG; - size_t bytesMaxG; - float* E; - size_t bytesE; - float* Gs; - size_t bytesGs; - float* B; - size_t bytesB; - float* Sx; - size_t bytesSx; - float* Sy; - size_t bytesSy; - int m; - int n; - int block_x; - int grid_x; -}; - - -void packData(struct InStruct* args, float* I, size_t bytesI, - float* Is, size_t bytesIs, - float* L, size_t bytesL, - float* S, size_t bytesS, - float* G, size_t bytesG, - float* maxG, size_t bytesMaxG, - float* E, size_t bytesE, - float* Gs, size_t bytesGs, - float* B, size_t bytesB, - float* Sx, size_t bytesSx, - float* Sy, size_t bytesSy, - int m, int n, - int block_x, int grid_x) { - args->I = I; - args->bytesI = bytesI; - args->Is = Is; - args->bytesIs = bytesIs; - args->L = L; - args->bytesL = bytesL; - args->S = S; - args->bytesS = bytesS; - args->G = G; - args->bytesG = bytesG; - args->maxG = maxG; - args->bytesMaxG = bytesMaxG; - args->E = E; - args->bytesE = bytesE; - args->Gs = Gs; - args->bytesGs = bytesGs; - args->B = B; - args->bytesB = bytesB; - args->Sx = Sx; - args->bytesSx = bytesSx; - args->Sy = Sy; - args->bytesSy = bytesSy; - args->m = m; - args->n = n; - args->block_x = block_x; - args->grid_x = grid_x; -} - -/* - * Gaussian smoothing of image I of size m x n - * I : input image - * Gs : gaussian filter - * Is: output (smoothed image) - * m, n : dimensions - * - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define GAUSSIAN_SIZE 7 -#define GAUSSIAN_RADIUS (GAUSSIAN_SIZE / 2) -void gaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(2, I, Gs, 1, Is); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float smoothedVal = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -GAUSSIAN_RADIUS; i <= GAUSSIAN_RADIUS; i++) - for (int j = -GAUSSIAN_RADIUS; j <= GAUSSIAN_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = I[loadOffset]; - smoothedVal += gval * Gs[(GAUSSIAN_RADIUS + i)*GAUSSIAN_SIZE + GAUSSIAN_RADIUS + j]; - } - - Is[gloc] = smoothedVal; - } - __visc__return(m); -} - -void WrapperGaussianSmoothing(float *I, size_t bytesI, - float *Gs, size_t bytesGs, - float *Is, size_t bytesIs, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, I, Gs, 1, Is); - void* GSNode = __visc__createNode2D(gaussianSmoothing, m, n); - __visc__bindIn(GSNode, 0, 0, 0); // Bind I - __visc__bindIn(GSNode, 1, 1, 0); // Bind bytesI - __visc__bindIn(GSNode, 2, 2, 0); // Bind Gs - __visc__bindIn(GSNode, 3, 3, 0); // Bind bytesGs - __visc__bindIn(GSNode, 4, 4, 0); // Bind Is - __visc__bindIn(GSNode, 5, 5, 0); // Bind bytesIs - __visc__bindIn(GSNode, 6, 6, 0); // Bind m - __visc__bindIn(GSNode, 7, 7, 0); // Bind n - - __visc__bindOut(GSNode, 0, 0, 0); // bind output m -} - - -/* Compute a non-linear laplacian estimate of input image I of size m x n */ -/* - * Is : blurred imput image - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * L : output (laplacian of the image) - * Need 2D grid, a thread per pixel -*/ -void laplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - - __visc__hint(visc::DEVICE); - //__visc__hint(visc::GPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - //if(gx == 0 && gy == 0) - //std::cout << "Entered laplacian\n"; - - int i, j; - - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = Is[gy * n + gx]; - - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = Is[gy * n + gx - 1]; - imageArea[0][0] = (gy > 0) ? Is[(gy - 1) * n + gx - 1] : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? Is[(gy + 1) * n + gx - 1] : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = Is[gy * n + gx + 1]; - imageArea[0][2] = (gy > 0) ? Is[(gy - 1) * n + gx + 1] : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? Is[(gy + 1) * n + gx + 1] : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? Is[(gy - 1) * n + gx] : MIN_BR; - imageArea[2][1] = (gy < m - 1) ? Is[(gy + 1) * n + gx] : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float laplacian = dilatedPixel + erodedPixel - 2 * imageArea[1][1]; - L[gy*n+gx] = laplacian; - } - //OutStruct output = {bytesB, bytesL}; - //if(gx == m-1 && gy == n-1) - //std::cout << "Exit laplacian\n"; - __visc__return(m); -} - -void WrapperlaplacianEstimate(float *Is, size_t bytesIs, - float *B, size_t bytesB, - float *L, size_t bytesL, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, Is, B, 1, L); - void* LNode = __visc__createNode2D(laplacianEstimate, m, n); - __visc__bindIn(LNode, 0, 0, 0); // Bind Is - __visc__bindIn(LNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(LNode, 2, 2, 0); // Bind B - __visc__bindIn(LNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(LNode, 4, 4, 0); // Bind L - __visc__bindIn(LNode, 5, 5, 0); // Bind bytesL - __visc__bindIn(LNode, 6, 6, 0); // Bind m - __visc__bindIn(LNode, 7, 7, 0); // Bind n - - __visc__bindOut(LNode, 0, 0, 0); // bind output m - -} - -/* Compute the zero crossings of input image L of size m x n */ -/* - * L : imput image (computed Laplacian) - * m, n : dimensions - * B : structural element for dilation - erosion ([0 1 0; 1 1 1; 0 1 0]) - * S : output (sign of the image) - * Need 2D grid, a thread per pixel - */ -void computeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::DEVICE); - //__visc__hint(visc::SPIR_TARGET); - __visc__attributes(2, L, B, 1, S); - - // 3x3 image area - float imageArea[SZB][SZB]; - - //int gx = get_global_id(0); - //int gy = get_global_id(1); - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - int i, j; - - //if(gx == 0 && gy == 0) - //std::cout << "Entered ZC\n"; - if ((gx < n) && (gy < m)) { - // Data copy for dilation filter - imageArea[1][1] = L[gy * n + gx] > MIN_BR? MAX_BR : MIN_BR; - - if (gx == 0) { // left most line - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MIN_BR; - } else { - imageArea[1][0] = L[gy * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][0] = (gy > 0) ? - (L[(gy - 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][0] = (gy < m - 1) ? - (L[(gy + 1) * n + gx - 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MIN_BR; - } else { - imageArea[1][2] = L[gy * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR; - imageArea[0][2] = (gy > 0) ? - (L[(gy - 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][2] = (gy < m - 1) ? - (L[(gy + 1) * n + gx + 1] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - } - - imageArea[0][1] = (gy > 0) ? - (L[(gy - 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - imageArea[2][1] = (gy < m - 1)? - (L[(gy + 1) * n + gx] > MIN_BR? MAX_BR : MIN_BR) - : MIN_BR; - - // Compute pixel of dilated image - float dilatedPixel = MIN_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - dilatedPixel = _MAX(dilatedPixel, imageArea[i][j] * B[i*SZB + j]); - - // Data copy for erotion filter - only change the boundary conditions - if (gx == 0) { - imageArea[0][0] = imageArea[1][0] = imageArea[2][0] = MAX_BR; - } else { - if (gy == 0) imageArea[0][0] = MAX_BR; - if (gy == m-1) imageArea[2][0] = MAX_BR; - } - - if (gx == n - 1) { - imageArea[0][2] = imageArea[1][2] = imageArea[2][2] = MAX_BR; - } else { - if (gy == 0) imageArea[0][2] = MAX_BR; - if (gy == m-1) imageArea[2][2] = MAX_BR; - } - - if (gy == 0) imageArea[0][1] = MAX_BR; - if (gy == m-1) imageArea[2][1] = MAX_BR; - - // Compute pixel of eroded image - float erodedPixel = MAX_BR; - for (i = 0; i < SZB; i++) - for (j = 0; j < SZB; j++) - erodedPixel = _MIN(erodedPixel, imageArea[i][j] * B[i*SZB + j]); - - float pixelSign = dilatedPixel - erodedPixel; - S[gy*n+gx] = pixelSign; - } - //OutStruct output = {bytesB, bytesS}; - //if(gx == n-1 && gy == n-1) - //std::cout << "Exit ZC\n"; - __visc__return(m); -} - -void WrapperComputeZeroCrossings(float *L, size_t bytesL, - float *B, size_t bytesB, - float *S, size_t bytesS, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, L, B, 1, S); - void* ZCNode = __visc__createNode2D(computeZeroCrossings, m, n); - __visc__bindIn(ZCNode, 0, 0, 0); // Bind L - __visc__bindIn(ZCNode, 1, 1, 0); // Bind bytesL - __visc__bindIn(ZCNode, 2, 2, 0); // Bind B - __visc__bindIn(ZCNode, 3, 3, 0); // Bind bytesB - __visc__bindIn(ZCNode, 4, 4, 0); // Bind S - __visc__bindIn(ZCNode, 5, 5, 0); // Bind bytesS - __visc__bindIn(ZCNode, 6, 6, 0); // Bind m - __visc__bindIn(ZCNode, 7, 7, 0); // Bind n - - __visc__bindOut(ZCNode, 0, 0, 0); // bind output m - -} - -/* - * Gradient computation using Sobel filters - * Is : input (smoothed image) - * Sx, Sy: Sobel operators - * - Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - * - Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - * m, n : dimensions - * G: output, gradient magnitude : sqrt(Gx^2+Gy^2) - * Need 2D grid, a thread per pixel - * No use of separable algorithm because we need to do this in one kernel - * No use of shared memory because - * - we don't handle it in the X86 pass - */ - -#define SOBEL_SIZE 3 -#define SOBEL_RADIUS (SOBEL_SIZE / 2) - -void computeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(3, Is, Sx, Sy, 1, G); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - int gloc = gx + gy*n; - - float Gx = 0; - float Gy = 0; - float gval; - int loadOffset; - - if ((gx < n) && (gy < m)) { - for (int i = -SOBEL_RADIUS; i <= SOBEL_RADIUS; i++) - for (int j = -SOBEL_RADIUS; j <= SOBEL_RADIUS; j++) { - - loadOffset = gloc + i*n + j; - - if ((gy + i) < 0) // top contour - loadOffset = gx + j; - else if ((gy + i) > m-1 ) // bottom contour - loadOffset = (m-1)*n + gx + j; - else - loadOffset = gloc + i*n + j; // within image vertically - - // Adjust so we are within image horizonally - if ((gx + j) < 0) // left contour - loadOffset -= (gx+j); - else if ((gx + j) > n-1 ) // right contour - loadOffset = loadOffset - gx - j + n - 1; - - gval = Is[loadOffset]; - Gx += gval * Sx[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - Gy += gval * Sy[(SOBEL_RADIUS + i)*SOBEL_SIZE + SOBEL_RADIUS + j]; - } - - G[gloc] = __visc__sqrt(Gx*Gx + Gy*Gy); - //G[gloc] = Gx*Gx + Gy*Gy; - } - __visc__return(m); -} - -void WrapperComputeGradient(float *Is, size_t bytesIs, - float *Sx, size_t bytesSx, - float *Sy, size_t bytesSy, - float *G, size_t bytesG, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, Is, Sx, Sy, 1, G); - void* CGNode = __visc__createNode2D(computeGradient, m, n); - __visc__bindIn(CGNode, 0, 0, 0); // Bind Is - __visc__bindIn(CGNode, 1, 1, 0); // Bind bytesIs - __visc__bindIn(CGNode, 2, 2, 0); // Bind Sx - __visc__bindIn(CGNode, 3, 3, 0); // Bind bytesSx - __visc__bindIn(CGNode, 4, 4, 0); // Bind Sy - __visc__bindIn(CGNode, 5, 5, 0); // Bind bytesSy - __visc__bindIn(CGNode, 6, 6, 0); // Bind G - __visc__bindIn(CGNode, 7, 7, 0); // Bind bytesG - __visc__bindIn(CGNode, 8, 8, 0); // Bind m - __visc__bindIn(CGNode, 9, 9, 0); // Bind n - - __visc__bindOut(CGNode, 0, 0, 0); // bind output m -} - -/* - * Reduction - * G : input - * maxG: output - * m, n: input size - * Needs a single thread block - */ -void computeMaxGradientLeaf(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n) { - - __visc__hint(visc::DEVICE); - __visc__attributes(1, G, 1, maxG); - - void* thisNode = __visc__getNode(); - - int lx = __visc__getNodeInstanceID_x(thisNode); // threadIdx.x - int dimx = __visc__getNumNodeInstances_x(thisNode); // blockDim.x - - - // Assume a single thread block - // Thread block iterates over all elements - for (int i = lx + dimx; i < m*n; i+= dimx) { - if (G[lx] < G[i]) - G[lx] = G[i]; - } - - // First thread iterates over all elements of the thread block - if (lx == 0) { - for (int i = 1; (i < dimx) && (i < m*n); i++) - if (G[lx] < G[i]) - G[lx] = G[i]; - - *maxG = G[lx]; - } - - __visc__return(m); -} - -/* - * Reduction - * G : input - * maxG: output - * Each static node processes 2*nodeDim elements - * Need 1D grid, a thread per 2 pixels - */ -//void computeMaxGradientLeaf(float *G, size_t bytesG, - //float *maxG, size_t bytesMaxG, - //int m, int n) { - - //__visc__hint(visc::DEVICE); - //TODO: maxG should be initialized to zero (MIN_BR) every time - //__visc__attributes(2, G, maxG, 1, maxG); - - //void* thisNode = __visc__getNode(); - //void* parentNode = __visc__getParentNode(thisNode); - - //int lx = __visc__getNodeInstanceID_x(thisNode); - //int px = __visc__getNodeInstanceID_x(parentNode); - //int dimx = __visc__getNumNodeInstances_x(thisNode); - - //int gid = lx + 2*px*dimx; - - //for (unsigned stride = dimx; stride > 32; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //__visc__barrier(); - //} - - //for (unsigned stride = 32; stride >= 1; stride >>= 1) { - //if ((gid + stride < m*n) && (lx < stride)) - //if (G[gid + stride] > G[gid]) - //G[gid] = G[gid + stride]; - //} - - //if (lx == 0) - //__visc__atomic_max(maxG,G[gid]); - - //__visc__return(m); -//} - -void computeMaxGradientTB(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x) { - __visc__hint(visc::DEVICE); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGLeafNode = __visc__createNode1D(computeMaxGradientLeaf, block_x); - __visc__bindIn(CMGLeafNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGLeafNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGLeafNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGLeafNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGLeafNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGLeafNode, 5, 5, 0); // Bind n - - __visc__bindOut(CMGLeafNode, 0, 0, 0); // bind output m -} - -void WrapperComputeMaxGradient(float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - int m, int n, - int block_x, int grid_x) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(2, G, maxG, 1, maxG); - void* CMGTBNode = __visc__createNode1D(computeMaxGradientTB, grid_x); - __visc__bindIn(CMGTBNode, 0, 0, 0); // Bind G - __visc__bindIn(CMGTBNode, 1, 1, 0); // Bind bytesG - __visc__bindIn(CMGTBNode, 2, 2, 0); // Bind maxG - __visc__bindIn(CMGTBNode, 3, 3, 0); // Bind bytesMaxG - __visc__bindIn(CMGTBNode, 4, 4, 0); // Bind m - __visc__bindIn(CMGTBNode, 5, 5, 0); // Bind n - __visc__bindIn(CMGTBNode, 6, 6, 0); // Bind block_x - - __visc__bindOut(CMGTBNode, 0, 0, 0); // bind output m -} - -/* Reject the zero crossings where the gradient is below a threshold */ -/* - * S : input (computed zero crossings) - * m, n : dimensions - * G: gradient of (smoothed) image - * E : output (edges of the image) - * Need 2D grid, a thread per pixel - */ - -#define THETA 0.1 -void rejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::DEVICE); - __visc__attributes(3, S, G, maxG, 1, E); - - void* thisNode = __visc__getNode(); - int gx = __visc__getNodeInstanceID_x(thisNode); - int gy = __visc__getNodeInstanceID_y(thisNode); - - float mG = *maxG; - //float mG = 1.39203; - if ((gx < n) && (gy < m)) { - E[gy*n+gx] = ((S[gy*n+gx] > 0.0) && (G[gy*n+gx] > THETA*mG)) ? 1.0 : 0.0 ; - } - - __visc__return(m); -} - -void WrapperRejectZeroCrossings(float *S, size_t bytesS, - float *G, size_t bytesG, - float *maxG, size_t bytesMaxG, - float *E, size_t bytesE, - int m, int n) { - __visc__hint(visc::CPU_TARGET); - __visc__attributes(3, S, G, maxG, 1, E); - void* RZCNode = __visc__createNode2D(rejectZeroCrossings, m, n); - __visc__bindIn(RZCNode, 0, 0 , 0); // Bind S - __visc__bindIn(RZCNode, 1, 1 , 0); // Bind bytesS - __visc__bindIn(RZCNode, 2, 2 , 0); // Bind G - __visc__bindIn(RZCNode, 3, 3 , 0); // Bind bytesG - __visc__bindIn(RZCNode, 4, 4 , 0); // Bind maxG - __visc__bindIn(RZCNode, 5, 5 , 0); // Bind bytesMaxG - __visc__bindIn(RZCNode, 6, 6 , 0); // Bind E - __visc__bindIn(RZCNode, 7, 7 , 0); // Bind bytesE - __visc__bindIn(RZCNode, 8, 8 , 0); // Bind m - __visc__bindIn(RZCNode, 9, 9, 0); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 0); // bind output m -} - - - -// Pipelined Root node -void edgeDetection(float *I, size_t bytesI, // 0 - float *Is, size_t bytesIs, // 2 - float *L, size_t bytesL, // 4 - float *S, size_t bytesS, // 6 - float *G, size_t bytesG, // 8 - float *maxG, size_t bytesMaxG, // 10 - float *E, size_t bytesE, // 12 - float *Gs, size_t bytesGs, // 14 - float *B, size_t bytesB, // 16 - float *Sx, size_t bytesSx, // 18 - float *Sy, size_t bytesSy, // 20 - int m, // 22 - int n, // 23 - int block_x, // 24 - int grid_x // 25 - ) { - __visc__attributes(5, I, Gs, B, Sx, Sy, 6, Is, L, S, G, maxG, E); - __visc__hint(visc::CPU_TARGET); - void* GSNode = __visc__createNode(WrapperGaussianSmoothing); - void* LNode = __visc__createNode(WrapperlaplacianEstimate); - void* CZCNode = __visc__createNode(WrapperComputeZeroCrossings); - void* CGNode = __visc__createNode(WrapperComputeGradient); - void* CMGNode = __visc__createNode(WrapperComputeMaxGradient); - void* RZCNode = __visc__createNode(WrapperRejectZeroCrossings); - - // Gaussian Inputs - __visc__bindIn(GSNode, 0 , 0, 1); // Bind I - __visc__bindIn(GSNode, 1 , 1, 1); // Bind bytesI - __visc__bindIn(GSNode, 14, 2, 1); // Bind Gs - __visc__bindIn(GSNode, 15, 3, 1); // Bind bytesGs - __visc__bindIn(GSNode, 2 , 4, 1); // Bind Is - __visc__bindIn(GSNode, 3 , 5, 1); // Bind bytesIs - __visc__bindIn(GSNode, 22, 6, 1); // Bind m - __visc__bindIn(GSNode, 23, 7, 1); // Bind n - - // Laplacian Inputs - __visc__bindIn(LNode, 2 , 0, 1); // Bind Is - __visc__bindIn(LNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(LNode, 16, 2, 1); // Bind B - __visc__bindIn(LNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(LNode, 4 , 4, 1); // Bind L - __visc__bindIn(LNode, 5 , 5, 1); // Bind bytesL -// __visc__bindIn(LNode, 22, 6, 1); // Bind m - __visc__edge(GSNode, LNode, 0, 6, 1); // Get m - __visc__bindIn(LNode, 23, 7, 1); // Bind n - - // Compute ZC Inputs - __visc__bindIn(CZCNode, 4 , 0, 1); // Bind L - __visc__bindIn(CZCNode, 5 , 1, 1); // Bind bytesL - __visc__bindIn(CZCNode, 16, 2, 1); // Bind B - __visc__bindIn(CZCNode, 17, 3, 1); // Bind bytesB - __visc__bindIn(CZCNode, 6 , 4, 1); // Bind S - __visc__bindIn(CZCNode, 7 , 5, 1); // Bind bytesS - //__visc__bindIn(CZCNode, 22, 6, 1); // Bind m - __visc__edge(LNode, CZCNode, 0, 6, 1); // Get m - __visc__bindIn(CZCNode, 23, 7, 1); // Bind n - - // Gradient Inputs - __visc__bindIn(CGNode, 2 , 0, 1); // Bind Is - __visc__bindIn(CGNode, 3 , 1, 1); // Bind bytesIs - __visc__bindIn(CGNode, 18, 2, 1); // Bind Sx - __visc__bindIn(CGNode, 19, 3, 1); // Bind bytesSx - __visc__bindIn(CGNode, 20, 4, 1); // Bind Sy - __visc__bindIn(CGNode, 21, 5, 1); // Bind bytesSy - __visc__bindIn(CGNode, 8 , 6, 1); // Bind G - __visc__bindIn(CGNode, 9 , 7, 1); // Bind bytesG -// __visc__bindIn(CGNode, 22, 8, 1); // Bind m - __visc__edge(CZCNode, CGNode, 0, 8, 1); // Get m - __visc__bindIn(CGNode, 23, 9, 1); // Bind n - - // Max Gradient Inputs - __visc__bindIn(CMGNode, 8 , 0, 1); // Bind G - __visc__bindIn(CMGNode, 9 , 1, 1); // Bind bytesG - __visc__bindIn(CMGNode, 10, 2, 1); // Bind maxG - __visc__bindIn(CMGNode, 11, 3, 1); // Bind bytesMaxG -// __visc__bindIn(CMGNode, 22, 4, 1) // Bind m - __visc__edge(CGNode, CMGNode, 0, 4, 1); // Get m - __visc__bindIn(CMGNode, 23, 5, 1); // Bind n - __visc__bindIn(CMGNode, 24, 6, 1); // Bind block_x - __visc__bindIn(CMGNode, 25, 7, 1); // Bind grid_x - - // Reject ZC Inputs - __visc__bindIn(RZCNode, 6 , 0, 1); // Bind S - __visc__bindIn(RZCNode, 7 , 1, 1); // Bind bytesS - __visc__bindIn(RZCNode, 8 , 2, 1); // Bind G - __visc__bindIn(RZCNode, 9 , 3, 1); // Bind bytesG - __visc__bindIn(RZCNode, 10, 4, 1); // Bind maxG - __visc__bindIn(RZCNode, 11, 5, 1); // Bind bytesMaxG - __visc__bindIn(RZCNode, 12, 6, 1); // Bind E - __visc__bindIn(RZCNode, 13, 7, 1); // Bind bytesE - //__visc__bindIn(RZCNode, 22, 8, 1); // Bind m - __visc__edge(CMGNode, RZCNode, 0, 8, 1); - __visc__bindIn(RZCNode, 23, 9, 1); // Bind n - - __visc__bindOut(RZCNode, 0, 0, 1); // dummy bind output to get pipeline functionality -} - -} -#define NUM_RUNS 10 -#define DEPTH 3 -//#define NUM_FRAMES 20 -using namespace cv; - -void getNextFrame(VideoCapture& VC, Mat& F) { - VC >> F; - /// Convert the image to grayscale if image colored - if(F.channels() == 3) - cvtColor( F, F, CV_BGR2GRAY ); - - F.convertTo(F, CV_32F, 1.0/255.0); - -} - -int main (int argc, char *argv[]) { - - struct pb_Parameters *params; - struct pb_TimerSet timers; - - size_t I_sz; - int matIrow, matIcol; - int block_x, grid_x; - std::string input_window = "Input Frame"; - std::string output_window = "Edge Map"; - - std::cout << "Using OpenCV" << CV_VERSION << "\n"; - - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); - if(!cap.isOpened()) { - std::cout << "Could not open video file" << "\n"; - return -1; - } - - int NUM_FRAMES = cap.get(CV_CAP_PROP_FRAME_COUNT); - std::cout << "Number of frames = " << NUM_FRAMES << "\n"; - namedWindow(input_window, CV_WINDOW_AUTOSIZE); - namedWindow(output_window, CV_WINDOW_AUTOSIZE); - - Mat src, Is, L, S, G, E; - - getNextFrame(cap, src); - - std::cout << "Image dimension = " << src.size() << "\n"; - if(src.isContinuous()) { - std::cout << "Assigning image to float vector\n"; - matIrow = src.size[0]; - matIcol = src.size[1]; - std::cout << "Vector size = " << matIrow * matIcol << "\n"; - } - else { - std::cout << "Expecting contiguous storage of image in memory!\n"; - exit(-1); - } - - Is = Mat(src.size[0], src.size[1], CV_32F); - L = Mat(src.size[0], src.size[1], CV_32F); - S = Mat(src.size[0], src.size[1], CV_32F); - G = Mat(src.size[0], src.size[1], CV_32F); - E = Mat(src.size[0], src.size[1], CV_32F); - - // All these matrices need to have their data array contiguous in memory - assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - - pb_InitializeTimerSet(&timers); - __visc__init(); - - pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - // copy A to device memory - I_sz = matIrow*matIcol*sizeof(float); - - size_t bytesMaxG = sizeof(float); - float* maxG = (float*)malloc(bytesMaxG); - - float B[] = { 1, 1, 1, - 1, 1, 1, - 1, 1, 1 }; - size_t bytesB = 9*sizeof(float); - //Sx = [-1 0 1 ; -2 0 2 ; -1 0 1 ] - //Sy = [-1 -2 -1 ; 0 0 0 ; 1 2 1 ] - float Sx[] = { -1, 0, 1, - -2, 0, 2, - -1, 0, 1 }; - size_t bytesSx = 9*sizeof(float); - float Sy[] = { -1, -2, -1, - 0, 0, 0, - 1, 2, 1 }; - size_t bytesSy = 9*sizeof(float); - - float Gs [] = { - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.002291, 0.023226, 0.092651, 0.146768, 0.092651, 0.023226, 0.002291, - 0.001446, 0.014662, 0.058488, 0.092651, 0.058488, 0.014662, 0.001446, - 0.000363, 0.003676, 0.014662, 0.023226, 0.014662, 0.003676, 0.000363, - 0.000036, 0.000363, 0.001446, 0.002291, 0.001446, 0.000363, 0.000036 }; - size_t bytesGs = 7*7*sizeof(float); - - block_x = 256; - // grid_x should be equal to the number of SMs on GPU. FTX 680 has 8 SMs - grid_x = 1; - - // Copy A and B^T into device memory - pb_SwitchToTimer( &timers, pb_TimerID_COMPUTE ); - - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); - struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); - - imshow(input_window, src); - imshow(output_window, Is); - waitKey(0); - packData(args, (float*)src.data, I_sz, - (float*)Is.data, I_sz, - (float*)L.data, I_sz, - (float*)S.data, I_sz, - (float*)G.data, I_sz, - maxG, bytesMaxG, - (float*)E.data, I_sz, - Gs, bytesGs, - B, bytesB, - Sx, bytesSx, - Sy, bytesSy, - matIrow, matIcol, - block_x, grid_x); - - // Check if the total elements is a multiple of block size - assert(matIrow*matIcol % block_x == 0); - - imshow(input_window, src); - imshow(output_window, E); - waitKey(0); - for(unsigned j=0; j<NUM_RUNS; j++) { - std::cout << "Run: " << j << "\n"; - void* DFG = __visc__launch(1, edgeDetection, (void*)args); - - cap = VideoCapture(params->inpFiles[0]); - getNextFrame(cap, src); - //packData(args, A.data, BlockSize, &matB[i], BlockSize, &matC[i], BlockSize, BlockElements); - if(NUM_FRAMES >=2) { - //__visc__push(DFG, args); - //__visc__push(DFG, args); - for(int i=0; i<NUM_FRAMES; i++) { - std::cout << "Frame " << i << "\n"; - args->I = (float*) src.data; - - *maxG = 0.0; - llvm_visc_track_mem(src.data, I_sz); - llvm_visc_track_mem(Is.data, I_sz); - llvm_visc_track_mem(L.data, I_sz); - llvm_visc_track_mem(S.data, I_sz); - llvm_visc_track_mem(G.data, I_sz); - llvm_visc_track_mem(maxG, bytesMaxG); - llvm_visc_track_mem(E.data, I_sz); - llvm_visc_track_mem(Gs, bytesGs); - llvm_visc_track_mem(B, bytesB); - llvm_visc_track_mem(Sx, bytesSx); - llvm_visc_track_mem(Sy, bytesSy); - - __visc__push(DFG, args); - __visc__pop(DFG); - - //llvm_visc_request_mem(E.data, I_sz); - //std::cout << "Show E" << "\n"; - //imshow(window_name, E); - //waitKey(0); - //llvm_visc_request_mem(src.data, I_sz); - //llvm_visc_request_mem(Is.data, I_sz); - //llvm_visc_request_mem(L.data, I_sz); - //llvm_visc_request_mem(S.data, I_sz); - //llvm_visc_request_mem(G.data, I_sz); - llvm_visc_request_mem(maxG, bytesMaxG); - llvm_visc_request_mem(E.data, I_sz); - std::cout << "Max G = " << *maxG << "\n"; - - imshow(output_window, E); - imshow(input_window, src); - waitKey(1); - getNextFrame(cap, src); - - llvm_visc_untrack_mem(src.data); - llvm_visc_untrack_mem(Is.data); - llvm_visc_untrack_mem(L.data); - llvm_visc_untrack_mem(S.data); - llvm_visc_untrack_mem(G.data); - llvm_visc_untrack_mem(maxG); - llvm_visc_untrack_mem(E.data); - llvm_visc_untrack_mem(Gs); - llvm_visc_untrack_mem(B); - llvm_visc_untrack_mem(Sx); - llvm_visc_untrack_mem(Sy); - - - - } - //__visc__pop(DFG); - //__visc__pop(DFG); - } - else { - __visc__push(DFG, args); - __visc__pop(DFG); - } - - __visc__wait(DFG); - } - - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - - - pb_PrintTimerSet(&timers); - __visc__cleanup(); - - //if (params->outFile) { - - /* Write C to file */ - //pb_SwitchToTimer(&timers, pb_TimerID_IO); - //writeColMajorMatrixFile(params->outFile, - //matIrow, matIcol, matE); - //} - - std::cout << "Show Is" << "\n"; - Mat output(src.size[0], src.size[1], CV_32F); - imshow(output_window, Is); - waitKey(0); - - std::cout << "Show G" << "\n"; - imshow(output_window, L); - waitKey(0); - - std::cout << "Show L" << "\n"; - imshow(output_window, S); - waitKey(0); - - std::cout << "Show S" << "\n"; - imshow(output_window, G); - waitKey(0); - - std::cout << "Show E" << "\n"; - imshow(output_window, E); - waitKey(0); - - double GPUtime = pb_GetElapsedTime(&(timers.timers[pb_TimerID_KERNEL])); - std::cout<< "GFLOPs = " << 2.* matIrow * matIcol * matIcol/GPUtime/1e9 << std::endl; - pb_FreeParameters(params); - - return 0; -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc_parallel/io.cc b/hpvm/test/parboil/benchmarks/pipeline/src/visc_parallel/io.cc deleted file mode 100644 index 045983722390eaa48deff0df0944dff481ee148a..0000000000000000000000000000000000000000 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc_parallel/io.cc +++ /dev/null @@ -1,91 +0,0 @@ -/*************************************************************************** - *cr - *cr (C) Copyright 2010 The Board of Trustees of the - *cr University of Illinois - *cr All Rights Reserved - *cr - ***************************************************************************/ - -/* I/O routines for reading and writing matrices in column-major - * layout - */ - -#include<fstream> -#include<iostream> -#include<vector> - -char* readFile(const char* fileName) -{ - std::fstream f(fileName,std::fstream::in); - if(!f.good()) - { - std::cerr<<"Error Reading File!!"<<std::endl; - return NULL; - } - - f.seekg(0,std::ios::end); - int length = f.tellg(); - f.seekg(0,std::ios::beg); - - char* buffer; - - if(length>0) - { - buffer = new char[length]; - f.read(buffer,length); - buffer[length-1]=0; - } - else - { - buffer = new char; - buffer[0] = 0; - } - - f.close(); - - return buffer; -} - -bool readColMajorMatrixFile(const char *fn, int &nr_row, int &nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << std::endl; - std::fstream f(fn, std::fstream::in); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f >> nr_row; - f >> nr_col; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - while (f.good() ) { - f >> data; - v.push_back(data); - } - v.pop_back(); // remove the duplicated last element - return true; - -} - -bool writeColMajorMatrixFile(const char *fn, int nr_row, int nr_col, std::vector<float>&v) -{ - std::cerr << "Opening file:"<< fn << " for write." << std::endl; - std::fstream f(fn, std::fstream::out); - if ( !f.good() ) { - return false; - } - - // Read # of rows and cols - f << nr_row << " "<<nr_col<<" "; - - float data; - std::cerr << "Matrix dimension: "<<nr_row<<"x"<<nr_col<<std::endl; - for (int i = 0; i < v.size(); ++i) { - f << v[i] << ' '; - } - f << "\n"; - return true; - -} diff --git a/hpvm/test/parboil/benchmarks/pipeline/DESCRIPTION b/hpvm/test/pipeline/DESCRIPTION similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/DESCRIPTION rename to hpvm/test/pipeline/DESCRIPTION diff --git a/hpvm/test/pipeline/Makefile b/hpvm/test/pipeline/Makefile new file mode 100644 index 0000000000000000000000000000000000000000..4a72673a43712d9532025be073aad0b7be3bd970 --- /dev/null +++ b/hpvm/test/pipeline/Makefile @@ -0,0 +1,112 @@ +# This Makefile compiles the HPVM-CAVA pilot project. +# It builds HPVM-related dependencies, then the native camera pipeline ISP code. +# +# Paths to some dependencies (e.g., HPVM, LLVM) must exist in Makefile.config, +# which can be copied from Makefile.config.example for a start. + +CONFIG_FILE := Makefile.config + +ifeq ($(wildcard $(CONFIG_FILE)),) + $(error $(CONFIG_FILE) not found. See $(CONFIG_FILE).example) +endif +include $(CONFIG_FILE) + +# Compiler Flags + +LFLAGS += -lm -lrt + +# Build dirs +SRC_DIR = src/ +BUILD_DIR = build/$(TARGET) +CURRENT_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) + +EXE = pipeline-$(TARGET) + +## BEGIN HPVM MAKEFILE +SRCDIR_OBJS= io.ll +OBJS_SRC=src/io.cc +VISC_OBJS=main.visc.ll +APP = $(EXE) +APP_CFLAGS+=-ffast-math -O3 -fno-lax-vector-conversions -fno-vectorize -fno-slp-vectorize -I$(SRC_DIR) +APP_CXXFLAGS+=-ffast-math -O3 -fno-lax-vector-conversions -fno-vectorize -fno-slp-vectorize -I$(SRC_DIR) +APP_LDFLAGS=`pkg-config opencv --libs` + +CFLAGS = $(APP_CFLAGS) $(PLATFORM_CFLAGS) +OBJS_CFLAGS = $(APP_CFLAGS) $(PLATFORM_CFLAGS) +CXXFLAGS = $(APP_CXXFLAGS) $(PLATFORM_CXXFLAGS) +LDFLAGS= $(APP_LDFLAGS) $(PLATFORM_LDFLAGS) + +VISC_RT_PATH = $(LLVM_SRC_ROOT)/tools/hpvm/projects/visc-rt +VISC_RT_LIB = $(VISC_RT_PATH)/visc-rt.ll + +TESTGEN_OPTFLAGS = -load LLVMGenVISC.so -genvisc -globaldce + +ifeq ($(TARGET),seq) + DEVICE = CPU_TARGET + VISC_OPTFLAGS = -load LLVMBuildDFG.so -load LLVMDFG2LLVM_X86.so -load LLVMClearDFG.so -dfg2llvm-x86 -clearDFG + VISC_OPTFLAGS += -visc-timers-x86 +else + DEVICE = GPU_TARGET + VISC_OPTFLAGS = -load LLVMBuildDFG.so -load LLVMLocalMem.so -load LLVMDFG2LLVM_NVPTX.so -load LLVMDFG2LLVM_X86.so -load LLVMClearDFG.so -localmem -dfg2llvm-nvptx -dfg2llvm-x86 -clearDFG + VISC_OPTFLAGS += -visc-timers-x86 -visc-timers-ptx +endif + TESTGEN_OPTFLAGS += -visc-timers-gen + +CFLAGS += -DDEVICE=$(DEVICE) +CXXFLAGS += -DDEVICE=$(DEVICE) + +# Add BUILDDIR as a prefix to each element of $1 +INBUILDDIR=$(addprefix $(BUILD_DIR)/,$(1)) + +.PRECIOUS: $(BUILD_DIR)/%.ll + +OBJS = $(call INBUILDDIR,$(SRCDIR_OBJS)) +TEST_OBJS = $(call INBUILDDIR,$(VISC_OBJS)) +KERNEL = $(TEST_OBJS).kernels.ll + +ifeq ($(TARGET),seq) +else + KERNEL_LINKED = $(BUILD_DIR)/$(APP).kernels.linked.ll + KERNEL_OCL = $(TEST_OBJS).kernels.cl +endif + +HOST_LINKED = $(BUILD_DIR)/$(APP).linked.ll +HOST = $(BUILD_DIR)/$(APP).host.ll + +ifeq ($(OPENCL_PATH),) +FAILSAFE=no_opencl +else +FAILSAFE= +endif + +# Targets +default: $(FAILSAFE) $(BUILD_DIR) $(KERNEL_OCL) $(EXE) + +$(KERNEL_OCL) : $(KERNEL) + $(OCLBE) -debug $< -o $@ + +$(EXE) : $(HOST_LINKED) + $(CXX) -O3 $(LDFLAGS) $< -o $@ + +$(HOST_LINKED) : $(HOST) $(OBJS) $(VISC_RT_LIB) + $(LLVM_LINK) $^ -S -o $@ + +$(VISC_RT_LIB) : $(VISC_RT_PATH)/visc-rt.cpp + make -C $(LLVM_LIB_PATH) + +$(HOST) $(KERNEL): $(BUILD_DIR)/$(VISC_OBJS) + $(OPT) -debug $(VISC_OPTFLAGS) -S $< -o $(HOST) + +$(BUILD_DIR): + mkdir -p $(BUILD_DIR) + +$(BUILD_DIR)/%.ll : $(SRC_DIR)/%.cc + $(CC) $(OBJS_CFLAGS) -emit-llvm -S -o $@ $< + +$(BUILD_DIR)/main.ll : $(SRC_DIR)/main.cc + $(CC) $(CXXFLAGS) -emit-llvm -S -o $@ $< + +$(BUILD_DIR)/main.visc.ll : $(BUILD_DIR)/main.ll + $(OPT) -debug-only=genvisc $(TESTGEN_OPTFLAGS) $< -S -o $@ + +## END HPVM MAKEFILE diff --git a/hpvm/test/pipeline/build/seq/main.ll b/hpvm/test/pipeline/build/seq/main.ll new file mode 100644 index 0000000000000000000000000000000000000000..5ec1397323a0317baa4b676a55b42505c8431ca8 --- /dev/null +++ b/hpvm/test/pipeline/build/seq/main.ll @@ -0,0 +1,5576 @@ +; ModuleID = 'src//main.cc' +source_filename = "src//main.cc" +target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" +target triple = "x86_64-unknown-linux-gnu" + +%"class.std::ios_base::Init" = type { i8 } +%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_Alloc_hider", i64, %union.anon } +%"struct.std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_Alloc_hider" = type { i8* } +%union.anon = type { i64, [8 x i8] } +%struct._IO_FILE = type { i32, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, %struct._IO_marker*, %struct._IO_FILE*, i32, i32, i64, i16, i8, [1 x i8], i8*, i64, i8*, i8*, i8*, i8*, i64, i32, [20 x i8] } +%struct._IO_marker = type { %struct._IO_marker*, %struct._IO_FILE*, i32 } +%"class.std::basic_ostream" = type { i32 (...)**, %"class.std::basic_ios" } +%"class.std::basic_ios" = type { %"class.std::ios_base", %"class.std::basic_ostream"*, i8, i8, %"class.std::basic_streambuf"*, %"class.std::ctype"*, %"class.std::num_put"*, %"class.std::num_get"* } +%"class.std::ios_base" = type { i32 (...)**, i64, i64, i32, i32, i32, %"struct.std::ios_base::_Callback_list"*, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, %"struct.std::ios_base::_Words"*, %"class.std::locale" } +%"struct.std::ios_base::_Callback_list" = type { %"struct.std::ios_base::_Callback_list"*, void (i32, %"class.std::ios_base"*, i32)*, i32, i32 } +%"struct.std::ios_base::_Words" = type { i8*, i64 } +%"class.std::locale" = type { %"class.std::locale::_Impl"* } +%"class.std::locale::_Impl" = type { i32, %"class.std::locale::facet"**, i64, %"class.std::locale::facet"**, i8** } +%"class.std::locale::facet" = type <{ i32 (...)**, i32, [4 x i8] }> +%"class.std::basic_streambuf" = type { i32 (...)**, i8*, i8*, i8*, i8*, i8*, i8*, %"class.std::locale" } +%"class.std::ctype" = type <{ %"class.std::locale::facet.base", [4 x i8], %struct.__locale_struct*, i8, [7 x i8], i32*, i32*, i16*, i8, [256 x i8], [256 x i8], i8, [6 x i8] }> +%"class.std::locale::facet.base" = type <{ i32 (...)**, i32 }> +%struct.__locale_struct = type { [13 x %struct.__locale_data*], i16*, i32*, i32*, [13 x i8*] } +%struct.__locale_data = type opaque +%"class.std::num_put" = type { %"class.std::locale::facet.base", [4 x i8] } +%"class.std::num_get" = type { %"class.std::locale::facet.base", [4 x i8] } +%struct.InStruct = type { float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, i64, i64, i64, i64 } +%"class.cv::VideoCapture" = type { i32 (...)**, %"class.cv::Ptr" } +%"class.cv::Ptr" = type { %struct.CvCapture*, i32* } +%struct.CvCapture = type opaque +%"class.cv::Mat" = type { i32, i32, i32, i32, i8*, i32*, i8*, i8*, i8*, %"class.cv::MatAllocator"*, %"struct.cv::Mat::MSize", %"struct.cv::Mat::MStep" } +%"class.cv::MatAllocator" = type { i32 (...)** } +%"struct.cv::Mat::MSize" = type { i32* } +%"struct.cv::Mat::MStep" = type { i64*, [2 x i64] } +%"class.cv::_InputArray" = type { i32 (...)**, i32, i8*, %"class.cv::Size_" } +%"class.cv::Size_" = type { i32, i32 } +%"class.cv::_OutputArray" = type { %"class.cv::_InputArray" } + +$__clang_call_terminate = comdat any + +@_ZStL8__ioinit = internal global %"class.std::ios_base::Init" zeroinitializer, align 1 +@__dso_handle = external hidden global i8 +@_Z12input_windowB5cxx11 = dso_local global %"class.std::__cxx11::basic_string" zeroinitializer, align 8 +@.str = private unnamed_addr constant [27 x i8] c"GPU Pipeline - Input Video\00", align 1 +@_Z13output_windowB5cxx11 = dso_local global %"class.std::__cxx11::basic_string" zeroinitializer, align 8 +@.str.3 = private unnamed_addr constant [28 x i8] c"GPU Pipeline - Edge Mapping\00", align 1 +@stderr = external dso_local local_unnamed_addr global %struct._IO_FILE*, align 8 +@.str.4 = private unnamed_addr constant [32 x i8] c"Expecting input image filename\0A\00", align 1 +@.str.5 = private unnamed_addr constant [24 x i8] c"Running pipeline on %s\0A\00", align 1 +@_ZSt4cout = external dso_local global %"class.std::basic_ostream", align 8 +@.str.6 = private unnamed_addr constant [13 x i8] c"Using OpenCV\00", align 1 +@.str.7 = private unnamed_addr constant [8 x i8] c"2.4.9.1\00", align 1 +@.str.8 = private unnamed_addr constant [2 x i8] c"\0A\00", align 1 +@.str.9 = private unnamed_addr constant [21 x i8] c"Reading video file: \00", align 1 +@.str.10 = private unnamed_addr constant [26 x i8] c"Could not open video file\00", align 1 +@.str.11 = private unnamed_addr constant [20 x i8] c"Number of frames = \00", align 1 +@.str.12 = private unnamed_addr constant [19 x i8] c"Image dimension = \00", align 1 +@.str.13 = private unnamed_addr constant [50 x i8] c"Expecting contiguous storage of image in memory!\0A\00", align 1 +@.str.14 = private unnamed_addr constant [120 x i8] c"src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()\00", align 1 +@.str.15 = private unnamed_addr constant [13 x i8] c"src//main.cc\00", align 1 +@__PRETTY_FUNCTION__.main = private unnamed_addr constant [23 x i8] c"int main(int, char **)\00", align 1 +@__const.main.B = private unnamed_addr constant [9 x float] [float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00], align 16 +@__const.main.Gs = private unnamed_addr constant [49 x float] [float 0x3F02DFD6A0000000, float 0x3F37CA2120000000, float 0x3F57B0F6A0000000, float 0x3F62C49340000000, float 0x3F57B0F6A0000000, float 0x3F37CA2120000000, float 0x3F02DFD6A0000000, float 0x3F37CA2120000000, float 0x3F6E1D2180000000, float 0x3F8E071C60000000, float 0x3F97C88E80000000, float 0x3F8E071C60000000, float 0x3F6E1D2180000000, float 0x3F37CA2120000000, float 0x3F57B0F6A0000000, float 0x3F8E071C60000000, float 0x3FADF223A0000000, float 0x3FB7B7F9E0000000, float 0x3FADF223A0000000, float 0x3F8E071C60000000, float 0x3F57B0F6A0000000, float 0x3F62C49340000000, float 0x3F97C88E80000000, float 0x3FB7B7F9E0000000, float 0x3FC2C94B40000000, float 0x3FB7B7F9E0000000, float 0x3F97C88E80000000, float 0x3F62C49340000000, float 0x3F57B0F6A0000000, float 0x3F8E071C60000000, float 0x3FADF223A0000000, float 0x3FB7B7F9E0000000, float 0x3FADF223A0000000, float 0x3F8E071C60000000, float 0x3F57B0F6A0000000, float 0x3F37CA2120000000, float 0x3F6E1D2180000000, float 0x3F8E071C60000000, float 0x3F97C88E80000000, float 0x3F8E071C60000000, float 0x3F6E1D2180000000, float 0x3F37CA2120000000, float 0x3F02DFD6A0000000, float 0x3F37CA2120000000, float 0x3F57B0F6A0000000, float 0x3F62C49340000000, float 0x3F57B0F6A0000000, float 0x3F37CA2120000000, float 0x3F02DFD6A0000000], align 16 +@.str.16 = private unnamed_addr constant [39 x i8] c"src.size[0]*src.size[1] % block_x == 0\00", align 1 +@.str.17 = private unnamed_addr constant [6 x i8] c"Run: \00", align 1 +@.str.18 = private unnamed_addr constant [7 x i8] c"Frame \00", align 1 +@.str.19 = private unnamed_addr constant [16 x i8] c"Returned size: \00", align 1 +@.str.20 = private unnamed_addr constant [11 x i8] c" expected \00", align 1 +@.str.21 = private unnamed_addr constant [42 x i8] c"basic_string::_M_construct null not valid\00", align 1 +@.str.22 = private unnamed_addr constant [2 x i8] c"[\00", align 1 +@.str.23 = private unnamed_addr constant [4 x i8] c" x \00", align 1 +@.str.24 = private unnamed_addr constant [2 x i8] c"]\00", align 1 +@llvm.global_ctors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @_GLOBAL__sub_I_main.cc, i8* null }] + +declare dso_local void @_ZNSt8ios_base4InitC1Ev(%"class.std::ios_base::Init"*) unnamed_addr #0 + +; Function Attrs: nounwind +declare dso_local void @_ZNSt8ios_base4InitD1Ev(%"class.std::ios_base::Init"*) unnamed_addr #1 + +; Function Attrs: nofree nounwind +declare dso_local i32 @__cxa_atexit(void (i8*)*, i8*, i8*) local_unnamed_addr #2 + +; Function Attrs: argmemonly nounwind +declare void @llvm.lifetime.start.p0i8(i64 immarg, i8* nocapture) #3 + +declare dso_local i32 @__gxx_personality_v0(...) + +; Function Attrs: argmemonly nounwind +declare void @llvm.lifetime.end.p0i8(i64 immarg, i8* nocapture) #3 + +; Function Attrs: nounwind uwtable +declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(%"class.std::__cxx11::basic_string"*) unnamed_addr #4 align 2 + +; Function Attrs: nofree norecurse nounwind uwtable writeonly +define dso_local void @packData(%struct.InStruct* %args, float* %I, i64 %bytesI, float* %Is, i64 %bytesIs, float* %L, i64 %bytesL, float* %S, i64 %bytesS, float* %G, i64 %bytesG, float* %maxG, i64 %bytesMaxG, float* %E, i64 %bytesE, float* %Gs, i64 %bytesGs, float* %B, i64 %bytesB, float* %Sx, i64 %bytesSx, float* %Sy, i64 %bytesSy, i64 %m, i64 %n, i64 %block_x, i64 %grid_x) local_unnamed_addr #5 { +entry: + %I1 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 0 + store float* %I, float** %I1, align 1, !tbaa !2 + %bytesI2 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 1 + store i64 %bytesI, i64* %bytesI2, align 1, !tbaa !8 + %Is3 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 2 + store float* %Is, float** %Is3, align 1, !tbaa !9 + %bytesIs4 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 3 + store i64 %bytesIs, i64* %bytesIs4, align 1, !tbaa !10 + %L5 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 4 + store float* %L, float** %L5, align 1, !tbaa !11 + %bytesL6 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 5 + store i64 %bytesL, i64* %bytesL6, align 1, !tbaa !12 + %S7 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 6 + store float* %S, float** %S7, align 1, !tbaa !13 + %bytesS8 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 7 + store i64 %bytesS, i64* %bytesS8, align 1, !tbaa !14 + %G9 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 8 + store float* %G, float** %G9, align 1, !tbaa !15 + %bytesG10 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 9 + store i64 %bytesG, i64* %bytesG10, align 1, !tbaa !16 + %maxG11 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 10 + store float* %maxG, float** %maxG11, align 1, !tbaa !17 + %bytesMaxG12 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 11 + store i64 %bytesMaxG, i64* %bytesMaxG12, align 1, !tbaa !18 + %E13 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 12 + store float* %E, float** %E13, align 1, !tbaa !19 + %bytesE14 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 13 + store i64 %bytesE, i64* %bytesE14, align 1, !tbaa !20 + %Gs15 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 14 + store float* %Gs, float** %Gs15, align 1, !tbaa !21 + %bytesGs16 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 15 + store i64 %bytesGs, i64* %bytesGs16, align 1, !tbaa !22 + %B17 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 16 + store float* %B, float** %B17, align 1, !tbaa !23 + %bytesB18 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 17 + store i64 %bytesB, i64* %bytesB18, align 1, !tbaa !24 + %Sx19 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 18 + store float* %Sx, float** %Sx19, align 1, !tbaa !25 + %bytesSx20 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 19 + store i64 %bytesSx, i64* %bytesSx20, align 1, !tbaa !26 + %Sy21 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 20 + store float* %Sy, float** %Sy21, align 1, !tbaa !27 + %bytesSy22 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 21 + store i64 %bytesSy, i64* %bytesSy22, align 1, !tbaa !28 + %m23 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 22 + store i64 %m, i64* %m23, align 1, !tbaa !29 + %n24 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 23 + store i64 %n, i64* %n24, align 1, !tbaa !30 + %block_x25 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 24 + store i64 %block_x, i64* %block_x25, align 1, !tbaa !31 + %grid_x26 = getelementptr inbounds %struct.InStruct, %struct.InStruct* %args, i64 0, i32 25 + store i64 %grid_x, i64* %grid_x26, align 1, !tbaa !32 + ret void +} + +; Function Attrs: uwtable +define dso_local void @gaussianSmoothing(float* %I, i64 %bytesI, float* %Gs, i64 %bytesGs, float* %Is, i64 %bytesIs, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 2, float* %I, float* %Gs, i32 1, float* %Is) + %call = tail call i8* @__visc__getNode() + %call1 = tail call i64 @__visc__getNodeInstanceID_x(i8* %call) + %call2 = tail call i64 @__visc__getNodeInstanceID_y(i8* %call) + %mul = mul nsw i64 %call2, %n + %add = add nsw i64 %mul, %call1 + %cmp = icmp slt i64 %call1, %n + %cmp3 = icmp slt i64 %call2, %m + %or.cond = and i1 %cmp, %cmp3 + br i1 %or.cond, label %for.cond.preheader, label %if.end79 + +for.cond.preheader: ; preds = %entry + %sub = add nsw i64 %m, -1 + %mul28 = mul nsw i64 %sub, %n + %add29 = add nsw i64 %call1, %mul28 + %sub58 = sub i64 %n, %call1 + %0 = trunc i64 %m to i32 + %1 = add i32 %0, -1 + %2 = trunc i64 %n to i32 + %3 = mul i32 %1, %2 + %4 = trunc i64 %call2 to i32 + %5 = add i32 %4, -3 + %6 = mul i32 %5, %2 + %.pn = trunc i64 %add29 to i32 + %add43 = add nsw i64 %call1, -3 + %cmp44 = icmp slt i64 %add43, 0 + %loadOffset.0 = add i32 %.pn, -3 + %cmp55 = icmp slt i64 %add43, %n + %7 = trunc i64 %sub58 to i32 + %8 = add i32 %7, %.pn + %conv63 = add i32 %8, -1 + %add43.1 = add nsw i64 %call1, -2 + %cmp44.1 = icmp slt i64 %add43.1, 0 + %loadOffset.0.1 = add i32 %.pn, -2 + %cmp55.1 = icmp slt i64 %add43.1, %n + %9 = trunc i64 %sub58 to i32 + %10 = add i32 %9, %.pn + %conv63.1 = add i32 %10, -1 + %cmp44.2 = icmp slt i64 %call1, 1 + %loadOffset.0.2 = add i32 %.pn, -1 + %cmp44.3 = icmp slt i64 %call1, 0 + %add43.4 = add nsw i64 %call1, 1 + %cmp44.4 = icmp slt i64 %add43.4, 0 + %loadOffset.0.4 = add i32 %.pn, 1 + %cmp55.4 = icmp slt i64 %add43.4, %n + %11 = trunc i64 %sub58 to i32 + %12 = add i32 %11, %.pn + %conv63.4 = add i32 %12, -1 + %add43.5 = add nsw i64 %call1, 2 + %cmp44.5 = icmp slt i64 %add43.5, 0 + %loadOffset.0.5 = add i32 %.pn, 2 + %cmp55.5 = icmp slt i64 %add43.5, %n + %13 = trunc i64 %sub58 to i32 + %14 = add i32 %13, %.pn + %conv63.5 = add i32 %14, -1 + %add43.6 = add nsw i64 %call1, 3 + %cmp44.6 = icmp slt i64 %add43.6, 0 + %loadOffset.0.6 = add i32 %.pn, 3 + %cmp55.6 = icmp slt i64 %add43.6, %n + %15 = trunc i64 %sub58 to i32 + %16 = add i32 %15, %.pn + %conv63.6 = add i32 %16, -1 + %add43.us146 = add nsw i64 %call1, -3 + %cmp44.us147 = icmp slt i64 %add43.us146, 0 + %cmp55.us149 = icmp slt i64 %add43.us146, %n + %17 = trunc i64 %sub58 to i32 + %add43.us146.1 = add nsw i64 %call1, -2 + %cmp44.us147.1 = icmp slt i64 %add43.us146.1, 0 + %cmp55.us149.1 = icmp slt i64 %add43.us146.1, %n + %18 = trunc i64 %sub58 to i32 + %cmp44.us147.2 = icmp slt i64 %call1, 1 + %cmp44.us147.3 = icmp slt i64 %call1, 0 + %add43.us146.4 = add nsw i64 %call1, 1 + %cmp44.us147.4 = icmp slt i64 %add43.us146.4, 0 + %cmp55.us149.4 = icmp slt i64 %add43.us146.4, %n + %19 = trunc i64 %sub58 to i32 + %add43.us146.5 = add nsw i64 %call1, 2 + %cmp44.us147.5 = icmp slt i64 %add43.us146.5, 0 + %cmp55.us149.5 = icmp slt i64 %add43.us146.5, %n + %20 = trunc i64 %sub58 to i32 + %add43.us146.6 = add nsw i64 %call1, 3 + %cmp44.us147.6 = icmp slt i64 %add43.us146.6, 0 + %cmp55.us149.6 = icmp slt i64 %add43.us146.6, %n + %21 = trunc i64 %sub58 to i32 + %add43.us = add nsw i64 %call1, -3 + %cmp44.us = icmp slt i64 %add43.us, 0 + %loadOffset.0.us = add i64 %call1, 4294967293 + %cmp55.us = icmp slt i64 %add43.us, %n + %conv63.us = add i64 %n, 4294967295 + %add43.us.1 = add nsw i64 %call1, -2 + %cmp44.us.1 = icmp slt i64 %add43.us.1, 0 + %loadOffset.0.us.1 = add i64 %call1, 4294967294 + %cmp55.us.1 = icmp slt i64 %add43.us.1, %n + %conv63.us.1 = add i64 %n, 4294967295 + %cmp44.us.2 = icmp slt i64 %call1, 1 + %add43.us.4 = add nsw i64 %call1, 1 + %cmp44.us.4 = icmp slt i64 %add43.us.4, 0 + %loadOffset.0.us.4 = add nsw i64 %call1, 1 + %cmp55.us.4 = icmp slt i64 %add43.us.4, %n + %conv63.us.4 = add i64 %n, 4294967295 + %add43.us.5 = add nsw i64 %call1, 2 + %cmp44.us.5 = icmp slt i64 %add43.us.5, 0 + %loadOffset.0.us.5 = add nsw i64 %call1, 2 + %cmp55.us.5 = icmp slt i64 %add43.us.5, %n + %conv63.us.5 = add i64 %n, 4294967295 + %add43.us.6 = add nsw i64 %call1, 3 + %cmp44.us.6 = icmp slt i64 %add43.us.6, 0 + %loadOffset.0.us.6 = add nsw i64 %call1, 3 + %cmp55.us.6 = icmp slt i64 %add43.us.6, %n + %conv63.us.6 = add i64 %n, 4294967295 + %spec.select190 = select i1 %cmp55, i32 %loadOffset.0, i32 %conv63 + %loadOffset.1 = select i1 %cmp44, i32 %3, i32 %spec.select190 + %idxprom = sext i32 %loadOffset.1 to i64 + %arrayidx = getelementptr inbounds float, float* %I, i64 %idxprom + %spec.select191 = select i1 %cmp55.1, i32 %loadOffset.0.1, i32 %conv63.1 + %loadOffset.1.1 = select i1 %cmp44.1, i32 %3, i32 %spec.select191 + %idxprom.1 = sext i32 %loadOffset.1.1 to i64 + %arrayidx.1 = getelementptr inbounds float, float* %I, i64 %idxprom.1 + %loadOffset.1.2 = select i1 %cmp44.2, i32 %3, i32 %loadOffset.0.2 + %idxprom.2 = sext i32 %loadOffset.1.2 to i64 + %arrayidx.2 = getelementptr inbounds float, float* %I, i64 %idxprom.2 + %spec.select193 = select i1 %cmp44.3, i32 %3, i32 %.pn + %idxprom.3 = sext i32 %spec.select193 to i64 + %arrayidx.3 = getelementptr inbounds float, float* %I, i64 %idxprom.3 + %spec.select194 = select i1 %cmp55.4, i32 %loadOffset.0.4, i32 %conv63.4 + %loadOffset.1.4 = select i1 %cmp44.4, i32 %3, i32 %spec.select194 + %idxprom.4 = sext i32 %loadOffset.1.4 to i64 + %arrayidx.4 = getelementptr inbounds float, float* %I, i64 %idxprom.4 + %spec.select195 = select i1 %cmp55.5, i32 %loadOffset.0.5, i32 %conv63.5 + %loadOffset.1.5 = select i1 %cmp44.5, i32 %3, i32 %spec.select195 + %idxprom.5 = sext i32 %loadOffset.1.5 to i64 + %arrayidx.5 = getelementptr inbounds float, float* %I, i64 %idxprom.5 + %spec.select196 = select i1 %cmp55.6, i32 %loadOffset.0.6, i32 %conv63.6 + %loadOffset.1.6 = select i1 %cmp44.6, i32 %3, i32 %spec.select196 + %idxprom.6 = sext i32 %loadOffset.1.6 to i64 + %spec.select = select i1 %cmp55.us, i64 %loadOffset.0.us, i64 %conv63.us + %spec.select.op = shl i64 %spec.select, 32 + %spec.select.op.op = ashr exact i64 %spec.select.op, 32 + %idxprom.us = select i1 %cmp44.us, i64 0, i64 %spec.select.op.op + %arrayidx.us = getelementptr inbounds float, float* %I, i64 %idxprom.us + %spec.select198 = select i1 %cmp55.us.1, i64 %loadOffset.0.us.1, i64 %conv63.us.1 + %spec.select198.op = shl i64 %spec.select198, 32 + %spec.select198.op.op = ashr exact i64 %spec.select198.op, 32 + %idxprom.us.1 = select i1 %cmp44.us.1, i64 0, i64 %spec.select198.op.op + %arrayidx.us.1 = getelementptr inbounds float, float* %I, i64 %idxprom.us.1 + %loadOffset.0.us.2 = shl i64 %call1, 32 + %loadOffset.0.us.2.op = add i64 %loadOffset.0.us.2, -4294967296 + %loadOffset.0.us.2.op.op = ashr exact i64 %loadOffset.0.us.2.op, 32 + %idxprom.us.2 = select i1 %cmp44.us.2, i64 0, i64 %loadOffset.0.us.2.op.op + %arrayidx.us.2 = getelementptr inbounds float, float* %I, i64 %idxprom.us.2 + %22 = icmp sgt i64 %call1, 0 + %spec.select200 = select i1 %22, i64 %call1, i64 0 + %sext186 = shl i64 %spec.select200, 32 + %idxprom.us.3 = ashr exact i64 %sext186, 32 + %arrayidx.us.3 = getelementptr inbounds float, float* %I, i64 %idxprom.us.3 + %spec.select201 = select i1 %cmp55.us.4, i64 %loadOffset.0.us.4, i64 %conv63.us.4 + %spec.select201.op = shl i64 %spec.select201, 32 + %spec.select201.op.op = ashr exact i64 %spec.select201.op, 32 + %idxprom.us.4 = select i1 %cmp44.us.4, i64 0, i64 %spec.select201.op.op + %arrayidx.us.4 = getelementptr inbounds float, float* %I, i64 %idxprom.us.4 + %spec.select202 = select i1 %cmp55.us.5, i64 %loadOffset.0.us.5, i64 %conv63.us.5 + %spec.select202.op = shl i64 %spec.select202, 32 + %spec.select202.op.op = ashr exact i64 %spec.select202.op, 32 + %idxprom.us.5 = select i1 %cmp44.us.5, i64 0, i64 %spec.select202.op.op + %arrayidx.us.5 = getelementptr inbounds float, float* %I, i64 %idxprom.us.5 + %spec.select203 = select i1 %cmp55.us.6, i64 %loadOffset.0.us.6, i64 %conv63.us.6 + %spec.select203.op = shl i64 %spec.select203, 32 + %spec.select203.op.op = ashr exact i64 %spec.select203.op, 32 + %idxprom.us.6 = select i1 %cmp44.us.6, i64 0, i64 %spec.select203.op.op + br label %for.cond5.preheader + +for.cond5.preheader: ; preds = %for.cond.cleanup7, %for.cond.preheader + %indvars.iv180 = phi i64 [ -3, %for.cond.preheader ], [ %indvars.iv.next181, %for.cond.cleanup7 ] + %indvars.iv = phi i32 [ %6, %for.cond.preheader ], [ %indvars.iv.next, %for.cond.cleanup7 ] + %smoothedVal.0169 = phi float [ 0.000000e+00, %for.cond.preheader ], [ %add73.6, %for.cond.cleanup7 ] + %add17 = add nsw i64 %call2, %indvars.iv180 + %cmp18 = icmp slt i64 %add17, 0 + %mul11 = mul nsw i64 %indvars.iv180, %n + %add12 = add i64 %mul11, %add + %23 = mul nsw i64 %indvars.iv180, 7 + %24 = add nsw i64 %23, 24 + br i1 %cmp18, label %for.body8.us.preheader, label %for.cond5.preheader.split + +for.body8.us.preheader: ; preds = %for.cond5.preheader + %25 = load float, float* %arrayidx.us, align 4, !tbaa !33 + %26 = add nsw i64 %23, 21 + %arrayidx71.us = getelementptr inbounds float, float* %Gs, i64 %26 + %27 = load float, float* %arrayidx71.us, align 4, !tbaa !33 + %mul72.us = fmul fast float %27, %25 + %add73.us = fadd fast float %mul72.us, %smoothedVal.0169 + %28 = load float, float* %arrayidx.us.1, align 4, !tbaa !33 + %29 = add nsw i64 %23, 22 + %arrayidx71.us.1 = getelementptr inbounds float, float* %Gs, i64 %29 + %30 = load float, float* %arrayidx71.us.1, align 4, !tbaa !33 + %mul72.us.1 = fmul fast float %30, %28 + %add73.us.1 = fadd fast float %mul72.us.1, %add73.us + %31 = load float, float* %arrayidx.us.2, align 4, !tbaa !33 + %32 = add nsw i64 %23, 23 + %arrayidx71.us.2 = getelementptr inbounds float, float* %Gs, i64 %32 + %33 = load float, float* %arrayidx71.us.2, align 4, !tbaa !33 + %mul72.us.2 = fmul fast float %33, %31 + %add73.us.2 = fadd fast float %mul72.us.2, %add73.us.1 + %34 = load float, float* %arrayidx.us.3, align 4, !tbaa !33 + %arrayidx71.us.3 = getelementptr inbounds float, float* %Gs, i64 %24 + %35 = load float, float* %arrayidx71.us.3, align 4, !tbaa !33 + %mul72.us.3 = fmul fast float %35, %34 + %add73.us.3 = fadd fast float %mul72.us.3, %add73.us.2 + %36 = load float, float* %arrayidx.us.4, align 4, !tbaa !33 + %37 = add nsw i64 %23, 25 + %arrayidx71.us.4 = getelementptr inbounds float, float* %Gs, i64 %37 + %38 = load float, float* %arrayidx71.us.4, align 4, !tbaa !33 + %mul72.us.4 = fmul fast float %38, %36 + %add73.us.4 = fadd fast float %mul72.us.4, %add73.us.3 + %39 = load float, float* %arrayidx.us.5, align 4, !tbaa !33 + %40 = add nsw i64 %23, 26 + %arrayidx71.us.5 = getelementptr inbounds float, float* %Gs, i64 %40 + %41 = load float, float* %arrayidx71.us.5, align 4, !tbaa !33 + %mul72.us.5 = fmul fast float %41, %39 + %add73.us.5 = fadd fast float %mul72.us.5, %add73.us.4 + br label %for.cond.cleanup7 + +for.cond5.preheader.split: ; preds = %for.cond5.preheader + %cmp25 = icmp slt i64 %add17, %m + br i1 %cmp25, label %for.body8.us136.preheader, label %for.body8.preheader + +for.body8.preheader: ; preds = %for.cond5.preheader.split + %42 = load float, float* %arrayidx, align 4, !tbaa !33 + %43 = add nsw i64 %23, 21 + %arrayidx71 = getelementptr inbounds float, float* %Gs, i64 %43 + %44 = load float, float* %arrayidx71, align 4, !tbaa !33 + %mul72 = fmul fast float %44, %42 + %add73 = fadd fast float %mul72, %smoothedVal.0169 + %45 = load float, float* %arrayidx.1, align 4, !tbaa !33 + %46 = add nsw i64 %23, 22 + %arrayidx71.1 = getelementptr inbounds float, float* %Gs, i64 %46 + %47 = load float, float* %arrayidx71.1, align 4, !tbaa !33 + %mul72.1 = fmul fast float %47, %45 + %add73.1 = fadd fast float %mul72.1, %add73 + %48 = load float, float* %arrayidx.2, align 4, !tbaa !33 + %49 = add nsw i64 %23, 23 + %arrayidx71.2 = getelementptr inbounds float, float* %Gs, i64 %49 + %50 = load float, float* %arrayidx71.2, align 4, !tbaa !33 + %mul72.2 = fmul fast float %50, %48 + %add73.2 = fadd fast float %mul72.2, %add73.1 + %51 = load float, float* %arrayidx.3, align 4, !tbaa !33 + %arrayidx71.3 = getelementptr inbounds float, float* %Gs, i64 %24 + %52 = load float, float* %arrayidx71.3, align 4, !tbaa !33 + %mul72.3 = fmul fast float %52, %51 + %add73.3 = fadd fast float %mul72.3, %add73.2 + %53 = load float, float* %arrayidx.4, align 4, !tbaa !33 + %54 = add nsw i64 %23, 25 + %arrayidx71.4 = getelementptr inbounds float, float* %Gs, i64 %54 + %55 = load float, float* %arrayidx71.4, align 4, !tbaa !33 + %mul72.4 = fmul fast float %55, %53 + %add73.4 = fadd fast float %mul72.4, %add73.3 + %56 = load float, float* %arrayidx.5, align 4, !tbaa !33 + %57 = add nsw i64 %23, 26 + %arrayidx71.5 = getelementptr inbounds float, float* %Gs, i64 %57 + %58 = load float, float* %arrayidx71.5, align 4, !tbaa !33 + %mul72.5 = fmul fast float %58, %56 + %add73.5 = fadd fast float %mul72.5, %add73.4 + br label %for.cond.cleanup7 + +for.body8.us136.preheader: ; preds = %for.cond5.preheader.split + %.pn.us144 = trunc i64 %add12 to i32 + br i1 %cmp44.us147, label %if.end65.us158, label %if.else51.us148 + +if.else51.us148: ; preds = %for.body8.us136.preheader + %loadOffset.0.us145 = add i32 %.pn.us144, -3 + br i1 %cmp55.us149, label %if.end65.us158, label %if.then56.us150 + +if.then56.us150: ; preds = %if.else51.us148 + %59 = add i32 %17, %.pn.us144 + %conv63.us155 = add i32 %59, -1 + br label %if.end65.us158 + +if.end65.us158: ; preds = %for.body8.us136.preheader, %if.then56.us150, %if.else51.us148 + %loadOffset.1.us159 = phi i32 [ %conv63.us155, %if.then56.us150 ], [ %loadOffset.0.us145, %if.else51.us148 ], [ %indvars.iv, %for.body8.us136.preheader ] + %idxprom.us160 = sext i32 %loadOffset.1.us159 to i64 + %arrayidx.us161 = getelementptr inbounds float, float* %I, i64 %idxprom.us160 + %60 = load float, float* %arrayidx.us161, align 4, !tbaa !33 + %61 = add nsw i64 %23, 21 + %arrayidx71.us164 = getelementptr inbounds float, float* %Gs, i64 %61 + %62 = load float, float* %arrayidx71.us164, align 4, !tbaa !33 + %mul72.us165 = fmul fast float %62, %60 + %add73.us166 = fadd fast float %mul72.us165, %smoothedVal.0169 + br i1 %cmp44.us147.1, label %if.end65.us158.1, label %if.else51.us148.1 + +for.cond.cleanup: ; preds = %for.cond.cleanup7 + %sext = shl i64 %add, 32 + %idxprom77 = ashr exact i64 %sext, 32 + %arrayidx78 = getelementptr inbounds float, float* %Is, i64 %idxprom77 + store float %add73.6, float* %arrayidx78, align 4, !tbaa !33 + br label %if.end79 + +for.cond.cleanup7: ; preds = %for.body8.preheader, %if.end65.us158.6, %for.body8.us.preheader + %idxprom.6.sink = phi i64 [ %idxprom.6, %for.body8.preheader ], [ %idxprom.us160.6, %if.end65.us158.6 ], [ %idxprom.us.6, %for.body8.us.preheader ] + %add73.5.sink = phi float [ %add73.5, %for.body8.preheader ], [ %add73.us166.5, %if.end65.us158.6 ], [ %add73.us.5, %for.body8.us.preheader ] + %arrayidx.6 = getelementptr inbounds float, float* %I, i64 %idxprom.6.sink + %63 = load float, float* %arrayidx.6, align 4, !tbaa !33 + %64 = add nsw i64 %23, 27 + %arrayidx71.6 = getelementptr inbounds float, float* %Gs, i64 %64 + %65 = load float, float* %arrayidx71.6, align 4, !tbaa !33 + %mul72.6 = fmul fast float %65, %63 + %add73.6 = fadd fast float %mul72.6, %add73.5.sink + %indvars.iv.next181 = add nsw i64 %indvars.iv180, 1 + %indvars.iv.next = add i32 %indvars.iv, %2 + %exitcond = icmp eq i64 %indvars.iv.next181, 4 + br i1 %exitcond, label %for.cond.cleanup, label %for.cond5.preheader + +if.end79: ; preds = %for.cond.cleanup, %entry + tail call void (i32, ...) @__visc__return(i32 2, i64 %bytesIs, i64 %bytesIs) + ret void + +if.else51.us148.1: ; preds = %if.end65.us158 + %loadOffset.0.us145.1 = add i32 %.pn.us144, -2 + br i1 %cmp55.us149.1, label %if.end65.us158.1, label %if.then56.us150.1 + +if.then56.us150.1: ; preds = %if.else51.us148.1 + %66 = add i32 %18, %.pn.us144 + %conv63.us155.1 = add i32 %66, -1 + br label %if.end65.us158.1 + +if.end65.us158.1: ; preds = %if.end65.us158, %if.then56.us150.1, %if.else51.us148.1 + %loadOffset.1.us159.1 = phi i32 [ %conv63.us155.1, %if.then56.us150.1 ], [ %loadOffset.0.us145.1, %if.else51.us148.1 ], [ %indvars.iv, %if.end65.us158 ] + %idxprom.us160.1 = sext i32 %loadOffset.1.us159.1 to i64 + %arrayidx.us161.1 = getelementptr inbounds float, float* %I, i64 %idxprom.us160.1 + %67 = load float, float* %arrayidx.us161.1, align 4, !tbaa !33 + %68 = add nsw i64 %23, 22 + %arrayidx71.us164.1 = getelementptr inbounds float, float* %Gs, i64 %68 + %69 = load float, float* %arrayidx71.us164.1, align 4, !tbaa !33 + %mul72.us165.1 = fmul fast float %69, %67 + %add73.us166.1 = fadd fast float %mul72.us165.1, %add73.us166 + %loadOffset.0.us145.2 = add i32 %.pn.us144, -1 + %spec.select205 = select i1 %cmp44.us147.2, i32 %indvars.iv, i32 %loadOffset.0.us145.2 + %idxprom.us160.2 = sext i32 %spec.select205 to i64 + %arrayidx.us161.2 = getelementptr inbounds float, float* %I, i64 %idxprom.us160.2 + %70 = load float, float* %arrayidx.us161.2, align 4, !tbaa !33 + %71 = add nsw i64 %23, 23 + %arrayidx71.us164.2 = getelementptr inbounds float, float* %Gs, i64 %71 + %72 = load float, float* %arrayidx71.us164.2, align 4, !tbaa !33 + %mul72.us165.2 = fmul fast float %72, %70 + %add73.us166.2 = fadd fast float %mul72.us165.2, %add73.us166.1 + %spec.select197 = select i1 %cmp44.us147.3, i32 %indvars.iv, i32 %.pn.us144 + %idxprom.us160.3 = sext i32 %spec.select197 to i64 + %arrayidx.us161.3 = getelementptr inbounds float, float* %I, i64 %idxprom.us160.3 + %73 = load float, float* %arrayidx.us161.3, align 4, !tbaa !33 + %arrayidx71.us164.3 = getelementptr inbounds float, float* %Gs, i64 %24 + %74 = load float, float* %arrayidx71.us164.3, align 4, !tbaa !33 + %mul72.us165.3 = fmul fast float %74, %73 + %add73.us166.3 = fadd fast float %mul72.us165.3, %add73.us166.2 + br i1 %cmp44.us147.4, label %if.end65.us158.4, label %if.else51.us148.4 + +if.else51.us148.4: ; preds = %if.end65.us158.1 + %loadOffset.0.us145.4 = add i32 %.pn.us144, 1 + br i1 %cmp55.us149.4, label %if.end65.us158.4, label %if.then56.us150.4 + +if.then56.us150.4: ; preds = %if.else51.us148.4 + %75 = add i32 %19, %.pn.us144 + %conv63.us155.4 = add i32 %75, -1 + br label %if.end65.us158.4 + +if.end65.us158.4: ; preds = %if.end65.us158.1, %if.then56.us150.4, %if.else51.us148.4 + %loadOffset.1.us159.4 = phi i32 [ %conv63.us155.4, %if.then56.us150.4 ], [ %loadOffset.0.us145.4, %if.else51.us148.4 ], [ %indvars.iv, %if.end65.us158.1 ] + %idxprom.us160.4 = sext i32 %loadOffset.1.us159.4 to i64 + %arrayidx.us161.4 = getelementptr inbounds float, float* %I, i64 %idxprom.us160.4 + %76 = load float, float* %arrayidx.us161.4, align 4, !tbaa !33 + %77 = add nsw i64 %23, 25 + %arrayidx71.us164.4 = getelementptr inbounds float, float* %Gs, i64 %77 + %78 = load float, float* %arrayidx71.us164.4, align 4, !tbaa !33 + %mul72.us165.4 = fmul fast float %78, %76 + %add73.us166.4 = fadd fast float %mul72.us165.4, %add73.us166.3 + br i1 %cmp44.us147.5, label %if.end65.us158.5, label %if.else51.us148.5 + +if.else51.us148.5: ; preds = %if.end65.us158.4 + %loadOffset.0.us145.5 = add i32 %.pn.us144, 2 + br i1 %cmp55.us149.5, label %if.end65.us158.5, label %if.then56.us150.5 + +if.then56.us150.5: ; preds = %if.else51.us148.5 + %79 = add i32 %20, %.pn.us144 + %conv63.us155.5 = add i32 %79, -1 + br label %if.end65.us158.5 + +if.end65.us158.5: ; preds = %if.end65.us158.4, %if.then56.us150.5, %if.else51.us148.5 + %loadOffset.1.us159.5 = phi i32 [ %conv63.us155.5, %if.then56.us150.5 ], [ %loadOffset.0.us145.5, %if.else51.us148.5 ], [ %indvars.iv, %if.end65.us158.4 ] + %idxprom.us160.5 = sext i32 %loadOffset.1.us159.5 to i64 + %arrayidx.us161.5 = getelementptr inbounds float, float* %I, i64 %idxprom.us160.5 + %80 = load float, float* %arrayidx.us161.5, align 4, !tbaa !33 + %81 = add nsw i64 %23, 26 + %arrayidx71.us164.5 = getelementptr inbounds float, float* %Gs, i64 %81 + %82 = load float, float* %arrayidx71.us164.5, align 4, !tbaa !33 + %mul72.us165.5 = fmul fast float %82, %80 + %add73.us166.5 = fadd fast float %mul72.us165.5, %add73.us166.4 + br i1 %cmp44.us147.6, label %if.end65.us158.6, label %if.else51.us148.6 + +if.else51.us148.6: ; preds = %if.end65.us158.5 + %loadOffset.0.us145.6 = add i32 %.pn.us144, 3 + br i1 %cmp55.us149.6, label %if.end65.us158.6, label %if.then56.us150.6 + +if.then56.us150.6: ; preds = %if.else51.us148.6 + %83 = add i32 %21, %.pn.us144 + %conv63.us155.6 = add i32 %83, -1 + br label %if.end65.us158.6 + +if.end65.us158.6: ; preds = %if.end65.us158.5, %if.then56.us150.6, %if.else51.us148.6 + %loadOffset.1.us159.6 = phi i32 [ %conv63.us155.6, %if.then56.us150.6 ], [ %loadOffset.0.us145.6, %if.else51.us148.6 ], [ %indvars.iv, %if.end65.us158.5 ] + %idxprom.us160.6 = sext i32 %loadOffset.1.us159.6 to i64 + br label %for.cond.cleanup7 +} + +declare dso_local void @__visc__hint(i32) local_unnamed_addr #0 + +declare dso_local void @__visc__attributes(i32, ...) local_unnamed_addr #0 + +declare dso_local i8* @__visc__getNode() local_unnamed_addr #0 + +declare dso_local i64 @__visc__getNodeInstanceID_x(i8*) local_unnamed_addr #0 + +declare dso_local i64 @__visc__getNodeInstanceID_y(i8*) local_unnamed_addr #0 + +declare dso_local void @__visc__return(i32, ...) local_unnamed_addr #0 + +; Function Attrs: uwtable +define dso_local void @WrapperGaussianSmoothing(float* %I, i64 %bytesI, float* %Gs, i64 %bytesGs, float* %Is, i64 %bytesIs, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 2, float* %I, float* %Gs, i32 1, float* %Is) + %call = tail call i8* (i32, ...) @__visc__createNodeND(i32 2, void (float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @gaussianSmoothing, i64 %m, i64 %n) + tail call void @__visc__bindIn(i8* %call, i32 0, i32 0, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 1, i32 1, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 2, i32 2, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 3, i32 3, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 4, i32 4, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 5, i32 5, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 6, i32 6, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 7, i32 7, i32 0) + tail call void @__visc__bindOut(i8* %call, i32 0, i32 0, i32 0) + tail call void @__visc__bindOut(i8* %call, i32 1, i32 1, i32 0) + ret void +} + +declare dso_local i8* @__visc__createNodeND(i32, ...) local_unnamed_addr #0 + +declare dso_local void @__visc__bindIn(i8*, i32, i32, i32) local_unnamed_addr #0 + +declare dso_local void @__visc__bindOut(i8*, i32, i32, i32) local_unnamed_addr #0 + +; Function Attrs: uwtable +define dso_local void @laplacianEstimate(float* %Is, i64 %bytesIs, float* %B, i64 %bytesB, float* %L, i64 %bytesL, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 2, float* %Is, float* %B, i32 1, float* %L) + %call = tail call i8* @__visc__getNode() + %call1 = tail call i64 @__visc__getNodeInstanceID_x(i8* %call) + %call2 = tail call i64 @__visc__getNodeInstanceID_y(i8* %call) + %cmp = icmp slt i64 %call1, %n + %cmp3 = icmp slt i64 %call2, %m + %or.cond = and i1 %cmp, %cmp3 + br i1 %or.cond, label %if.then, label %if.end203 + +if.then: ; preds = %entry + %mul = mul nsw i64 %call2, %n + %add = add nsw i64 %mul, %call1 + %arrayidx = getelementptr inbounds float, float* %Is, i64 %add + %0 = load float, float* %arrayidx, align 4, !tbaa !33 + %cmp5 = icmp eq i64 %call1, 0 + br i1 %cmp5, label %if.end, label %if.else + +if.else: ; preds = %if.then + %sub = add nsw i64 %add, -1 + %arrayidx12 = getelementptr inbounds float, float* %Is, i64 %sub + %1 = load float, float* %arrayidx12, align 4, !tbaa !33 + %cmp14 = icmp sgt i64 %call2, 0 + br i1 %cmp14, label %cond.true, label %cond.end + +cond.true: ; preds = %if.else + %sub15 = add nsw i64 %call2, -1 + %mul16 = mul nsw i64 %sub15, %n + %add17 = add i64 %call1, -1 + %sub18 = add i64 %add17, %mul16 + %arrayidx19 = getelementptr inbounds float, float* %Is, i64 %sub18 + %2 = load float, float* %arrayidx19, align 4, !tbaa !33 + br label %cond.end + +cond.end: ; preds = %if.else, %cond.true + %cond = phi float [ %2, %cond.true ], [ 0.000000e+00, %if.else ] + %sub21 = add nsw i64 %m, -1 + %cmp22 = icmp slt i64 %call2, %sub21 + br i1 %cmp22, label %cond.true23, label %if.end + +cond.true23: ; preds = %cond.end + %add24 = add nsw i64 %call2, 1 + %mul25 = mul nsw i64 %add24, %n + %add26 = add i64 %call1, -1 + %sub27 = add i64 %add26, %mul25 + %arrayidx28 = getelementptr inbounds float, float* %Is, i64 %sub27 + %3 = load float, float* %arrayidx28, align 4, !tbaa !33 + br label %if.end + +if.end: ; preds = %cond.true23, %cond.end, %if.then + %4 = phi float [ 0.000000e+00, %if.then ], [ %1, %cond.end ], [ %1, %cond.true23 ] + %5 = phi float [ 0.000000e+00, %if.then ], [ 0.000000e+00, %cond.end ], [ %3, %cond.true23 ] + %6 = phi float [ 0.000000e+00, %if.then ], [ %cond, %cond.end ], [ %cond, %cond.true23 ] + %sub33 = add nsw i64 %n, -1 + %cmp34 = icmp eq i64 %call1, %sub33 + br i1 %cmp34, label %if.end68, label %if.else39 + +if.else39: ; preds = %if.end + %add42 = add nsw i64 %add, 1 + %arrayidx43 = getelementptr inbounds float, float* %Is, i64 %add42 + %7 = load float, float* %arrayidx43, align 4, !tbaa !33 + %cmp45 = icmp sgt i64 %call2, 0 + br i1 %cmp45, label %cond.true46, label %cond.end53 + +cond.true46: ; preds = %if.else39 + %sub47 = add nsw i64 %call2, -1 + %mul48 = mul nsw i64 %sub47, %n + %add49 = add nsw i64 %call1, 1 + %add50 = add i64 %add49, %mul48 + %arrayidx51 = getelementptr inbounds float, float* %Is, i64 %add50 + %8 = load float, float* %arrayidx51, align 4, !tbaa !33 + br label %cond.end53 + +cond.end53: ; preds = %if.else39, %cond.true46 + %cond54 = phi float [ %8, %cond.true46 ], [ 0.000000e+00, %if.else39 ] + %sub56 = add nsw i64 %m, -1 + %cmp57 = icmp slt i64 %call2, %sub56 + br i1 %cmp57, label %cond.true58, label %if.end68 + +cond.true58: ; preds = %cond.end53 + %add59 = add nsw i64 %call2, 1 + %mul60 = mul nsw i64 %add59, %n + %add61 = add nsw i64 %call1, 1 + %add62 = add i64 %add61, %mul60 + %arrayidx63 = getelementptr inbounds float, float* %Is, i64 %add62 + %9 = load float, float* %arrayidx63, align 4, !tbaa !33 + br label %if.end68 + +if.end68: ; preds = %cond.true58, %cond.end53, %if.end + %10 = phi float [ 0.000000e+00, %if.end ], [ %7, %cond.end53 ], [ %7, %cond.true58 ] + %11 = phi float [ 0.000000e+00, %if.end ], [ 0.000000e+00, %cond.end53 ], [ %9, %cond.true58 ] + %12 = phi float [ 0.000000e+00, %if.end ], [ %cond54, %cond.end53 ], [ %cond54, %cond.true58 ] + %cmp69 = icmp sgt i64 %call2, 0 + br i1 %cmp69, label %cond.true70, label %cond.end76 + +cond.true70: ; preds = %if.end68 + %sub71 = add nsw i64 %call2, -1 + %mul72 = mul nsw i64 %sub71, %n + %add73 = add nsw i64 %mul72, %call1 + %arrayidx74 = getelementptr inbounds float, float* %Is, i64 %add73 + %13 = load float, float* %arrayidx74, align 4, !tbaa !33 + br label %cond.end76 + +cond.end76: ; preds = %if.end68, %cond.true70 + %14 = phi float [ %13, %cond.true70 ], [ 0.000000e+00, %if.end68 ] + %sub79 = add nsw i64 %m, -1 + %cmp80 = icmp slt i64 %call2, %sub79 + br i1 %cmp80, label %cond.true81, label %cond.end87 + +cond.true81: ; preds = %cond.end76 + %add82 = add nsw i64 %call2, 1 + %mul83 = mul nsw i64 %add82, %n + %add84 = add nsw i64 %mul83, %call1 + %arrayidx85 = getelementptr inbounds float, float* %Is, i64 %add84 + %15 = load float, float* %arrayidx85, align 4, !tbaa !33 + br label %cond.end87 + +cond.end87: ; preds = %cond.end76, %cond.true81 + %cond88 = phi float [ %15, %cond.true81 ], [ 0.000000e+00, %cond.end76 ] + %16 = load float, float* %B, align 4, !tbaa !33 + %mul101 = fmul fast float %16, %6 + %cmp102 = fcmp fast olt float %mul101, 0.000000e+00 + %dilatedPixel.1.mul101 = select i1 %cmp102, float 0.000000e+00, float %mul101 + %arrayidx100.1 = getelementptr inbounds float, float* %B, i64 1 + %17 = load float, float* %arrayidx100.1, align 4, !tbaa !33 + %mul101.1 = fmul fast float %17, %14 + %cmp102.1 = fcmp fast ogt float %dilatedPixel.1.mul101, %mul101.1 + %dilatedPixel.1.mul101.1 = select i1 %cmp102.1, float %dilatedPixel.1.mul101, float %mul101.1 + %arrayidx100.2 = getelementptr inbounds float, float* %B, i64 2 + %18 = load float, float* %arrayidx100.2, align 4, !tbaa !33 + %mul101.2 = fmul fast float %18, %12 + %cmp102.2 = fcmp fast ogt float %dilatedPixel.1.mul101.1, %mul101.2 + %dilatedPixel.1.mul101.2 = select i1 %cmp102.2, float %dilatedPixel.1.mul101.1, float %mul101.2 + %arrayidx100.1330 = getelementptr inbounds float, float* %B, i64 3 + %19 = load float, float* %arrayidx100.1330, align 4, !tbaa !33 + %mul101.1331 = fmul fast float %19, %4 + %cmp102.1332 = fcmp fast ogt float %dilatedPixel.1.mul101.2, %mul101.1331 + %dilatedPixel.1.mul101.1333 = select i1 %cmp102.1332, float %dilatedPixel.1.mul101.2, float %mul101.1331 + %arrayidx100.1.1 = getelementptr inbounds float, float* %B, i64 4 + %20 = load float, float* %arrayidx100.1.1, align 4, !tbaa !33 + %mul101.1.1 = fmul fast float %20, %0 + %cmp102.1.1 = fcmp fast ogt float %dilatedPixel.1.mul101.1333, %mul101.1.1 + %dilatedPixel.1.mul101.1.1 = select i1 %cmp102.1.1, float %dilatedPixel.1.mul101.1333, float %mul101.1.1 + %arrayidx100.2.1 = getelementptr inbounds float, float* %B, i64 5 + %21 = load float, float* %arrayidx100.2.1, align 4, !tbaa !33 + %mul101.2.1 = fmul fast float %21, %10 + %cmp102.2.1 = fcmp fast ogt float %dilatedPixel.1.mul101.1.1, %mul101.2.1 + %dilatedPixel.1.mul101.2.1 = select i1 %cmp102.2.1, float %dilatedPixel.1.mul101.1.1, float %mul101.2.1 + %arrayidx100.2335 = getelementptr inbounds float, float* %B, i64 6 + %22 = load float, float* %arrayidx100.2335, align 4, !tbaa !33 + %mul101.2336 = fmul fast float %22, %5 + %cmp102.2337 = fcmp fast ogt float %dilatedPixel.1.mul101.2.1, %mul101.2336 + %dilatedPixel.1.mul101.2338 = select i1 %cmp102.2337, float %dilatedPixel.1.mul101.2.1, float %mul101.2336 + %arrayidx100.1.2 = getelementptr inbounds float, float* %B, i64 7 + %23 = load float, float* %arrayidx100.1.2, align 4, !tbaa !33 + %mul101.1.2 = fmul fast float %23, %cond88 + %cmp102.1.2 = fcmp fast ogt float %dilatedPixel.1.mul101.2338, %mul101.1.2 + %dilatedPixel.1.mul101.1.2 = select i1 %cmp102.1.2, float %dilatedPixel.1.mul101.2338, float %mul101.1.2 + %arrayidx100.2.2 = getelementptr inbounds float, float* %B, i64 8 + %24 = load float, float* %arrayidx100.2.2, align 4, !tbaa !33 + %mul101.2.2 = fmul fast float %24, %11 + %cmp102.2.2 = fcmp fast ogt float %dilatedPixel.1.mul101.1.2, %mul101.2.2 + %dilatedPixel.1.mul101.2.2 = select i1 %cmp102.2.2, float %dilatedPixel.1.mul101.1.2, float %mul101.2.2 + br i1 %cmp5, label %if.end134, label %if.else124 + +if.else124: ; preds = %cond.end87 + %cmp125 = icmp eq i64 %call2, 0 + %spec.select = select i1 %cmp125, float 1.000000e+00, float %6 + %cmp130 = icmp eq i64 %call2, %sub79 + %spec.select341 = select i1 %cmp130, float 1.000000e+00, float %5 + br label %if.end134 + +if.end134: ; preds = %if.else124, %cond.end87 + %25 = phi float [ 1.000000e+00, %cond.end87 ], [ %spec.select341, %if.else124 ] + %26 = phi float [ 1.000000e+00, %cond.end87 ], [ %4, %if.else124 ] + %27 = phi float [ 1.000000e+00, %cond.end87 ], [ %spec.select, %if.else124 ] + br i1 %cmp34, label %if.end151, label %if.else141 + +if.else141: ; preds = %if.end134 + %cmp142 = icmp eq i64 %call2, 0 + %spec.select339 = select i1 %cmp142, float 1.000000e+00, float %12 + %cmp147 = icmp eq i64 %call2, %sub79 + %spec.select342 = select i1 %cmp147, float 1.000000e+00, float %11 + br label %if.end151 + +if.end151: ; preds = %if.else141, %if.end134 + %28 = phi float [ 1.000000e+00, %if.end134 ], [ %spec.select342, %if.else141 ] + %29 = phi float [ 1.000000e+00, %if.end134 ], [ %10, %if.else141 ] + %30 = phi float [ 1.000000e+00, %if.end134 ], [ %spec.select339, %if.else141 ] + %cmp152 = icmp eq i64 %call2, 0 + %spec.select340 = select i1 %cmp152, float 1.000000e+00, float %14 + %cmp157 = icmp eq i64 %call2, %sub79 + %31 = select i1 %cmp157, float 1.000000e+00, float %cond88 + %mul175 = fmul fast float %16, %27 + %cmp176 = fcmp fast ogt float %mul175, 1.000000e+00 + %erodedPixel.1.mul175 = select i1 %cmp176, float 1.000000e+00, float %mul175 + %mul175.1 = fmul fast float %17, %spec.select340 + %cmp176.1 = fcmp fast olt float %erodedPixel.1.mul175, %mul175.1 + %erodedPixel.1.mul175.1 = select i1 %cmp176.1, float %erodedPixel.1.mul175, float %mul175.1 + %mul175.2 = fmul fast float %18, %30 + %cmp176.2 = fcmp fast olt float %erodedPixel.1.mul175.1, %mul175.2 + %erodedPixel.1.mul175.2 = select i1 %cmp176.2, float %erodedPixel.1.mul175.1, float %mul175.2 + %mul175.1319 = fmul fast float %19, %26 + %cmp176.1320 = fcmp fast olt float %erodedPixel.1.mul175.2, %mul175.1319 + %erodedPixel.1.mul175.1321 = select i1 %cmp176.1320, float %erodedPixel.1.mul175.2, float %mul175.1319 + %cmp176.1.1 = fcmp fast olt float %erodedPixel.1.mul175.1321, %mul101.1.1 + %erodedPixel.1.mul175.1.1 = select i1 %cmp176.1.1, float %erodedPixel.1.mul175.1321, float %mul101.1.1 + %mul175.2.1 = fmul fast float %21, %29 + %cmp176.2.1 = fcmp fast olt float %erodedPixel.1.mul175.1.1, %mul175.2.1 + %erodedPixel.1.mul175.2.1 = select i1 %cmp176.2.1, float %erodedPixel.1.mul175.1.1, float %mul175.2.1 + %mul175.2324 = fmul fast float %22, %25 + %cmp176.2325 = fcmp fast olt float %erodedPixel.1.mul175.2.1, %mul175.2324 + %erodedPixel.1.mul175.2326 = select i1 %cmp176.2325, float %erodedPixel.1.mul175.2.1, float %mul175.2324 + %mul175.1.2 = fmul fast float %23, %31 + %cmp176.1.2 = fcmp fast olt float %erodedPixel.1.mul175.2326, %mul175.1.2 + %erodedPixel.1.mul175.1.2 = select i1 %cmp176.1.2, float %erodedPixel.1.mul175.2326, float %mul175.1.2 + %mul175.2.2 = fmul fast float %24, %28 + %cmp176.2.2 = fcmp fast olt float %erodedPixel.1.mul175.1.2, %mul175.2.2 + %erodedPixel.1.mul175.2.2 = select i1 %cmp176.2.2, float %erodedPixel.1.mul175.1.2, float %mul175.2.2 + %add196 = fadd fast float %erodedPixel.1.mul175.2.2, %dilatedPixel.1.mul101.2.2 + %mul198.neg = fmul fast float %0, -2.000000e+00 + %sub199 = fadd fast float %add196, %mul198.neg + %arrayidx202 = getelementptr inbounds float, float* %L, i64 %add + store float %sub199, float* %arrayidx202, align 4, !tbaa !33 + br label %if.end203 + +if.end203: ; preds = %if.end151, %entry + tail call void (i32, ...) @__visc__return(i32 1, i64 %bytesL) + ret void +} + +; Function Attrs: uwtable +define dso_local void @WrapperlaplacianEstimate(float* %Is, i64 %bytesIs, float* %B, i64 %bytesB, float* %L, i64 %bytesL, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 2, float* %Is, float* %B, i32 1, float* %L) + %call = tail call i8* (i32, ...) @__visc__createNodeND(i32 2, void (float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @laplacianEstimate, i64 %m, i64 %n) + tail call void @__visc__bindIn(i8* %call, i32 0, i32 0, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 1, i32 1, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 2, i32 2, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 3, i32 3, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 4, i32 4, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 5, i32 5, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 6, i32 6, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 7, i32 7, i32 0) + tail call void @__visc__bindOut(i8* %call, i32 0, i32 0, i32 0) + ret void +} + +; Function Attrs: uwtable +define dso_local void @computeZeroCrossings(float* %L, i64 %bytesL, float* %B, i64 %bytesB, float* %S, i64 %bytesS, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 2, float* %L, float* %B, i32 1, float* %S) + %call = tail call i8* @__visc__getNode() + %call1 = tail call i64 @__visc__getNodeInstanceID_x(i8* %call) + %call2 = tail call i64 @__visc__getNodeInstanceID_y(i8* %call) + %cmp = icmp slt i64 %call1, %n + %cmp3 = icmp slt i64 %call2, %m + %or.cond = and i1 %cmp, %cmp3 + br i1 %or.cond, label %if.then, label %if.end245 + +if.then: ; preds = %entry + %mul = mul nsw i64 %call2, %n + %add = add nsw i64 %mul, %call1 + %arrayidx = getelementptr inbounds float, float* %L, i64 %add + %0 = load float, float* %arrayidx, align 4, !tbaa !33 + %cmp4 = fcmp fast ogt float %0, 0.000000e+00 + %cond = select fast i1 %cmp4, float 1.000000e+00, float 0.000000e+00 + %cmp7 = icmp eq i64 %call1, 0 + br i1 %cmp7, label %if.end, label %if.else + +if.else: ; preds = %if.then + %sub = add nsw i64 %add, -1 + %arrayidx17 = getelementptr inbounds float, float* %L, i64 %sub + %1 = load float, float* %arrayidx17, align 4, !tbaa !33 + %cmp18 = fcmp fast ogt float %1, 0.000000e+00 + %cond19 = select fast i1 %cmp18, float 1.000000e+00, float 0.000000e+00 + %cmp22 = icmp sgt i64 %call2, 0 + br i1 %cmp22, label %cond.true, label %cond.end + +cond.true: ; preds = %if.else + %sub23 = add nsw i64 %call2, -1 + %mul24 = mul nsw i64 %sub23, %n + %add25 = add i64 %call1, -1 + %sub26 = add i64 %add25, %mul24 + %arrayidx27 = getelementptr inbounds float, float* %L, i64 %sub26 + %2 = load float, float* %arrayidx27, align 4, !tbaa !33 + %cmp28 = fcmp fast ogt float %2, 0.000000e+00 + %cond29 = select fast i1 %cmp28, float 1.000000e+00, float 0.000000e+00 + br label %cond.end + +cond.end: ; preds = %if.else, %cond.true + %cond30 = phi float [ %cond29, %cond.true ], [ 0.000000e+00, %if.else ] + %sub33 = add nsw i64 %m, -1 + %cmp34 = icmp slt i64 %call2, %sub33 + br i1 %cmp34, label %cond.true35, label %if.end + +cond.true35: ; preds = %cond.end + %add36 = add nsw i64 %call2, 1 + %mul37 = mul nsw i64 %add36, %n + %add38 = add i64 %call1, -1 + %sub39 = add i64 %add38, %mul37 + %arrayidx40 = getelementptr inbounds float, float* %L, i64 %sub39 + %3 = load float, float* %arrayidx40, align 4, !tbaa !33 + %cmp41 = fcmp fast ogt float %3, 0.000000e+00 + %cond42 = select fast i1 %cmp41, float 1.000000e+00, float 0.000000e+00 + br label %if.end + +if.end: ; preds = %cond.true35, %cond.end, %if.then + %4 = phi float [ 0.000000e+00, %if.then ], [ %cond42, %cond.true35 ], [ 0.000000e+00, %cond.end ] + %5 = phi float [ 0.000000e+00, %if.then ], [ %cond19, %cond.true35 ], [ %cond19, %cond.end ] + %6 = phi float [ 0.000000e+00, %if.then ], [ %cond30, %cond.true35 ], [ %cond30, %cond.end ] + %sub48 = add nsw i64 %n, -1 + %cmp49 = icmp eq i64 %call1, %sub48 + br i1 %cmp49, label %if.end95, label %if.else57 + +if.else57: ; preds = %if.end + %add60 = add nsw i64 %add, 1 + %arrayidx61 = getelementptr inbounds float, float* %L, i64 %add60 + %7 = load float, float* %arrayidx61, align 4, !tbaa !33 + %cmp62 = fcmp fast ogt float %7, 0.000000e+00 + %cond63 = select fast i1 %cmp62, float 1.000000e+00, float 0.000000e+00 + %cmp66 = icmp sgt i64 %call2, 0 + br i1 %cmp66, label %cond.true67, label %cond.end76 + +cond.true67: ; preds = %if.else57 + %sub68 = add nsw i64 %call2, -1 + %mul69 = mul nsw i64 %sub68, %n + %add70 = add nsw i64 %call1, 1 + %add71 = add i64 %add70, %mul69 + %arrayidx72 = getelementptr inbounds float, float* %L, i64 %add71 + %8 = load float, float* %arrayidx72, align 4, !tbaa !33 + %cmp73 = fcmp fast ogt float %8, 0.000000e+00 + %cond74 = select fast i1 %cmp73, float 1.000000e+00, float 0.000000e+00 + br label %cond.end76 + +cond.end76: ; preds = %if.else57, %cond.true67 + %cond77 = phi float [ %cond74, %cond.true67 ], [ 0.000000e+00, %if.else57 ] + %sub80 = add nsw i64 %m, -1 + %cmp81 = icmp slt i64 %call2, %sub80 + br i1 %cmp81, label %cond.true82, label %if.end95 + +cond.true82: ; preds = %cond.end76 + %add83 = add nsw i64 %call2, 1 + %mul84 = mul nsw i64 %add83, %n + %add85 = add nsw i64 %call1, 1 + %add86 = add i64 %add85, %mul84 + %arrayidx87 = getelementptr inbounds float, float* %L, i64 %add86 + %9 = load float, float* %arrayidx87, align 4, !tbaa !33 + %cmp88 = fcmp fast ogt float %9, 0.000000e+00 + %cond89 = select fast i1 %cmp88, float 1.000000e+00, float 0.000000e+00 + br label %if.end95 + +if.end95: ; preds = %cond.true82, %cond.end76, %if.end + %10 = phi float [ 0.000000e+00, %if.end ], [ %cond89, %cond.true82 ], [ 0.000000e+00, %cond.end76 ] + %11 = phi float [ 0.000000e+00, %if.end ], [ %cond63, %cond.true82 ], [ %cond63, %cond.end76 ] + %12 = phi float [ 0.000000e+00, %if.end ], [ %cond77, %cond.true82 ], [ %cond77, %cond.end76 ] + %cmp96 = icmp sgt i64 %call2, 0 + br i1 %cmp96, label %cond.true97, label %cond.end105 + +cond.true97: ; preds = %if.end95 + %sub98 = add nsw i64 %call2, -1 + %mul99 = mul nsw i64 %sub98, %n + %add100 = add nsw i64 %mul99, %call1 + %arrayidx101 = getelementptr inbounds float, float* %L, i64 %add100 + %13 = load float, float* %arrayidx101, align 4, !tbaa !33 + %cmp102 = fcmp fast ogt float %13, 0.000000e+00 + %cond103 = select fast i1 %cmp102, float 1.000000e+00, float 0.000000e+00 + br label %cond.end105 + +cond.end105: ; preds = %if.end95, %cond.true97 + %14 = phi float [ %cond103, %cond.true97 ], [ 0.000000e+00, %if.end95 ] + %sub109 = add nsw i64 %m, -1 + %cmp110 = icmp slt i64 %call2, %sub109 + br i1 %cmp110, label %cond.true111, label %cond.end119 + +cond.true111: ; preds = %cond.end105 + %add112 = add nsw i64 %call2, 1 + %mul113 = mul nsw i64 %add112, %n + %add114 = add nsw i64 %mul113, %call1 + %arrayidx115 = getelementptr inbounds float, float* %L, i64 %add114 + %15 = load float, float* %arrayidx115, align 4, !tbaa !33 + %cmp116 = fcmp fast ogt float %15, 0.000000e+00 + %cond117 = select fast i1 %cmp116, float 1.000000e+00, float 0.000000e+00 + br label %cond.end119 + +cond.end119: ; preds = %cond.end105, %cond.true111 + %cond120 = phi float [ %cond117, %cond.true111 ], [ 0.000000e+00, %cond.end105 ] + %16 = load float, float* %B, align 4, !tbaa !33 + %mul134 = fmul fast float %16, %6 + %cmp135 = fcmp fast olt float %mul134, 0.000000e+00 + %dilatedPixel.1.mul134 = select i1 %cmp135, float 0.000000e+00, float %mul134 + %arrayidx133.1 = getelementptr inbounds float, float* %B, i64 1 + %17 = load float, float* %arrayidx133.1, align 4, !tbaa !33 + %mul134.1 = fmul fast float %17, %14 + %cmp135.1 = fcmp fast ogt float %dilatedPixel.1.mul134, %mul134.1 + %dilatedPixel.1.mul134.1 = select i1 %cmp135.1, float %dilatedPixel.1.mul134, float %mul134.1 + %arrayidx133.2 = getelementptr inbounds float, float* %B, i64 2 + %18 = load float, float* %arrayidx133.2, align 4, !tbaa !33 + %mul134.2 = fmul fast float %18, %12 + %cmp135.2 = fcmp fast ogt float %dilatedPixel.1.mul134.1, %mul134.2 + %dilatedPixel.1.mul134.2 = select i1 %cmp135.2, float %dilatedPixel.1.mul134.1, float %mul134.2 + %arrayidx133.1372 = getelementptr inbounds float, float* %B, i64 3 + %19 = load float, float* %arrayidx133.1372, align 4, !tbaa !33 + %mul134.1373 = fmul fast float %19, %5 + %cmp135.1374 = fcmp fast ogt float %dilatedPixel.1.mul134.2, %mul134.1373 + %dilatedPixel.1.mul134.1375 = select i1 %cmp135.1374, float %dilatedPixel.1.mul134.2, float %mul134.1373 + %arrayidx133.1.1 = getelementptr inbounds float, float* %B, i64 4 + %20 = load float, float* %arrayidx133.1.1, align 4, !tbaa !33 + %mul134.1.1 = fmul fast float %20, %cond + %cmp135.1.1 = fcmp fast ogt float %dilatedPixel.1.mul134.1375, %mul134.1.1 + %dilatedPixel.1.mul134.1.1 = select i1 %cmp135.1.1, float %dilatedPixel.1.mul134.1375, float %mul134.1.1 + %arrayidx133.2.1 = getelementptr inbounds float, float* %B, i64 5 + %21 = load float, float* %arrayidx133.2.1, align 4, !tbaa !33 + %mul134.2.1 = fmul fast float %21, %11 + %cmp135.2.1 = fcmp fast ogt float %dilatedPixel.1.mul134.1.1, %mul134.2.1 + %dilatedPixel.1.mul134.2.1 = select i1 %cmp135.2.1, float %dilatedPixel.1.mul134.1.1, float %mul134.2.1 + %arrayidx133.2377 = getelementptr inbounds float, float* %B, i64 6 + %22 = load float, float* %arrayidx133.2377, align 4, !tbaa !33 + %mul134.2378 = fmul fast float %22, %4 + %cmp135.2379 = fcmp fast ogt float %dilatedPixel.1.mul134.2.1, %mul134.2378 + %dilatedPixel.1.mul134.2380 = select i1 %cmp135.2379, float %dilatedPixel.1.mul134.2.1, float %mul134.2378 + %arrayidx133.1.2 = getelementptr inbounds float, float* %B, i64 7 + %23 = load float, float* %arrayidx133.1.2, align 4, !tbaa !33 + %mul134.1.2 = fmul fast float %23, %cond120 + %cmp135.1.2 = fcmp fast ogt float %dilatedPixel.1.mul134.2380, %mul134.1.2 + %dilatedPixel.1.mul134.1.2 = select i1 %cmp135.1.2, float %dilatedPixel.1.mul134.2380, float %mul134.1.2 + %arrayidx133.2.2 = getelementptr inbounds float, float* %B, i64 8 + %24 = load float, float* %arrayidx133.2.2, align 4, !tbaa !33 + %mul134.2.2 = fmul fast float %24, %10 + %cmp135.2.2 = fcmp fast ogt float %dilatedPixel.1.mul134.1.2, %mul134.2.2 + %dilatedPixel.1.mul134.2.2 = select i1 %cmp135.2.2, float %dilatedPixel.1.mul134.1.2, float %mul134.2.2 + br i1 %cmp7, label %if.end172, label %if.else160 + +if.else160: ; preds = %cond.end119 + %cmp161 = icmp eq i64 %call2, 0 + %spec.select = select i1 %cmp161, float 1.000000e+00, float %6 + %cmp167 = icmp eq i64 %call2, %sub109 + %spec.select383 = select i1 %cmp167, float 1.000000e+00, float %4 + br label %if.end172 + +if.end172: ; preds = %if.else160, %cond.end119 + %25 = phi float [ 1.000000e+00, %cond.end119 ], [ %spec.select383, %if.else160 ] + %26 = phi float [ 1.000000e+00, %cond.end119 ], [ %5, %if.else160 ] + %27 = phi float [ 1.000000e+00, %cond.end119 ], [ %spec.select, %if.else160 ] + br i1 %cmp49, label %if.end194, label %if.else182 + +if.else182: ; preds = %if.end172 + %cmp183 = icmp eq i64 %call2, 0 + %spec.select381 = select i1 %cmp183, float 1.000000e+00, float %12 + %cmp189 = icmp eq i64 %call2, %sub109 + %spec.select384 = select i1 %cmp189, float 1.000000e+00, float %10 + br label %if.end194 + +if.end194: ; preds = %if.else182, %if.end172 + %28 = phi float [ 1.000000e+00, %if.end172 ], [ %spec.select384, %if.else182 ] + %29 = phi float [ 1.000000e+00, %if.end172 ], [ %11, %if.else182 ] + %30 = phi float [ 1.000000e+00, %if.end172 ], [ %spec.select381, %if.else182 ] + %cmp195 = icmp eq i64 %call2, 0 + %spec.select382 = select i1 %cmp195, float 1.000000e+00, float %14 + %cmp201 = icmp eq i64 %call2, %sub109 + %31 = select i1 %cmp201, float 1.000000e+00, float %cond120 + %mul220 = fmul fast float %16, %27 + %cmp221 = fcmp fast ogt float %mul220, 1.000000e+00 + %erodedPixel.1.mul220 = select i1 %cmp221, float 1.000000e+00, float %mul220 + %mul220.1 = fmul fast float %17, %spec.select382 + %cmp221.1 = fcmp fast olt float %erodedPixel.1.mul220, %mul220.1 + %erodedPixel.1.mul220.1 = select i1 %cmp221.1, float %erodedPixel.1.mul220, float %mul220.1 + %mul220.2 = fmul fast float %18, %30 + %cmp221.2 = fcmp fast olt float %erodedPixel.1.mul220.1, %mul220.2 + %erodedPixel.1.mul220.2 = select i1 %cmp221.2, float %erodedPixel.1.mul220.1, float %mul220.2 + %mul220.1361 = fmul fast float %19, %26 + %cmp221.1362 = fcmp fast olt float %erodedPixel.1.mul220.2, %mul220.1361 + %erodedPixel.1.mul220.1363 = select i1 %cmp221.1362, float %erodedPixel.1.mul220.2, float %mul220.1361 + %cmp221.1.1 = fcmp fast olt float %erodedPixel.1.mul220.1363, %mul134.1.1 + %erodedPixel.1.mul220.1.1 = select i1 %cmp221.1.1, float %erodedPixel.1.mul220.1363, float %mul134.1.1 + %mul220.2.1 = fmul fast float %21, %29 + %cmp221.2.1 = fcmp fast olt float %erodedPixel.1.mul220.1.1, %mul220.2.1 + %erodedPixel.1.mul220.2.1 = select i1 %cmp221.2.1, float %erodedPixel.1.mul220.1.1, float %mul220.2.1 + %mul220.2366 = fmul fast float %22, %25 + %cmp221.2367 = fcmp fast olt float %erodedPixel.1.mul220.2.1, %mul220.2366 + %erodedPixel.1.mul220.2368 = select i1 %cmp221.2367, float %erodedPixel.1.mul220.2.1, float %mul220.2366 + %mul220.1.2 = fmul fast float %23, %31 + %cmp221.1.2 = fcmp fast olt float %erodedPixel.1.mul220.2368, %mul220.1.2 + %erodedPixel.1.mul220.1.2 = select i1 %cmp221.1.2, float %erodedPixel.1.mul220.2368, float %mul220.1.2 + %mul220.2.2 = fmul fast float %24, %28 + %cmp221.2.2 = fcmp fast olt float %erodedPixel.1.mul220.1.2, %mul220.2.2 + %erodedPixel.1.mul220.2.2 = select i1 %cmp221.2.2, float %erodedPixel.1.mul220.1.2, float %mul220.2.2 + %sub241 = fsub fast float %dilatedPixel.1.mul134.2.2, %erodedPixel.1.mul220.2.2 + %arrayidx244 = getelementptr inbounds float, float* %S, i64 %add + store float %sub241, float* %arrayidx244, align 4, !tbaa !33 + br label %if.end245 + +if.end245: ; preds = %if.end194, %entry + tail call void (i32, ...) @__visc__return(i32 1, i64 %bytesS) + ret void +} + +; Function Attrs: uwtable +define dso_local void @WrapperComputeZeroCrossings(float* %L, i64 %bytesL, float* %B, i64 %bytesB, float* %S, i64 %bytesS, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 2, float* %L, float* %B, i32 1, float* %S) + %call = tail call i8* (i32, ...) @__visc__createNodeND(i32 2, void (float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @computeZeroCrossings, i64 %m, i64 %n) + tail call void @__visc__bindIn(i8* %call, i32 0, i32 0, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 1, i32 1, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 2, i32 2, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 3, i32 3, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 4, i32 4, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 5, i32 5, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 6, i32 6, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 7, i32 7, i32 0) + tail call void @__visc__bindOut(i8* %call, i32 0, i32 0, i32 0) + ret void +} + +; Function Attrs: uwtable +define dso_local void @computeGradient(float* %Is, i64 %bytesIs, float* %Sx, i64 %bytesSx, float* %Sy, i64 %bytesSy, float* %G, i64 %bytesG, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 3, float* %Is, float* %Sx, float* %Sy, i32 1, float* %G) + %call = tail call i8* @__visc__getNode() + %call1 = tail call i64 @__visc__getNodeInstanceID_x(i8* %call) + %call2 = tail call i64 @__visc__getNodeInstanceID_y(i8* %call) + %mul = mul nsw i64 %call2, %n + %add = add nsw i64 %mul, %call1 + %cmp = icmp slt i64 %call1, %n + %cmp3 = icmp slt i64 %call2, %m + %or.cond = and i1 %cmp, %cmp3 + br i1 %or.cond, label %for.cond.preheader, label %if.end91 + +for.cond.preheader: ; preds = %entry + %sub = add nsw i64 %m, -1 + %mul28 = mul nsw i64 %sub, %n + %add29 = add nsw i64 %call1, %mul28 + %sub58 = sub i64 %n, %call1 + %0 = trunc i64 %m to i32 + %1 = add i32 %0, -1 + %2 = trunc i64 %n to i32 + %3 = mul i32 %1, %2 + %4 = trunc i64 %call2 to i32 + %5 = add i32 %4, -1 + %6 = mul i32 %5, %2 + %.pn = trunc i64 %add29 to i32 + %cmp44 = icmp slt i64 %call1, 1 + %loadOffset.0 = add i32 %.pn, -1 + %cmp44.1 = icmp slt i64 %call1, 0 + %add43.2 = add nsw i64 %call1, 1 + %cmp44.2 = icmp slt i64 %add43.2, 0 + %loadOffset.0.2 = add i32 %.pn, 1 + %cmp55.2 = icmp slt i64 %add43.2, %n + %7 = trunc i64 %sub58 to i32 + %8 = add i32 %7, %.pn + %conv63.2 = add i32 %8, -1 + %cmp44.us168 = icmp slt i64 %call1, 1 + %cmp44.us168.1 = icmp slt i64 %call1, 0 + %add43.us167.2 = add nsw i64 %call1, 1 + %cmp44.us168.2 = icmp slt i64 %add43.us167.2, 0 + %cmp55.us170.2 = icmp slt i64 %add43.us167.2, %n + %9 = trunc i64 %sub58 to i32 + %cmp44.us = icmp slt i64 %call1, 1 + %add43.us.2 = add nsw i64 %call1, 1 + %cmp44.us.2 = icmp slt i64 %add43.us.2, 0 + %loadOffset.0.us.2 = add nsw i64 %call1, 1 + %cmp55.us.2 = icmp slt i64 %add43.us.2, %n + %conv63.us.2 = add i64 %n, 4294967295 + %cmp18 = icmp slt i64 %call2, 1 + %add12 = sub i64 %add, %n + br i1 %cmp18, label %for.body8.us.preheader, label %for.cond5.preheader.split + +for.body8.us.preheader: ; preds = %for.cond.preheader + %loadOffset.0.us = shl i64 %call1, 32 + %loadOffset.0.us.op = add i64 %loadOffset.0.us, -4294967296 + %loadOffset.0.us.op.op = ashr exact i64 %loadOffset.0.us.op, 32 + %idxprom.us = select i1 %cmp44.us, i64 0, i64 %loadOffset.0.us.op.op + %arrayidx.us = getelementptr inbounds float, float* %Is, i64 %idxprom.us + %10 = load float, float* %arrayidx.us, align 4, !tbaa !33 + %11 = load float, float* %Sx, align 4, !tbaa !33 + %mul72.us = fmul fast float %11, %10 + %12 = load float, float* %Sy, align 4, !tbaa !33 + %mul80.us = fmul fast float %12, %10 + %13 = icmp sgt i64 %call1, 0 + %spec.select211 = select i1 %13, i64 %call1, i64 0 + %sext209 = shl i64 %spec.select211, 32 + %idxprom.us.1 = ashr exact i64 %sext209, 32 + %arrayidx.us.1 = getelementptr inbounds float, float* %Is, i64 %idxprom.us.1 + %14 = load float, float* %arrayidx.us.1, align 4, !tbaa !33 + %arrayidx71.us.1 = getelementptr inbounds float, float* %Sx, i64 1 + %15 = load float, float* %arrayidx71.us.1, align 4, !tbaa !33 + %mul72.us.1 = fmul fast float %15, %14 + %add73.us.1 = fadd fast float %mul72.us.1, %mul72.us + %arrayidx79.us.1 = getelementptr inbounds float, float* %Sy, i64 1 + %16 = load float, float* %arrayidx79.us.1, align 4, !tbaa !33 + %mul80.us.1 = fmul fast float %16, %14 + %add81.us.1 = fadd fast float %mul80.us.1, %mul80.us + %spec.select216 = select i1 %cmp55.us.2, i64 %loadOffset.0.us.2, i64 %conv63.us.2 + %spec.select216.op = shl i64 %spec.select216, 32 + %spec.select216.op.op = ashr exact i64 %spec.select216.op, 32 + %idxprom.us.2 = select i1 %cmp44.us.2, i64 0, i64 %spec.select216.op.op + br label %for.cond.cleanup7 + +for.cond5.preheader.split: ; preds = %for.cond.preheader + %cmp25 = icmp sgt i64 %call2, %m + br i1 %cmp25, label %for.body8.preheader, label %for.body8.us156.preheader + +for.body8.preheader: ; preds = %for.cond5.preheader.split + %loadOffset.1 = select i1 %cmp44, i32 %3, i32 %loadOffset.0 + %idxprom = sext i32 %loadOffset.1 to i64 + %arrayidx = getelementptr inbounds float, float* %Is, i64 %idxprom + %17 = load float, float* %arrayidx, align 4, !tbaa !33 + %18 = load float, float* %Sx, align 4, !tbaa !33 + %mul72 = fmul fast float %18, %17 + %19 = load float, float* %Sy, align 4, !tbaa !33 + %mul80 = fmul fast float %19, %17 + %spec.select214 = select i1 %cmp44.1, i32 %3, i32 %.pn + %idxprom.1 = sext i32 %spec.select214 to i64 + %arrayidx.1 = getelementptr inbounds float, float* %Is, i64 %idxprom.1 + %20 = load float, float* %arrayidx.1, align 4, !tbaa !33 + %arrayidx71.1 = getelementptr inbounds float, float* %Sx, i64 1 + %21 = load float, float* %arrayidx71.1, align 4, !tbaa !33 + %mul72.1 = fmul fast float %21, %20 + %add73.1 = fadd fast float %mul72.1, %mul72 + %arrayidx79.1 = getelementptr inbounds float, float* %Sy, i64 1 + %22 = load float, float* %arrayidx79.1, align 4, !tbaa !33 + %mul80.1 = fmul fast float %22, %20 + %add81.1 = fadd fast float %mul80.1, %mul80 + %spec.select215 = select i1 %cmp55.2, i32 %loadOffset.0.2, i32 %conv63.2 + %loadOffset.1.2 = select i1 %cmp44.2, i32 %3, i32 %spec.select215 + %idxprom.2 = sext i32 %loadOffset.1.2 to i64 + br label %for.cond.cleanup7 + +for.body8.us156.preheader: ; preds = %for.cond5.preheader.split + %.pn.us165 = trunc i64 %add12 to i32 + %loadOffset.0.us166 = add i32 %.pn.us165, -1 + %spec.select = select i1 %cmp44.us168, i32 %6, i32 %loadOffset.0.us166 + %idxprom.us181 = sext i32 %spec.select to i64 + %arrayidx.us182 = getelementptr inbounds float, float* %Is, i64 %idxprom.us181 + %23 = load float, float* %arrayidx.us182, align 4, !tbaa !33 + %24 = load float, float* %Sx, align 4, !tbaa !33 + %mul72.us186 = fmul fast float %24, %23 + %25 = load float, float* %Sy, align 4, !tbaa !33 + %mul80.us189 = fmul fast float %25, %23 + %spec.select212 = select i1 %cmp44.us168.1, i32 %6, i32 %.pn.us165 + %idxprom.us181.1 = sext i32 %spec.select212 to i64 + %arrayidx.us182.1 = getelementptr inbounds float, float* %Is, i64 %idxprom.us181.1 + %26 = load float, float* %arrayidx.us182.1, align 4, !tbaa !33 + %arrayidx71.us185.1 = getelementptr inbounds float, float* %Sx, i64 1 + %27 = load float, float* %arrayidx71.us185.1, align 4, !tbaa !33 + %mul72.us186.1 = fmul fast float %27, %26 + %add73.us187.1 = fadd fast float %mul72.us186.1, %mul72.us186 + %arrayidx79.us188.1 = getelementptr inbounds float, float* %Sy, i64 1 + %28 = load float, float* %arrayidx79.us188.1, align 4, !tbaa !33 + %mul80.us189.1 = fmul fast float %28, %26 + %add81.us190.1 = fadd fast float %mul80.us189.1, %mul80.us189 + br i1 %cmp44.us168.2, label %if.end65.us179.2, label %if.else51.us169.2 + +for.cond.cleanup7: ; preds = %for.body8.preheader, %if.end65.us179.2, %for.body8.us.preheader + %idxprom.2.sink = phi i64 [ %idxprom.2, %for.body8.preheader ], [ %idxprom.us181.2, %if.end65.us179.2 ], [ %idxprom.us.2, %for.body8.us.preheader ] + %add73.1.sink = phi float [ %add73.1, %for.body8.preheader ], [ %add73.us187.1, %if.end65.us179.2 ], [ %add73.us.1, %for.body8.us.preheader ] + %add81.1.sink = phi float [ %add81.1, %for.body8.preheader ], [ %add81.us190.1, %if.end65.us179.2 ], [ %add81.us.1, %for.body8.us.preheader ] + %arrayidx.2 = getelementptr inbounds float, float* %Is, i64 %idxprom.2.sink + %29 = load float, float* %arrayidx.2, align 4, !tbaa !33 + %arrayidx71.2 = getelementptr inbounds float, float* %Sx, i64 2 + %30 = load float, float* %arrayidx71.2, align 4, !tbaa !33 + %mul72.2 = fmul fast float %30, %29 + %add73.2 = fadd fast float %mul72.2, %add73.1.sink + %arrayidx79.2 = getelementptr inbounds float, float* %Sy, i64 2 + %31 = load float, float* %arrayidx79.2, align 4, !tbaa !33 + %mul80.2 = fmul fast float %31, %29 + %add81.2 = fadd fast float %mul80.2, %add81.1.sink + %indvars.iv.next = mul i32 %4, %2 + %cmp18.1 = icmp slt i64 %call2, 0 + br i1 %cmp18.1, label %for.body8.us.preheader.1, label %for.cond5.preheader.split.1 + +if.end91: ; preds = %for.cond.cleanup7.2, %entry + tail call void (i32, ...) @__visc__return(i32 1, i64 %bytesG) + ret void + +if.else51.us169.2: ; preds = %for.body8.us156.preheader + %loadOffset.0.us166.2 = add i32 %.pn.us165, 1 + br i1 %cmp55.us170.2, label %if.end65.us179.2, label %if.then56.us171.2 + +if.then56.us171.2: ; preds = %if.else51.us169.2 + %32 = add i32 %9, %.pn.us165 + %conv63.us176.2 = add i32 %32, -1 + br label %if.end65.us179.2 + +if.end65.us179.2: ; preds = %for.body8.us156.preheader, %if.then56.us171.2, %if.else51.us169.2 + %loadOffset.1.us180.2 = phi i32 [ %conv63.us176.2, %if.then56.us171.2 ], [ %loadOffset.0.us166.2, %if.else51.us169.2 ], [ %6, %for.body8.us156.preheader ] + %idxprom.us181.2 = sext i32 %loadOffset.1.us180.2 to i64 + br label %for.cond.cleanup7 + +for.cond5.preheader.split.1: ; preds = %for.cond.cleanup7 + %cmp25.1 = icmp slt i64 %call2, %m + br i1 %cmp25.1, label %for.body8.us156.preheader.1, label %for.body8.preheader.1 + +for.body8.preheader.1: ; preds = %for.cond5.preheader.split.1 + %loadOffset.1.1 = select i1 %cmp44, i32 %3, i32 %loadOffset.0 + %idxprom.1221 = sext i32 %loadOffset.1.1 to i64 + %arrayidx.1222 = getelementptr inbounds float, float* %Is, i64 %idxprom.1221 + %33 = load float, float* %arrayidx.1222, align 4, !tbaa !33 + %arrayidx71.1223 = getelementptr inbounds float, float* %Sx, i64 3 + %34 = load float, float* %arrayidx71.1223, align 4, !tbaa !33 + %mul72.1224 = fmul fast float %34, %33 + %add73.1225 = fadd fast float %mul72.1224, %add73.2 + %arrayidx79.1226 = getelementptr inbounds float, float* %Sy, i64 3 + %35 = load float, float* %arrayidx79.1226, align 4, !tbaa !33 + %mul80.1227 = fmul fast float %35, %33 + %add81.1228 = fadd fast float %mul80.1227, %add81.2 + %spec.select214.1 = select i1 %cmp44.1, i32 %3, i32 %.pn + %idxprom.1.1 = sext i32 %spec.select214.1 to i64 + %arrayidx.1.1 = getelementptr inbounds float, float* %Is, i64 %idxprom.1.1 + %36 = load float, float* %arrayidx.1.1, align 4, !tbaa !33 + %arrayidx71.1.1 = getelementptr inbounds float, float* %Sx, i64 4 + %37 = load float, float* %arrayidx71.1.1, align 4, !tbaa !33 + %mul72.1.1 = fmul fast float %37, %36 + %add73.1.1 = fadd fast float %mul72.1.1, %add73.1225 + %arrayidx79.1.1 = getelementptr inbounds float, float* %Sy, i64 4 + %38 = load float, float* %arrayidx79.1.1, align 4, !tbaa !33 + %mul80.1.1 = fmul fast float %38, %36 + %add81.1.1 = fadd fast float %mul80.1.1, %add81.1228 + %spec.select215.1 = select i1 %cmp55.2, i32 %loadOffset.0.2, i32 %conv63.2 + %loadOffset.1.2.1 = select i1 %cmp44.2, i32 %3, i32 %spec.select215.1 + %idxprom.2.1 = sext i32 %loadOffset.1.2.1 to i64 + br label %for.cond.cleanup7.1 + +for.body8.us156.preheader.1: ; preds = %for.cond5.preheader.split.1 + %.pn.us165.1 = trunc i64 %add to i32 + %loadOffset.0.us166.1 = add i32 %.pn.us165.1, -1 + %spec.select.1 = select i1 %cmp44.us168, i32 %indvars.iv.next, i32 %loadOffset.0.us166.1 + %idxprom.us181.1229 = sext i32 %spec.select.1 to i64 + %arrayidx.us182.1230 = getelementptr inbounds float, float* %Is, i64 %idxprom.us181.1229 + %39 = load float, float* %arrayidx.us182.1230, align 4, !tbaa !33 + %arrayidx71.us185.1231 = getelementptr inbounds float, float* %Sx, i64 3 + %40 = load float, float* %arrayidx71.us185.1231, align 4, !tbaa !33 + %mul72.us186.1232 = fmul fast float %40, %39 + %add73.us187.1233 = fadd fast float %mul72.us186.1232, %add73.2 + %arrayidx79.us188.1234 = getelementptr inbounds float, float* %Sy, i64 3 + %41 = load float, float* %arrayidx79.us188.1234, align 4, !tbaa !33 + %mul80.us189.1235 = fmul fast float %41, %39 + %add81.us190.1236 = fadd fast float %mul80.us189.1235, %add81.2 + %spec.select212.1 = select i1 %cmp44.us168.1, i32 %indvars.iv.next, i32 %.pn.us165.1 + %idxprom.us181.1.1 = sext i32 %spec.select212.1 to i64 + %arrayidx.us182.1.1 = getelementptr inbounds float, float* %Is, i64 %idxprom.us181.1.1 + %42 = load float, float* %arrayidx.us182.1.1, align 4, !tbaa !33 + %arrayidx71.us185.1.1 = getelementptr inbounds float, float* %Sx, i64 4 + %43 = load float, float* %arrayidx71.us185.1.1, align 4, !tbaa !33 + %mul72.us186.1.1 = fmul fast float %43, %42 + %add73.us187.1.1 = fadd fast float %mul72.us186.1.1, %add73.us187.1233 + %arrayidx79.us188.1.1 = getelementptr inbounds float, float* %Sy, i64 4 + %44 = load float, float* %arrayidx79.us188.1.1, align 4, !tbaa !33 + %mul80.us189.1.1 = fmul fast float %44, %42 + %add81.us190.1.1 = fadd fast float %mul80.us189.1.1, %add81.us190.1236 + br i1 %cmp44.us168.2, label %if.end65.us179.2.1, label %if.else51.us169.2.1 + +if.else51.us169.2.1: ; preds = %for.body8.us156.preheader.1 + %loadOffset.0.us166.2.1 = add i32 %.pn.us165.1, 1 + br i1 %cmp55.us170.2, label %if.end65.us179.2.1, label %if.then56.us171.2.1 + +if.then56.us171.2.1: ; preds = %if.else51.us169.2.1 + %45 = add i32 %9, %.pn.us165.1 + %conv63.us176.2.1 = add i32 %45, -1 + br label %if.end65.us179.2.1 + +if.end65.us179.2.1: ; preds = %if.then56.us171.2.1, %if.else51.us169.2.1, %for.body8.us156.preheader.1 + %loadOffset.1.us180.2.1 = phi i32 [ %conv63.us176.2.1, %if.then56.us171.2.1 ], [ %loadOffset.0.us166.2.1, %if.else51.us169.2.1 ], [ %indvars.iv.next, %for.body8.us156.preheader.1 ] + %idxprom.us181.2.1 = sext i32 %loadOffset.1.us180.2.1 to i64 + br label %for.cond.cleanup7.1 + +for.body8.us.preheader.1: ; preds = %for.cond.cleanup7 + %loadOffset.0.us.1 = shl i64 %call1, 32 + %loadOffset.0.us.op.1 = add i64 %loadOffset.0.us.1, -4294967296 + %loadOffset.0.us.op.op.1 = ashr exact i64 %loadOffset.0.us.op.1, 32 + %idxprom.us.1237 = select i1 %cmp44.us, i64 0, i64 %loadOffset.0.us.op.op.1 + %arrayidx.us.1238 = getelementptr inbounds float, float* %Is, i64 %idxprom.us.1237 + %46 = load float, float* %arrayidx.us.1238, align 4, !tbaa !33 + %arrayidx71.us.1239 = getelementptr inbounds float, float* %Sx, i64 3 + %47 = load float, float* %arrayidx71.us.1239, align 4, !tbaa !33 + %mul72.us.1240 = fmul fast float %47, %46 + %add73.us.1241 = fadd fast float %mul72.us.1240, %add73.2 + %arrayidx79.us.1242 = getelementptr inbounds float, float* %Sy, i64 3 + %48 = load float, float* %arrayidx79.us.1242, align 4, !tbaa !33 + %mul80.us.1243 = fmul fast float %48, %46 + %add81.us.1244 = fadd fast float %mul80.us.1243, %add81.2 + %49 = icmp sgt i64 %call1, 0 + %spec.select211.1 = select i1 %49, i64 %call1, i64 0 + %sext209.1 = shl i64 %spec.select211.1, 32 + %idxprom.us.1.1 = ashr exact i64 %sext209.1, 32 + %arrayidx.us.1.1 = getelementptr inbounds float, float* %Is, i64 %idxprom.us.1.1 + %50 = load float, float* %arrayidx.us.1.1, align 4, !tbaa !33 + %arrayidx71.us.1.1 = getelementptr inbounds float, float* %Sx, i64 4 + %51 = load float, float* %arrayidx71.us.1.1, align 4, !tbaa !33 + %mul72.us.1.1 = fmul fast float %51, %50 + %add73.us.1.1 = fadd fast float %mul72.us.1.1, %add73.us.1241 + %arrayidx79.us.1.1 = getelementptr inbounds float, float* %Sy, i64 4 + %52 = load float, float* %arrayidx79.us.1.1, align 4, !tbaa !33 + %mul80.us.1.1 = fmul fast float %52, %50 + %add81.us.1.1 = fadd fast float %mul80.us.1.1, %add81.us.1244 + %spec.select216.1 = select i1 %cmp55.us.2, i64 %loadOffset.0.us.2, i64 %conv63.us.2 + %spec.select216.op.1 = shl i64 %spec.select216.1, 32 + %spec.select216.op.op.1 = ashr exact i64 %spec.select216.op.1, 32 + %idxprom.us.2.1 = select i1 %cmp44.us.2, i64 0, i64 %spec.select216.op.op.1 + br label %for.cond.cleanup7.1 + +for.cond.cleanup7.1: ; preds = %for.body8.us.preheader.1, %if.end65.us179.2.1, %for.body8.preheader.1 + %idxprom.2.sink.1 = phi i64 [ %idxprom.2.1, %for.body8.preheader.1 ], [ %idxprom.us181.2.1, %if.end65.us179.2.1 ], [ %idxprom.us.2.1, %for.body8.us.preheader.1 ] + %add73.1.sink.1 = phi float [ %add73.1.1, %for.body8.preheader.1 ], [ %add73.us187.1.1, %if.end65.us179.2.1 ], [ %add73.us.1.1, %for.body8.us.preheader.1 ] + %add81.1.sink.1 = phi float [ %add81.1.1, %for.body8.preheader.1 ], [ %add81.us190.1.1, %if.end65.us179.2.1 ], [ %add81.us.1.1, %for.body8.us.preheader.1 ] + %arrayidx.2.1 = getelementptr inbounds float, float* %Is, i64 %idxprom.2.sink.1 + %53 = load float, float* %arrayidx.2.1, align 4, !tbaa !33 + %arrayidx71.2.1 = getelementptr inbounds float, float* %Sx, i64 5 + %54 = load float, float* %arrayidx71.2.1, align 4, !tbaa !33 + %mul72.2.1 = fmul fast float %54, %53 + %add73.2.1 = fadd fast float %mul72.2.1, %add73.1.sink.1 + %arrayidx79.2.1 = getelementptr inbounds float, float* %Sy, i64 5 + %55 = load float, float* %arrayidx79.2.1, align 4, !tbaa !33 + %mul80.2.1 = fmul fast float %55, %53 + %add81.2.1 = fadd fast float %mul80.2.1, %add81.1.sink.1 + %indvars.iv.next.1 = add i32 %indvars.iv.next, %2 + %add17.2 = add nsw i64 %call2, 1 + %cmp18.2 = icmp slt i64 %add17.2, 0 + %add12.2 = add i64 %add, %n + br i1 %cmp18.2, label %for.body8.us.preheader.2, label %for.cond5.preheader.split.2 + +for.cond5.preheader.split.2: ; preds = %for.cond.cleanup7.1 + %cmp25.2 = icmp slt i64 %add17.2, %m + br i1 %cmp25.2, label %for.body8.us156.preheader.2, label %for.body8.preheader.2 + +for.body8.preheader.2: ; preds = %for.cond5.preheader.split.2 + %loadOffset.1.2245 = select i1 %cmp44, i32 %3, i32 %loadOffset.0 + %idxprom.2246 = sext i32 %loadOffset.1.2245 to i64 + %arrayidx.2247 = getelementptr inbounds float, float* %Is, i64 %idxprom.2246 + %56 = load float, float* %arrayidx.2247, align 4, !tbaa !33 + %arrayidx71.2248 = getelementptr inbounds float, float* %Sx, i64 6 + %57 = load float, float* %arrayidx71.2248, align 4, !tbaa !33 + %mul72.2249 = fmul fast float %57, %56 + %add73.2250 = fadd fast float %mul72.2249, %add73.2.1 + %arrayidx79.2251 = getelementptr inbounds float, float* %Sy, i64 6 + %58 = load float, float* %arrayidx79.2251, align 4, !tbaa !33 + %mul80.2252 = fmul fast float %58, %56 + %add81.2253 = fadd fast float %mul80.2252, %add81.2.1 + %spec.select214.2 = select i1 %cmp44.1, i32 %3, i32 %.pn + %idxprom.1.2 = sext i32 %spec.select214.2 to i64 + %arrayidx.1.2 = getelementptr inbounds float, float* %Is, i64 %idxprom.1.2 + %59 = load float, float* %arrayidx.1.2, align 4, !tbaa !33 + %arrayidx71.1.2 = getelementptr inbounds float, float* %Sx, i64 7 + %60 = load float, float* %arrayidx71.1.2, align 4, !tbaa !33 + %mul72.1.2 = fmul fast float %60, %59 + %add73.1.2 = fadd fast float %mul72.1.2, %add73.2250 + %arrayidx79.1.2 = getelementptr inbounds float, float* %Sy, i64 7 + %61 = load float, float* %arrayidx79.1.2, align 4, !tbaa !33 + %mul80.1.2 = fmul fast float %61, %59 + %add81.1.2 = fadd fast float %mul80.1.2, %add81.2253 + %spec.select215.2 = select i1 %cmp55.2, i32 %loadOffset.0.2, i32 %conv63.2 + %loadOffset.1.2.2 = select i1 %cmp44.2, i32 %3, i32 %spec.select215.2 + %idxprom.2.2 = sext i32 %loadOffset.1.2.2 to i64 + br label %for.cond.cleanup7.2 + +for.body8.us156.preheader.2: ; preds = %for.cond5.preheader.split.2 + %.pn.us165.2 = trunc i64 %add12.2 to i32 + %loadOffset.0.us166.2254 = add i32 %.pn.us165.2, -1 + %spec.select.2 = select i1 %cmp44.us168, i32 %indvars.iv.next.1, i32 %loadOffset.0.us166.2254 + %idxprom.us181.2255 = sext i32 %spec.select.2 to i64 + %arrayidx.us182.2 = getelementptr inbounds float, float* %Is, i64 %idxprom.us181.2255 + %62 = load float, float* %arrayidx.us182.2, align 4, !tbaa !33 + %arrayidx71.us185.2 = getelementptr inbounds float, float* %Sx, i64 6 + %63 = load float, float* %arrayidx71.us185.2, align 4, !tbaa !33 + %mul72.us186.2 = fmul fast float %63, %62 + %add73.us187.2 = fadd fast float %mul72.us186.2, %add73.2.1 + %arrayidx79.us188.2 = getelementptr inbounds float, float* %Sy, i64 6 + %64 = load float, float* %arrayidx79.us188.2, align 4, !tbaa !33 + %mul80.us189.2 = fmul fast float %64, %62 + %add81.us190.2 = fadd fast float %mul80.us189.2, %add81.2.1 + %spec.select212.2 = select i1 %cmp44.us168.1, i32 %indvars.iv.next.1, i32 %.pn.us165.2 + %idxprom.us181.1.2 = sext i32 %spec.select212.2 to i64 + %arrayidx.us182.1.2 = getelementptr inbounds float, float* %Is, i64 %idxprom.us181.1.2 + %65 = load float, float* %arrayidx.us182.1.2, align 4, !tbaa !33 + %arrayidx71.us185.1.2 = getelementptr inbounds float, float* %Sx, i64 7 + %66 = load float, float* %arrayidx71.us185.1.2, align 4, !tbaa !33 + %mul72.us186.1.2 = fmul fast float %66, %65 + %add73.us187.1.2 = fadd fast float %mul72.us186.1.2, %add73.us187.2 + %arrayidx79.us188.1.2 = getelementptr inbounds float, float* %Sy, i64 7 + %67 = load float, float* %arrayidx79.us188.1.2, align 4, !tbaa !33 + %mul80.us189.1.2 = fmul fast float %67, %65 + %add81.us190.1.2 = fadd fast float %mul80.us189.1.2, %add81.us190.2 + br i1 %cmp44.us168.2, label %if.end65.us179.2.2, label %if.else51.us169.2.2 + +if.else51.us169.2.2: ; preds = %for.body8.us156.preheader.2 + %loadOffset.0.us166.2.2 = add i32 %.pn.us165.2, 1 + br i1 %cmp55.us170.2, label %if.end65.us179.2.2, label %if.then56.us171.2.2 + +if.then56.us171.2.2: ; preds = %if.else51.us169.2.2 + %68 = add i32 %9, %.pn.us165.2 + %conv63.us176.2.2 = add i32 %68, -1 + br label %if.end65.us179.2.2 + +if.end65.us179.2.2: ; preds = %if.then56.us171.2.2, %if.else51.us169.2.2, %for.body8.us156.preheader.2 + %loadOffset.1.us180.2.2 = phi i32 [ %conv63.us176.2.2, %if.then56.us171.2.2 ], [ %loadOffset.0.us166.2.2, %if.else51.us169.2.2 ], [ %indvars.iv.next.1, %for.body8.us156.preheader.2 ] + %idxprom.us181.2.2 = sext i32 %loadOffset.1.us180.2.2 to i64 + br label %for.cond.cleanup7.2 + +for.body8.us.preheader.2: ; preds = %for.cond.cleanup7.1 + %loadOffset.0.us.2256 = shl i64 %call1, 32 + %loadOffset.0.us.op.2 = add i64 %loadOffset.0.us.2256, -4294967296 + %loadOffset.0.us.op.op.2 = ashr exact i64 %loadOffset.0.us.op.2, 32 + %idxprom.us.2257 = select i1 %cmp44.us, i64 0, i64 %loadOffset.0.us.op.op.2 + %arrayidx.us.2 = getelementptr inbounds float, float* %Is, i64 %idxprom.us.2257 + %69 = load float, float* %arrayidx.us.2, align 4, !tbaa !33 + %arrayidx71.us.2 = getelementptr inbounds float, float* %Sx, i64 6 + %70 = load float, float* %arrayidx71.us.2, align 4, !tbaa !33 + %mul72.us.2 = fmul fast float %70, %69 + %add73.us.2 = fadd fast float %mul72.us.2, %add73.2.1 + %arrayidx79.us.2 = getelementptr inbounds float, float* %Sy, i64 6 + %71 = load float, float* %arrayidx79.us.2, align 4, !tbaa !33 + %mul80.us.2 = fmul fast float %71, %69 + %add81.us.2 = fadd fast float %mul80.us.2, %add81.2.1 + %72 = icmp sgt i64 %call1, 0 + %spec.select211.2 = select i1 %72, i64 %call1, i64 0 + %sext209.2 = shl i64 %spec.select211.2, 32 + %idxprom.us.1.2 = ashr exact i64 %sext209.2, 32 + %arrayidx.us.1.2 = getelementptr inbounds float, float* %Is, i64 %idxprom.us.1.2 + %73 = load float, float* %arrayidx.us.1.2, align 4, !tbaa !33 + %arrayidx71.us.1.2 = getelementptr inbounds float, float* %Sx, i64 7 + %74 = load float, float* %arrayidx71.us.1.2, align 4, !tbaa !33 + %mul72.us.1.2 = fmul fast float %74, %73 + %add73.us.1.2 = fadd fast float %mul72.us.1.2, %add73.us.2 + %arrayidx79.us.1.2 = getelementptr inbounds float, float* %Sy, i64 7 + %75 = load float, float* %arrayidx79.us.1.2, align 4, !tbaa !33 + %mul80.us.1.2 = fmul fast float %75, %73 + %add81.us.1.2 = fadd fast float %mul80.us.1.2, %add81.us.2 + %spec.select216.2 = select i1 %cmp55.us.2, i64 %loadOffset.0.us.2, i64 %conv63.us.2 + %spec.select216.op.2 = shl i64 %spec.select216.2, 32 + %spec.select216.op.op.2 = ashr exact i64 %spec.select216.op.2, 32 + %idxprom.us.2.2 = select i1 %cmp44.us.2, i64 0, i64 %spec.select216.op.op.2 + br label %for.cond.cleanup7.2 + +for.cond.cleanup7.2: ; preds = %for.body8.us.preheader.2, %if.end65.us179.2.2, %for.body8.preheader.2 + %idxprom.2.sink.2 = phi i64 [ %idxprom.2.2, %for.body8.preheader.2 ], [ %idxprom.us181.2.2, %if.end65.us179.2.2 ], [ %idxprom.us.2.2, %for.body8.us.preheader.2 ] + %add73.1.sink.2 = phi float [ %add73.1.2, %for.body8.preheader.2 ], [ %add73.us187.1.2, %if.end65.us179.2.2 ], [ %add73.us.1.2, %for.body8.us.preheader.2 ] + %add81.1.sink.2 = phi float [ %add81.1.2, %for.body8.preheader.2 ], [ %add81.us190.1.2, %if.end65.us179.2.2 ], [ %add81.us.1.2, %for.body8.us.preheader.2 ] + %arrayidx.2.2 = getelementptr inbounds float, float* %Is, i64 %idxprom.2.sink.2 + %76 = load float, float* %arrayidx.2.2, align 4, !tbaa !33 + %arrayidx71.2.2 = getelementptr inbounds float, float* %Sx, i64 8 + %77 = load float, float* %arrayidx71.2.2, align 4, !tbaa !33 + %mul72.2.2 = fmul fast float %77, %76 + %add73.2.2 = fadd fast float %mul72.2.2, %add73.1.sink.2 + %arrayidx79.2.2 = getelementptr inbounds float, float* %Sy, i64 8 + %78 = load float, float* %arrayidx79.2.2, align 4, !tbaa !33 + %mul80.2.2 = fmul fast float %78, %76 + %add81.2.2 = fadd fast float %mul80.2.2, %add81.1.sink.2 + %mul85 = fmul fast float %add73.2.2, %add73.2.2 + %mul86 = fmul fast float %add81.2.2, %add81.2.2 + %add87 = fadd fast float %mul85, %mul86 + %79 = tail call fast float @llvm.sqrt.f32(float %add87) #16 + %sext = shl i64 %add, 32 + %idxprom89 = ashr exact i64 %sext, 32 + %arrayidx90 = getelementptr inbounds float, float* %G, i64 %idxprom89 + store float %79, float* %arrayidx90, align 4, !tbaa !33 + br label %if.end91 +} + +; Function Attrs: uwtable +define dso_local void @WrapperComputeGradient(float* %Is, i64 %bytesIs, float* %Sx, i64 %bytesSx, float* %Sy, i64 %bytesSy, float* %G, i64 %bytesG, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 3, float* %Is, float* %Sx, float* %Sy, i32 1, float* %G) + %call = tail call i8* (i32, ...) @__visc__createNodeND(i32 2, void (float*, i64, float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @computeGradient, i64 %m, i64 %n) + tail call void @__visc__bindIn(i8* %call, i32 0, i32 0, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 1, i32 1, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 2, i32 2, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 3, i32 3, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 4, i32 4, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 5, i32 5, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 6, i32 6, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 7, i32 7, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 8, i32 8, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 9, i32 9, i32 0) + tail call void @__visc__bindOut(i8* %call, i32 0, i32 0, i32 0) + ret void +} + +; Function Attrs: uwtable +define dso_local void @computeMaxGradientLeaf(float* %G, i64 %bytesG, float* %maxG, i64 %bytesMaxG, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 1, float* %G, i32 1, float* %maxG) + %call = tail call i8* @__visc__getNode() + %call1 = tail call i64 @__visc__getNodeInstanceID_x(i8* %call) + %call2 = tail call i64 @__visc__getNumNodeInstances_x(i8* %call) + %i.0.in76 = add nsw i64 %call1, %call2 + %sext77 = shl i64 %i.0.in76, 32 + %conv378 = ashr exact i64 %sext77, 32 + %mul = mul nsw i64 %n, %m + %cmp79 = icmp slt i64 %conv378, %mul + br i1 %cmp79, label %for.body.lr.ph, label %for.cond.cleanup + +for.body.lr.ph: ; preds = %entry + %arrayidx = getelementptr inbounds float, float* %G, i64 %call1 + %.pre = load float, float* %arrayidx, align 4, !tbaa !33 + br label %for.body + +for.cond.cleanup: ; preds = %for.inc, %entry + %cmp13 = icmp slt i64 %call2, %mul + %call2.mul = select i1 %cmp13, i64 %call2, i64 %mul + %cmp15 = icmp eq i64 %call1, 0 + br i1 %cmp15, label %for.cond18.preheader, label %if.end35 + +for.cond18.preheader: ; preds = %for.cond.cleanup + %cmp2073 = icmp sgt i64 %call2.mul, 1 + br i1 %cmp2073, label %for.body22.preheader, label %for.cond18.preheader.for.cond.cleanup21_crit_edge + +for.cond18.preheader.for.cond.cleanup21_crit_edge: ; preds = %for.cond18.preheader + %.phi.trans.insert = bitcast float* %G to i32* + %.pre82 = load i32, i32* %.phi.trans.insert, align 4, !tbaa !33 + br label %for.cond.cleanup21 + +for.body22.preheader: ; preds = %for.cond18.preheader + %.pre81 = load float, float* %G, align 4, !tbaa !33 + %0 = bitcast float %.pre81 to i32 + %1 = add i64 %call2.mul, -1 + %xtraiter = and i64 %1, 1 + %2 = icmp eq i64 %call2.mul, 2 + br i1 %2, label %for.cond.cleanup21.loopexit.unr-lcssa, label %for.body22.preheader.new + +for.body22.preheader.new: ; preds = %for.body22.preheader + %unroll_iter = sub i64 %1, %xtraiter + br label %for.body22 + +for.body: ; preds = %for.body.lr.ph, %for.inc + %3 = phi float [ %.pre, %for.body.lr.ph ], [ %5, %for.inc ] + %conv380 = phi i64 [ %conv378, %for.body.lr.ph ], [ %conv3, %for.inc ] + %arrayidx4 = getelementptr inbounds float, float* %G, i64 %conv380 + %4 = load float, float* %arrayidx4, align 4, !tbaa !33 + %cmp5 = fcmp fast olt float %3, %4 + br i1 %cmp5, label %if.then, label %for.inc + +if.then: ; preds = %for.body + store float %4, float* %arrayidx, align 4, !tbaa !33 + br label %for.inc + +for.inc: ; preds = %for.body, %if.then + %5 = phi float [ %3, %for.body ], [ %4, %if.then ] + %i.0.in = add nsw i64 %conv380, %call2 + %sext = shl i64 %i.0.in, 32 + %conv3 = ashr exact i64 %sext, 32 + %cmp = icmp slt i64 %conv3, %mul + br i1 %cmp, label %for.body, label %for.cond.cleanup + +for.cond.cleanup21.loopexit.unr-lcssa: ; preds = %for.inc32.1, %for.body22.preheader + %.lcssa.ph = phi i32 [ undef, %for.body22.preheader ], [ %18, %for.inc32.1 ] + %.unr = phi i32 [ %0, %for.body22.preheader ], [ %18, %for.inc32.1 ] + %.unr84 = phi float [ %.pre81, %for.body22.preheader ], [ %19, %for.inc32.1 ] + %indvars.iv.unr = phi i64 [ 1, %for.body22.preheader ], [ %indvars.iv.next.1, %for.inc32.1 ] + %lcmp.mod = icmp eq i64 %xtraiter, 0 + br i1 %lcmp.mod, label %for.cond.cleanup21, label %for.body22.epil + +for.body22.epil: ; preds = %for.cond.cleanup21.loopexit.unr-lcssa + %arrayidx25.epil = getelementptr inbounds float, float* %G, i64 %indvars.iv.unr + %6 = load float, float* %arrayidx25.epil, align 4, !tbaa !33 + %cmp26.epil = fcmp fast olt float %.unr84, %6 + br i1 %cmp26.epil, label %if.then27.epil, label %for.cond.cleanup21 + +if.then27.epil: ; preds = %for.body22.epil + store float %6, float* %G, align 4, !tbaa !33 + %7 = bitcast float %6 to i32 + br label %for.cond.cleanup21 + +for.cond.cleanup21: ; preds = %for.cond.cleanup21.loopexit.unr-lcssa, %for.body22.epil, %if.then27.epil, %for.cond18.preheader.for.cond.cleanup21_crit_edge + %8 = phi i32 [ %.pre82, %for.cond18.preheader.for.cond.cleanup21_crit_edge ], [ %.lcssa.ph, %for.cond.cleanup21.loopexit.unr-lcssa ], [ %.unr, %for.body22.epil ], [ %7, %if.then27.epil ] + %9 = bitcast float* %maxG to i32* + store i32 %8, i32* %9, align 4, !tbaa !33 + br label %if.end35 + +for.body22: ; preds = %for.inc32.1, %for.body22.preheader.new + %10 = phi i32 [ %0, %for.body22.preheader.new ], [ %18, %for.inc32.1 ] + %11 = phi float [ %.pre81, %for.body22.preheader.new ], [ %19, %for.inc32.1 ] + %indvars.iv = phi i64 [ 1, %for.body22.preheader.new ], [ %indvars.iv.next.1, %for.inc32.1 ] + %niter = phi i64 [ %unroll_iter, %for.body22.preheader.new ], [ %niter.nsub.1, %for.inc32.1 ] + %arrayidx25 = getelementptr inbounds float, float* %G, i64 %indvars.iv + %12 = load float, float* %arrayidx25, align 4, !tbaa !33 + %cmp26 = fcmp fast olt float %11, %12 + br i1 %cmp26, label %if.then27, label %for.inc32 + +if.then27: ; preds = %for.body22 + store float %12, float* %G, align 4, !tbaa !33 + %13 = bitcast float %12 to i32 + br label %for.inc32 + +for.inc32: ; preds = %for.body22, %if.then27 + %14 = phi i32 [ %10, %for.body22 ], [ %13, %if.then27 ] + %15 = phi float [ %11, %for.body22 ], [ %12, %if.then27 ] + %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 + %arrayidx25.1 = getelementptr inbounds float, float* %G, i64 %indvars.iv.next + %16 = load float, float* %arrayidx25.1, align 4, !tbaa !33 + %cmp26.1 = fcmp fast olt float %15, %16 + br i1 %cmp26.1, label %if.then27.1, label %for.inc32.1 + +if.end35: ; preds = %for.cond.cleanup21, %for.cond.cleanup + tail call void (i32, ...) @__visc__return(i32 1, i64 %bytesMaxG) + ret void + +if.then27.1: ; preds = %for.inc32 + store float %16, float* %G, align 4, !tbaa !33 + %17 = bitcast float %16 to i32 + br label %for.inc32.1 + +for.inc32.1: ; preds = %if.then27.1, %for.inc32 + %18 = phi i32 [ %14, %for.inc32 ], [ %17, %if.then27.1 ] + %19 = phi float [ %15, %for.inc32 ], [ %16, %if.then27.1 ] + %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv, 2 + %niter.nsub.1 = add i64 %niter, -2 + %niter.ncmp.1 = icmp eq i64 %niter.nsub.1, 0 + br i1 %niter.ncmp.1, label %for.cond.cleanup21.loopexit.unr-lcssa, label %for.body22 +} + +declare dso_local i64 @__visc__getNumNodeInstances_x(i8*) local_unnamed_addr #0 + +; Function Attrs: uwtable +define dso_local void @computeMaxGradientTB(float* %G, i64 %bytesG, float* %maxG, i64 %bytesMaxG, i64 %m, i64 %n, i64 %block_x) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 2, float* %G, float* %maxG, i32 1, float* %maxG) + %call = tail call i8* (i32, ...) @__visc__createNodeND(i32 1, void (float*, i64, float*, i64, i64, i64)* nonnull @computeMaxGradientLeaf, i64 %block_x) + tail call void @__visc__bindIn(i8* %call, i32 0, i32 0, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 1, i32 1, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 2, i32 2, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 3, i32 3, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 4, i32 4, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 5, i32 5, i32 0) + tail call void @__visc__bindOut(i8* %call, i32 0, i32 0, i32 0) + ret void +} + +; Function Attrs: uwtable +define dso_local void @WrapperComputeMaxGradient(float* %G, i64 %bytesG, float* %maxG, i64 %bytesMaxG, i64 %m, i64 %n, i64 %block_x, i64 %grid_x) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 2, float* %G, float* %maxG, i32 1, float* %maxG) + %call = tail call i8* (i32, ...) @__visc__createNodeND(i32 1, void (float*, i64, float*, i64, i64, i64, i64)* nonnull @computeMaxGradientTB, i64 %grid_x) + tail call void @__visc__bindIn(i8* %call, i32 0, i32 0, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 1, i32 1, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 2, i32 2, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 3, i32 3, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 4, i32 4, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 5, i32 5, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 6, i32 6, i32 0) + tail call void @__visc__bindOut(i8* %call, i32 0, i32 0, i32 0) + ret void +} + +; Function Attrs: uwtable +define dso_local void @rejectZeroCrossings(float* %S, i64 %bytesS, float* %G, i64 %bytesG, float* %maxG, i64 %bytesMaxG, float* %E, i64 %bytesE, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 3, float* %S, float* %G, float* %maxG, i32 1, float* %E) + %call = tail call i8* @__visc__getNode() + %call1 = tail call i64 @__visc__getNodeInstanceID_x(i8* %call) + %call2 = tail call i64 @__visc__getNodeInstanceID_y(i8* %call) + %0 = load float, float* %maxG, align 4, !tbaa !33 + %sext = shl i64 %call1, 32 + %conv4 = ashr exact i64 %sext, 32 + %cmp = icmp slt i64 %conv4, %n + br i1 %cmp, label %land.lhs.true, label %if.end + +land.lhs.true: ; preds = %entry + %sext44 = shl i64 %call2, 32 + %conv5 = ashr exact i64 %sext44, 32 + %cmp6 = icmp slt i64 %conv5, %m + br i1 %cmp6, label %if.then, label %if.end + +if.then: ; preds = %land.lhs.true + %mul = mul nsw i64 %conv5, %n + %add = add nsw i64 %mul, %conv4 + %arrayidx = getelementptr inbounds float, float* %S, i64 %add + %1 = load float, float* %arrayidx, align 4, !tbaa !33 + %cmp10 = fcmp fast ogt float %1, 0.000000e+00 + br i1 %cmp10, label %land.rhs, label %land.end + +land.rhs: ; preds = %if.then + %arrayidx15 = getelementptr inbounds float, float* %G, i64 %add + %2 = load float, float* %arrayidx15, align 4, !tbaa !33 + %conv16 = fpext float %2 to double + %conv17 = fpext float %0 to double + %mul18 = fmul fast double %conv17, 1.000000e-01 + %cmp19 = fcmp fast olt double %mul18, %conv16 + %phitmp = select i1 %cmp19, double 1.000000e+00, double 0.000000e+00 + %phitmp45 = fptrunc double %phitmp to float + br label %land.end + +land.end: ; preds = %land.rhs, %if.then + %3 = phi float [ 0.000000e+00, %if.then ], [ %phitmp45, %land.rhs ] + %arrayidx25 = getelementptr inbounds float, float* %E, i64 %add + store float %3, float* %arrayidx25, align 4, !tbaa !33 + br label %if.end + +if.end: ; preds = %land.end, %land.lhs.true, %entry + tail call void (i32, ...) @__visc__return(i32 1, i64 %bytesE) + ret void +} + +; Function Attrs: uwtable +define dso_local void @WrapperRejectZeroCrossings(float* %S, i64 %bytesS, float* %G, i64 %bytesG, float* %maxG, i64 %bytesMaxG, float* %E, i64 %bytesE, i64 %m, i64 %n) #6 { +entry: + tail call void @__visc__hint(i32 1) + tail call void (i32, ...) @__visc__attributes(i32 3, float* %S, float* %G, float* %maxG, i32 1, float* %E) + %call = tail call i8* (i32, ...) @__visc__createNodeND(i32 2, void (float*, i64, float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @rejectZeroCrossings, i64 %m, i64 %n) + tail call void @__visc__bindIn(i8* %call, i32 0, i32 0, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 1, i32 1, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 2, i32 2, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 3, i32 3, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 4, i32 4, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 5, i32 5, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 6, i32 6, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 7, i32 7, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 8, i32 8, i32 0) + tail call void @__visc__bindIn(i8* %call, i32 9, i32 9, i32 0) + tail call void @__visc__bindOut(i8* %call, i32 0, i32 0, i32 0) + ret void +} + +; Function Attrs: uwtable +define dso_local void @edgeDetection(float* %I, i64 %bytesI, float* %Is, i64 %bytesIs, float* %L, i64 %bytesL, float* %S, i64 %bytesS, float* %G, i64 %bytesG, float* %maxG, i64 %bytesMaxG, float* %E, i64 %bytesE, float* %Gs, i64 %bytesGs, float* %B, i64 %bytesB, float* %Sx, i64 %bytesSx, float* %Sy, i64 %bytesSy, i64 %m, i64 %n, i64 %block_x, i64 %grid_x) #6 { +entry: + tail call void (i32, ...) @__visc__attributes(i32 5, float* %I, float* %Gs, float* %B, float* %Sx, float* %Sy, i32 6, float* %Is, float* %L, float* %S, float* %G, float* %maxG, float* %E) + tail call void @__visc__hint(i32 1) + %call = tail call i8* (i32, ...) @__visc__createNodeND(i32 0, void (float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @WrapperGaussianSmoothing) + %call1 = tail call i8* (i32, ...) @__visc__createNodeND(i32 0, void (float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @WrapperlaplacianEstimate) + %call2 = tail call i8* (i32, ...) @__visc__createNodeND(i32 0, void (float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @WrapperComputeZeroCrossings) + %call3 = tail call i8* (i32, ...) @__visc__createNodeND(i32 0, void (float*, i64, float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @WrapperComputeGradient) + %call4 = tail call i8* (i32, ...) @__visc__createNodeND(i32 0, void (float*, i64, float*, i64, i64, i64, i64, i64)* nonnull @WrapperComputeMaxGradient) + %call5 = tail call i8* (i32, ...) @__visc__createNodeND(i32 0, void (float*, i64, float*, i64, float*, i64, float*, i64, i64, i64)* nonnull @WrapperRejectZeroCrossings) + tail call void @__visc__bindIn(i8* %call, i32 0, i32 0, i32 1) + tail call void @__visc__bindIn(i8* %call, i32 1, i32 1, i32 1) + tail call void @__visc__bindIn(i8* %call, i32 14, i32 2, i32 1) + tail call void @__visc__bindIn(i8* %call, i32 15, i32 3, i32 1) + tail call void @__visc__bindIn(i8* %call, i32 2, i32 4, i32 1) + tail call void @__visc__bindIn(i8* %call, i32 3, i32 5, i32 1) + tail call void @__visc__bindIn(i8* %call, i32 22, i32 6, i32 1) + tail call void @__visc__bindIn(i8* %call, i32 23, i32 7, i32 1) + tail call void @__visc__bindIn(i8* %call1, i32 2, i32 0, i32 1) + %call6 = tail call i8* @__visc__edge(i8* %call, i8* %call1, i32 1, i32 0, i32 1, i32 1) + tail call void @__visc__bindIn(i8* %call1, i32 16, i32 2, i32 1) + tail call void @__visc__bindIn(i8* %call1, i32 17, i32 3, i32 1) + tail call void @__visc__bindIn(i8* %call1, i32 4, i32 4, i32 1) + tail call void @__visc__bindIn(i8* %call1, i32 5, i32 5, i32 1) + tail call void @__visc__bindIn(i8* %call1, i32 22, i32 6, i32 1) + tail call void @__visc__bindIn(i8* %call1, i32 23, i32 7, i32 1) + tail call void @__visc__bindIn(i8* %call2, i32 4, i32 0, i32 1) + %call7 = tail call i8* @__visc__edge(i8* %call1, i8* %call2, i32 1, i32 0, i32 1, i32 1) + tail call void @__visc__bindIn(i8* %call2, i32 16, i32 2, i32 1) + tail call void @__visc__bindIn(i8* %call2, i32 17, i32 3, i32 1) + tail call void @__visc__bindIn(i8* %call2, i32 6, i32 4, i32 1) + tail call void @__visc__bindIn(i8* %call2, i32 7, i32 5, i32 1) + tail call void @__visc__bindIn(i8* %call2, i32 22, i32 6, i32 1) + tail call void @__visc__bindIn(i8* %call2, i32 23, i32 7, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 2, i32 0, i32 1) + %call8 = tail call i8* @__visc__edge(i8* %call, i8* %call3, i32 1, i32 1, i32 1, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 18, i32 2, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 19, i32 3, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 20, i32 4, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 21, i32 5, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 8, i32 6, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 9, i32 7, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 22, i32 8, i32 1) + tail call void @__visc__bindIn(i8* %call3, i32 23, i32 9, i32 1) + tail call void @__visc__bindIn(i8* %call4, i32 8, i32 0, i32 1) + %call9 = tail call i8* @__visc__edge(i8* %call3, i8* %call4, i32 1, i32 0, i32 1, i32 1) + tail call void @__visc__bindIn(i8* %call4, i32 10, i32 2, i32 1) + tail call void @__visc__bindIn(i8* %call4, i32 11, i32 3, i32 1) + tail call void @__visc__bindIn(i8* %call4, i32 22, i32 4, i32 1) + tail call void @__visc__bindIn(i8* %call4, i32 23, i32 5, i32 1) + tail call void @__visc__bindIn(i8* %call4, i32 24, i32 6, i32 1) + tail call void @__visc__bindIn(i8* %call4, i32 25, i32 7, i32 1) + tail call void @__visc__bindIn(i8* %call5, i32 6, i32 0, i32 1) + %call10 = tail call i8* @__visc__edge(i8* %call2, i8* %call5, i32 1, i32 0, i32 1, i32 1) + tail call void @__visc__bindIn(i8* %call5, i32 8, i32 2, i32 1) + tail call void @__visc__bindIn(i8* %call5, i32 9, i32 3, i32 1) + tail call void @__visc__bindIn(i8* %call5, i32 10, i32 4, i32 1) + %call11 = tail call i8* @__visc__edge(i8* %call4, i8* %call5, i32 1, i32 0, i32 5, i32 1) + tail call void @__visc__bindIn(i8* %call5, i32 12, i32 6, i32 1) + tail call void @__visc__bindIn(i8* %call5, i32 13, i32 7, i32 1) + tail call void @__visc__bindIn(i8* %call5, i32 22, i32 8, i32 1) + tail call void @__visc__bindIn(i8* %call5, i32 23, i32 9, i32 1) + tail call void @__visc__bindOut(i8* %call5, i32 0, i32 0, i32 1) + ret void +} + +declare dso_local i8* @__visc__edge(i8*, i8*, i32, i32, i32, i32) local_unnamed_addr #0 + +; Function Attrs: uwtable +define dso_local void @_Z12getNextFrameRN2cv12VideoCaptureERNS_3MatE(%"class.cv::VideoCapture"* dereferenceable(24) %VC, %"class.cv::Mat"* dereferenceable(96) %F) local_unnamed_addr #6 { +entry: + %ref.tmp = alloca %"class.cv::_InputArray", align 8 + %ref.tmp2 = alloca %"class.cv::_OutputArray", align 8 + %ref.tmp3 = alloca %"class.cv::_OutputArray", align 8 + %0 = bitcast %"class.cv::VideoCapture"* %VC to %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*** + %vtable = load %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)**, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*** %0, align 8, !tbaa !35 + %vfn = getelementptr inbounds %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)** %vtable, i64 8 + %1 = load %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)** %vfn, align 8 + %call = tail call dereferenceable(24) %"class.cv::VideoCapture"* %1(%"class.cv::VideoCapture"* nonnull %VC, %"class.cv::Mat"* nonnull dereferenceable(96) %F) + %flags.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %F, i64 0, i32 0 + %2 = load i32, i32* %flags.i, align 8, !tbaa !37 + %3 = and i32 %2, 4088 + %cmp = icmp eq i32 %3, 16 + br i1 %cmp, label %if.then, label %if.end + +if.then: ; preds = %entry + %4 = bitcast %"class.cv::_InputArray"* %ref.tmp to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %4) #16 + call void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp, %"class.cv::Mat"* nonnull dereferenceable(96) %F) + %5 = bitcast %"class.cv::_OutputArray"* %ref.tmp2 to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %5) #16 + call void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp2, %"class.cv::Mat"* nonnull dereferenceable(96) %F) + call void @_ZN2cv8cvtColorERKNS_11_InputArrayERKNS_12_OutputArrayEii(%"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp2, i32 6, i32 0) + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %5) #16 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %4) #16 + br label %if.end + +if.end: ; preds = %if.then, %entry + %6 = bitcast %"class.cv::_OutputArray"* %ref.tmp3 to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %6) #16 + call void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp3, %"class.cv::Mat"* nonnull dereferenceable(96) %F) + call void @_ZNK2cv3Mat9convertToERKNS_12_OutputArrayEidd(%"class.cv::Mat"* nonnull %F, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp3, i32 5, double 0x3F70101010101010, double 0.000000e+00) + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %6) #16 + ret void +} + +declare dso_local void @_ZN2cv8cvtColorERKNS_11_InputArrayERKNS_12_OutputArrayEii(%"class.cv::_InputArray"* dereferenceable(32), %"class.cv::_OutputArray"* dereferenceable(32), i32, i32) local_unnamed_addr #0 + +declare dso_local void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"*, %"class.cv::Mat"* dereferenceable(96)) unnamed_addr #0 + +declare dso_local void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"*, %"class.cv::Mat"* dereferenceable(96)) unnamed_addr #0 + +declare dso_local void @_ZNK2cv3Mat9convertToERKNS_12_OutputArrayEidd(%"class.cv::Mat"*, %"class.cv::_OutputArray"* dereferenceable(32), i32, double, double) local_unnamed_addr #0 + +; Function Attrs: norecurse uwtable +define dso_local i32 @main(i32 %argc, i8** nocapture readonly %argv) local_unnamed_addr #7 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { +entry: + %ref.tmp.i1164 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp2.i1165 = alloca %"class.cv::_OutputArray", align 8 + %ref.tmp3.i1166 = alloca %"class.cv::_OutputArray", align 8 + %__c.addr.i = alloca i8, align 1 + %ref.tmp.i1094 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp2.i1095 = alloca %"class.cv::_OutputArray", align 8 + %ref.tmp3.i1096 = alloca %"class.cv::_OutputArray", align 8 + %__dnew.i.i.i.i1063 = alloca i64, align 8 + %sz.i.i = alloca [2 x i32], align 4 + %ref.tmp.i = alloca %"class.cv::_InputArray", align 8 + %ref.tmp2.i = alloca %"class.cv::_OutputArray", align 8 + %ref.tmp3.i = alloca %"class.cv::_OutputArray", align 8 + %__dnew.i.i.i.i = alloca i64, align 8 + %cap = alloca %"class.cv::VideoCapture", align 8 + %ref.tmp = alloca %"class.std::__cxx11::basic_string", align 8 + %src = alloca %"class.cv::Mat", align 8 + %Is = alloca %"class.cv::Mat", align 8 + %L = alloca %"class.cv::Mat", align 8 + %S = alloca %"class.cv::Mat", align 8 + %G = alloca %"class.cv::Mat", align 8 + %E = alloca %"class.cv::Mat", align 8 + %ref.tmp65 = alloca %"class.cv::Mat", align 8 + %ref.tmp79 = alloca %"class.cv::Mat", align 8 + %ref.tmp93 = alloca %"class.cv::Mat", align 8 + %ref.tmp107 = alloca %"class.cv::Mat", align 8 + %ref.tmp121 = alloca %"class.cv::Mat", align 8 + %B = alloca [9 x float], align 16 + %Sx = alloca [9 x float], align 16 + %Sy = alloca [9 x float], align 16 + %Gs = alloca [49 x float], align 16 + %in = alloca %"class.cv::Mat", align 8 + %out = alloca %"class.cv::Mat", align 8 + %ref.tmp165 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp168 = alloca %"class.cv::_OutputArray", align 8 + %agg.tmp = alloca %"class.cv::Size_", align 4 + %ref.tmp175 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp178 = alloca %"class.cv::_OutputArray", align 8 + %agg.tmp181 = alloca %"class.cv::Size_", align 4 + %ref.tmp186 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp191 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp241 = alloca %"class.cv::VideoCapture", align 8 + %ref.tmp242 = alloca %"class.std::__cxx11::basic_string", align 8 + %in310 = alloca %"class.cv::Mat", align 8 + %out313 = alloca %"class.cv::Mat", align 8 + %ref.tmp316 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp319 = alloca %"class.cv::_OutputArray", align 8 + %agg.tmp322 = alloca %"class.cv::Size_", align 4 + %ref.tmp327 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp330 = alloca %"class.cv::_OutputArray", align 8 + %agg.tmp333 = alloca %"class.cv::Size_", align 4 + %ref.tmp338 = alloca %"class.cv::_InputArray", align 8 + %ref.tmp343 = alloca %"class.cv::_InputArray", align 8 + %cmp = icmp slt i32 %argc, 2 + br i1 %cmp, label %if.then, label %if.end + +if.then: ; preds = %entry + %0 = load %struct._IO_FILE*, %struct._IO_FILE** @stderr, align 8, !tbaa !42 + %1 = tail call i64 @fwrite(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.4, i64 0, i64 0), i64 31, i64 1, %struct._IO_FILE* %0) #17 + tail call void @exit(i32 -1) #18 + unreachable + +if.end: ; preds = %entry + %arrayidx = getelementptr inbounds i8*, i8** %argv, i64 1 + %2 = load i8*, i8** %arrayidx, align 8, !tbaa !42 + %3 = load %struct._IO_FILE*, %struct._IO_FILE** @stderr, align 8, !tbaa !42 + %call1 = tail call i32 (%struct._IO_FILE*, i8*, ...) @fprintf(%struct._IO_FILE* %3, i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.5, i64 0, i64 0), i8* %2) #17 + %call1.i = tail call dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([13 x i8], [13 x i8]* @.str.6, i64 0, i64 0), i64 12) + %call1.i507 = tail call dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([8 x i8], [8 x i8]* @.str.7, i64 0, i64 0), i64 7) + %call1.i509 = tail call dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i64 1) + %call1.i511 = tail call dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([21 x i8], [21 x i8]* @.str.9, i64 0, i64 0), i64 20) + %tobool.i = icmp eq i8* %2, null + br i1 %tobool.i, label %if.then.i, label %if.else.i + +if.then.i: ; preds = %if.end + %vtable.i = load i8*, i8** bitcast (%"class.std::basic_ostream"* @_ZSt4cout to i8**), align 8, !tbaa !35 + %vbase.offset.ptr.i = getelementptr i8, i8* %vtable.i, i64 -24 + %4 = bitcast i8* %vbase.offset.ptr.i to i64* + %vbase.offset.i = load i64, i64* %4, align 8 + %add.ptr.i = getelementptr inbounds i8, i8* bitcast (%"class.std::basic_ostream"* @_ZSt4cout to i8*), i64 %vbase.offset.i + %5 = bitcast i8* %add.ptr.i to %"class.std::basic_ios"* + %_M_streambuf_state.i.i.i = getelementptr inbounds i8, i8* %add.ptr.i, i64 32 + %6 = bitcast i8* %_M_streambuf_state.i.i.i to i32* + %7 = load i32, i32* %6, align 8, !tbaa !43 + %or.i.i.i = or i32 %7, 1 + tail call void @_ZNSt9basic_iosIcSt11char_traitsIcEE5clearESt12_Ios_Iostate(%"class.std::basic_ios"* nonnull %5, i32 %or.i.i.i) + br label %_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc.exit + +if.else.i: ; preds = %if.end + %call.i.i512 = tail call i64 @strlen(i8* nonnull %2) #16 + %call1.i513 = tail call dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull %2, i64 %call.i.i512) + br label %_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc.exit + +_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc.exit: ; preds = %if.then.i, %if.else.i + %call1.i515 = tail call dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i64 1) + %8 = bitcast %"class.cv::VideoCapture"* %cap to i8* + call void @llvm.lifetime.start.p0i8(i64 24, i8* nonnull %8) #16 + %9 = bitcast %"class.std::__cxx11::basic_string"* %ref.tmp to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %9) #16 + %10 = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp, i64 0, i32 2 + %11 = bitcast %"class.std::__cxx11::basic_string"* %ref.tmp to %union.anon** + store %union.anon* %10, %union.anon** %11, align 8, !tbaa !49 + br i1 %tobool.i, label %if.then.i.i.i.i, label %cond.end.thread.i + +cond.end.thread.i: ; preds = %_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc.exit + %12 = bitcast %union.anon* %10 to i8* + %call.i.i518 = call i64 @strlen(i8* nonnull %2) #16 + %13 = bitcast i64* %__dnew.i.i.i.i to i8* + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %13) #16 + store i64 %call.i.i518, i64* %__dnew.i.i.i.i, align 8, !tbaa !51 + %cmp3.i.i.i.i = icmp ugt i64 %call.i.i518, 15 + br i1 %cmp3.i.i.i.i, label %if.then4.i.i.i.i, label %if.end6.i.i.i.i + +if.then.i.i.i.i: ; preds = %_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc.exit + invoke void @_ZSt19__throw_logic_errorPKc(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.21, i64 0, i64 0)) #19 + to label %.noexc unwind label %lpad + +.noexc: ; preds = %if.then.i.i.i.i + unreachable + +if.then4.i.i.i.i: ; preds = %cond.end.thread.i + %call5.i.i.i9.i519 = invoke i8* @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_createERmm(%"class.std::__cxx11::basic_string"* nonnull %ref.tmp, i64* nonnull dereferenceable(8) %__dnew.i.i.i.i, i64 0) + to label %call5.i.i.i9.i.noexc unwind label %lpad + +call5.i.i.i9.i.noexc: ; preds = %if.then4.i.i.i.i + %_M_p.i18.i.i.i.i = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp, i64 0, i32 0, i32 0 + store i8* %call5.i.i.i9.i519, i8** %_M_p.i18.i.i.i.i, align 8, !tbaa !52 + %14 = load i64, i64* %__dnew.i.i.i.i, align 8, !tbaa !51 + %_M_allocated_capacity.i.i.i.i.i = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp, i64 0, i32 2, i32 0 + store i64 %14, i64* %_M_allocated_capacity.i.i.i.i.i, align 8, !tbaa !54 + br label %if.end6.i.i.i.i + +if.end6.i.i.i.i: ; preds = %call5.i.i.i9.i.noexc, %cond.end.thread.i + %15 = phi i8* [ %call5.i.i.i9.i519, %call5.i.i.i9.i.noexc ], [ %12, %cond.end.thread.i ] + %_M_p.i.i.i.i.i = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp, i64 0, i32 0, i32 0 + switch i64 %call.i.i518, label %if.end.i.i.i.i.i.i.i [ + i64 1, label %if.then.i.i.i.i.i.i + i64 0, label %invoke.cont + ] + +if.then.i.i.i.i.i.i: ; preds = %if.end6.i.i.i.i + %16 = load i8, i8* %2, align 1, !tbaa !54 + store i8 %16, i8* %15, align 1, !tbaa !54 + br label %invoke.cont + +if.end.i.i.i.i.i.i.i: ; preds = %if.end6.i.i.i.i + call void @llvm.memcpy.p0i8.p0i8.i64(i8* align 1 %15, i8* nonnull align 1 %2, i64 %call.i.i518, i1 false) #16 + br label %invoke.cont + +invoke.cont: ; preds = %if.end.i.i.i.i.i.i.i, %if.then.i.i.i.i.i.i, %if.end6.i.i.i.i + %17 = load i64, i64* %__dnew.i.i.i.i, align 8, !tbaa !51 + %_M_string_length.i.i.i.i.i.i = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp, i64 0, i32 1 + store i64 %17, i64* %_M_string_length.i.i.i.i.i.i, align 8, !tbaa !55 + %18 = load i8*, i8** %_M_p.i.i.i.i.i, align 8, !tbaa !52 + %arrayidx.i.i.i.i.i = getelementptr inbounds i8, i8* %18, i64 %17 + store i8 0, i8* %arrayidx.i.i.i.i.i, align 1, !tbaa !54 + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %13) #16 + invoke void @_ZN2cv12VideoCaptureC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(%"class.cv::VideoCapture"* nonnull %cap, %"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) %ref.tmp) + to label %invoke.cont10 unwind label %lpad9 + +invoke.cont10: ; preds = %invoke.cont + %19 = load i8*, i8** %_M_p.i.i.i.i.i, align 8, !tbaa !52 + %cmp.i.i.i = icmp eq i8* %19, %12 + br i1 %cmp.i.i.i, label %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit, label %if.then.i.i + +if.then.i.i: ; preds = %invoke.cont10 + call void @_ZdlPv(i8* %19) #16 + br label %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit + +_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit: ; preds = %invoke.cont10, %if.then.i.i + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %9) #16 + %call15 = invoke zeroext i1 @_ZNK2cv12VideoCapture8isOpenedEv(%"class.cv::VideoCapture"* nonnull %cap) + to label %invoke.cont14 unwind label %lpad13 + +invoke.cont14: ; preds = %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit + br i1 %call15, label %if.end21, label %if.then16 + +if.then16: ; preds = %invoke.cont14 + %call1.i521523 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([26 x i8], [26 x i8]* @.str.10, i64 0, i64 0), i64 25) + to label %invoke.cont17 unwind label %lpad13 + +invoke.cont17: ; preds = %if.then16 + %call1.i526528 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i64 1) + to label %cleanup unwind label %lpad13 + +lpad: ; preds = %if.then4.i.i.i.i, %if.then.i.i.i.i + %20 = landingpad { i8*, i32 } + cleanup + %21 = extractvalue { i8*, i32 } %20, 0 + %22 = extractvalue { i8*, i32 } %20, 1 + br label %ehcleanup + +lpad9: ; preds = %invoke.cont + %23 = landingpad { i8*, i32 } + cleanup + %24 = extractvalue { i8*, i32 } %23, 0 + %25 = extractvalue { i8*, i32 } %23, 1 + %26 = load i8*, i8** %_M_p.i.i.i.i.i, align 8, !tbaa !52 + %cmp.i.i.i532 = icmp eq i8* %26, %12 + br i1 %cmp.i.i.i532, label %ehcleanup, label %if.then.i.i533 + +if.then.i.i533: ; preds = %lpad9 + call void @_ZdlPv(i8* %26) #16 + br label %ehcleanup + +ehcleanup: ; preds = %if.then.i.i533, %lpad9, %lpad + %ehselector.slot.0 = phi i32 [ %22, %lpad ], [ %25, %lpad9 ], [ %25, %if.then.i.i533 ] + %exn.slot.0 = phi i8* [ %21, %lpad ], [ %24, %lpad9 ], [ %24, %if.then.i.i533 ] + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %9) #16 + br label %ehcleanup420 + +lpad13: ; preds = %invoke.cont17, %if.then16, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit + %27 = landingpad { i8*, i32 } + cleanup + %28 = extractvalue { i8*, i32 } %27, 0 + %29 = extractvalue { i8*, i32 } %27, 1 + br label %ehcleanup418 + +if.end21: ; preds = %invoke.cont14 + %call24 = invoke double @_ZN2cv12VideoCapture3getEi(%"class.cv::VideoCapture"* nonnull %cap, i32 7) + to label %invoke.cont23 unwind label %lpad22 + +invoke.cont23: ; preds = %if.end21 + %call1.i536538 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([20 x i8], [20 x i8]* @.str.11, i64 0, i64 0), i64 19) + to label %invoke.cont25 unwind label %lpad22 + +invoke.cont25: ; preds = %invoke.cont23 + %call28 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZNSolsEi(%"class.std::basic_ostream"* nonnull @_ZSt4cout, i32 600) + to label %invoke.cont27 unwind label %lpad22 + +invoke.cont27: ; preds = %invoke.cont25 + %call1.i541543 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) %call28, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i64 1) + to label %invoke.cont29 unwind label %lpad22 + +invoke.cont29: ; preds = %invoke.cont27 + invoke void @_ZN2cv11namedWindowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi(%"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) @_Z12input_windowB5cxx11, i32 1) + to label %invoke.cont31 unwind label %lpad22 + +invoke.cont31: ; preds = %invoke.cont29 + invoke void @_ZN2cv11namedWindowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi(%"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) @_Z13output_windowB5cxx11, i32 1) + to label %invoke.cont32 unwind label %lpad22 + +invoke.cont32: ; preds = %invoke.cont31 + invoke void @_ZN2cv10moveWindowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(%"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) @_Z12input_windowB5cxx11, i32 0, i32 0) + to label %invoke.cont33 unwind label %lpad22 + +invoke.cont33: ; preds = %invoke.cont32 + invoke void @_ZN2cv10moveWindowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(%"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) @_Z13output_windowB5cxx11, i32 0, i32 540) + to label %invoke.cont46 unwind label %lpad22 + +invoke.cont46: ; preds = %invoke.cont33 + %30 = bitcast %"class.cv::Mat"* %src to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %30) #16 + %rows.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 2 + %p.i.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 10, i32 0 + store i32* %rows.i, i32** %p.i.i, align 8, !tbaa !56 + %arraydecay.i.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 11, i32 1, i64 0 + %p.i2.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i, i64** %p.i2.i, align 8, !tbaa !57 + %31 = bitcast i64* %arraydecay.i.i to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %31, i8 0, i64 16, i1 false) #16 + %flags.i.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i, align 8, !tbaa !37 + %dims.i.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 1 + %32 = bitcast i32* %dims.i.i to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %32, i8 0, i64 60, i1 false) #16 + %33 = bitcast %"class.cv::Mat"* %Is to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %33) #16 + %rows.i545 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 2 + %p.i.i546 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 10, i32 0 + store i32* %rows.i545, i32** %p.i.i546, align 8, !tbaa !56 + %arraydecay.i.i547 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 11, i32 1, i64 0 + %p.i2.i548 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i547, i64** %p.i2.i548, align 8, !tbaa !57 + %34 = bitcast i64* %arraydecay.i.i547 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %34, i8 0, i64 16, i1 false) #16 + %flags.i.i549 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i549, align 8, !tbaa !37 + %dims.i.i550 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 1 + %35 = bitcast i32* %dims.i.i550 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %35, i8 0, i64 60, i1 false) #16 + %36 = bitcast %"class.cv::Mat"* %L to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %36) #16 + %rows.i551 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 2 + %p.i.i552 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 10, i32 0 + store i32* %rows.i551, i32** %p.i.i552, align 8, !tbaa !56 + %arraydecay.i.i553 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 11, i32 1, i64 0 + %p.i2.i554 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i553, i64** %p.i2.i554, align 8, !tbaa !57 + %37 = bitcast i64* %arraydecay.i.i553 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %37, i8 0, i64 16, i1 false) #16 + %flags.i.i555 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i555, align 8, !tbaa !37 + %dims.i.i556 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 1 + %38 = bitcast i32* %dims.i.i556 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %38, i8 0, i64 60, i1 false) #16 + %39 = bitcast %"class.cv::Mat"* %S to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %39) #16 + %rows.i557 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 2 + %p.i.i558 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 10, i32 0 + store i32* %rows.i557, i32** %p.i.i558, align 8, !tbaa !56 + %arraydecay.i.i559 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 11, i32 1, i64 0 + %p.i2.i560 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i559, i64** %p.i2.i560, align 8, !tbaa !57 + %40 = bitcast i64* %arraydecay.i.i559 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %40, i8 0, i64 16, i1 false) #16 + %flags.i.i561 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i561, align 8, !tbaa !37 + %dims.i.i562 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 1 + %41 = bitcast i32* %dims.i.i562 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %41, i8 0, i64 60, i1 false) #16 + %42 = bitcast %"class.cv::Mat"* %G to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %42) #16 + %rows.i563 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 2 + %p.i.i564 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 10, i32 0 + store i32* %rows.i563, i32** %p.i.i564, align 8, !tbaa !56 + %arraydecay.i.i565 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 11, i32 1, i64 0 + %p.i2.i566 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i565, i64** %p.i2.i566, align 8, !tbaa !57 + %43 = bitcast i64* %arraydecay.i.i565 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %43, i8 0, i64 16, i1 false) #16 + %flags.i.i567 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i567, align 8, !tbaa !37 + %dims.i.i568 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 1 + %44 = bitcast i32* %dims.i.i568 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %44, i8 0, i64 60, i1 false) #16 + %45 = bitcast %"class.cv::Mat"* %E to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %45) #16 + %rows.i569 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 2 + %p.i.i570 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 10, i32 0 + store i32* %rows.i569, i32** %p.i.i570, align 8, !tbaa !56 + %arraydecay.i.i571 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 11, i32 1, i64 0 + %p.i2.i572 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i571, i64** %p.i2.i572, align 8, !tbaa !57 + %46 = bitcast i64* %arraydecay.i.i571 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %46, i8 0, i64 16, i1 false) #16 + %flags.i.i573 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i573, align 8, !tbaa !37 + %dims.i.i574 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 1 + %47 = bitcast i32* %dims.i.i574 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %47, i8 0, i64 60, i1 false) #16 + %48 = bitcast %"class.cv::VideoCapture"* %cap to %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*** + %vtable.i575 = load %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)**, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*** %48, align 8, !tbaa !35 + %vfn.i = getelementptr inbounds %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)** %vtable.i575, i64 8 + %49 = load %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)** %vfn.i, align 8 + %call.i578 = invoke dereferenceable(24) %"class.cv::VideoCapture"* %49(%"class.cv::VideoCapture"* nonnull %cap, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %call.i.noexc unwind label %lpad47 + +call.i.noexc: ; preds = %invoke.cont46 + %50 = load i32, i32* %flags.i.i, align 8, !tbaa !37 + %51 = and i32 %50, 4088 + %cmp.i = icmp eq i32 %51, 16 + br i1 %cmp.i, label %if.then.i577, label %if.end.i + +if.then.i577: ; preds = %call.i.noexc + %52 = bitcast %"class.cv::_InputArray"* %ref.tmp.i to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %52) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp.i, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc579 unwind label %lpad47 + +.noexc579: ; preds = %if.then.i577 + %53 = bitcast %"class.cv::_OutputArray"* %ref.tmp2.i to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %53) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp2.i, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc580 unwind label %lpad47 + +.noexc580: ; preds = %.noexc579 + invoke void @_ZN2cv8cvtColorERKNS_11_InputArrayERKNS_12_OutputArrayEii(%"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp.i, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp2.i, i32 6, i32 0) + to label %.noexc581 unwind label %lpad47 + +.noexc581: ; preds = %.noexc580 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %53) #16 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %52) #16 + br label %if.end.i + +if.end.i: ; preds = %.noexc581, %call.i.noexc + %54 = bitcast %"class.cv::_OutputArray"* %ref.tmp3.i to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %54) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp3.i, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc582 unwind label %lpad47 + +.noexc582: ; preds = %if.end.i + invoke void @_ZNK2cv3Mat9convertToERKNS_12_OutputArrayEidd(%"class.cv::Mat"* nonnull %src, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp3.i, i32 5, double 0x3F70101010101010, double 0.000000e+00) + to label %invoke.cont48 unwind label %lpad47 + +invoke.cont48: ; preds = %.noexc582 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %54) #16 + %call1.i585588 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([19 x i8], [19 x i8]* @.str.12, i64 0, i64 0), i64 18) + to label %invoke.cont53 unwind label %lpad47 + +invoke.cont53: ; preds = %invoke.cont48 + %55 = load i32*, i32** %p.i.i, align 8, !tbaa !56, !noalias !58 + %arrayidx.i = getelementptr inbounds i32, i32* %55, i64 1 + %56 = load i32, i32* %arrayidx.i, align 4, !tbaa !61, !noalias !58 + %57 = load i32, i32* %55, align 4, !tbaa !61, !noalias !58 + %call1.i.i591 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.22, i64 0, i64 0), i64 1) + to label %call1.i.i.noexc unwind label %lpad52 + +call1.i.i.noexc: ; preds = %invoke.cont53 + %call1.i590592 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZNSolsEi(%"class.std::basic_ostream"* nonnull @_ZSt4cout, i32 %56) + to label %call1.i590.noexc unwind label %lpad52 + +call1.i590.noexc: ; preds = %call1.i.i.noexc + %call1.i8.i593 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) %call1.i590592, i8* nonnull getelementptr inbounds ([4 x i8], [4 x i8]* @.str.23, i64 0, i64 0), i64 3) + to label %call1.i8.i.noexc unwind label %lpad52 + +call1.i8.i.noexc: ; preds = %call1.i590.noexc + %call3.i594 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZNSolsEi(%"class.std::basic_ostream"* nonnull %call1.i590592, i32 %57) + to label %call3.i.noexc unwind label %lpad52 + +call3.i.noexc: ; preds = %call1.i8.i.noexc + %call1.i10.i595 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) %call3.i594, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.24, i64 0, i64 0), i64 1) + to label %invoke.cont54 unwind label %lpad52 + +invoke.cont54: ; preds = %call3.i.noexc + %call1.i597600 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i64 1) + to label %invoke.cont56 unwind label %lpad52 + +invoke.cont56: ; preds = %invoke.cont54 + %58 = load i32, i32* %flags.i.i, align 8, !tbaa !37 + %and.i = and i32 %58, 16384 + %cmp.i602 = icmp eq i32 %and.i, 0 + br i1 %cmp.i602, label %if.then61, label %if.end64 + +if.then61: ; preds = %invoke.cont56 + %call63 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.13, i64 0, i64 0)) + to label %invoke.cont62 unwind label %lpad47 + +invoke.cont62: ; preds = %if.then61 + call void @exit(i32 -1) #18 + unreachable + +lpad22: ; preds = %invoke.cont27, %invoke.cont23, %invoke.cont33, %invoke.cont32, %invoke.cont31, %invoke.cont29, %invoke.cont25, %if.end21 + %59 = landingpad { i8*, i32 } + cleanup + %60 = extractvalue { i8*, i32 } %59, 0 + %61 = extractvalue { i8*, i32 } %59, 1 + br label %ehcleanup418 + +lpad47: ; preds = %invoke.cont48, %.noexc582, %if.end.i, %.noexc580, %.noexc579, %if.then.i577, %invoke.cont46, %cond.end, %if.then61 + %62 = landingpad { i8*, i32 } + cleanup + %63 = extractvalue { i8*, i32 } %62, 0 + %64 = extractvalue { i8*, i32 } %62, 1 + br label %ehcleanup405 + +lpad52: ; preds = %invoke.cont54, %call3.i.noexc, %call1.i8.i.noexc, %call1.i590.noexc, %call1.i.i.noexc, %invoke.cont53 + %65 = landingpad { i8*, i32 } + cleanup + %66 = extractvalue { i8*, i32 } %65, 0 + %67 = extractvalue { i8*, i32 } %65, 1 + br label %ehcleanup405 + +if.end64: ; preds = %invoke.cont56 + %68 = bitcast %"class.cv::Mat"* %ref.tmp65 to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %68) #16 + %69 = load i32*, i32** %p.i.i, align 8, !tbaa !56 + %70 = load i32, i32* %69, align 4, !tbaa !61 + %arrayidx.i605 = getelementptr inbounds i32, i32* %69, i64 1 + %71 = load i32, i32* %arrayidx.i605, align 4, !tbaa !61 + %rows.i606 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 2 + %p.i.i607 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 10, i32 0 + store i32* %rows.i606, i32** %p.i.i607, align 8, !tbaa !56 + %arraydecay.i.i608 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 11, i32 1, i64 0 + %p.i2.i609 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i608, i64** %p.i2.i609, align 8, !tbaa !57 + %72 = bitcast i64* %arraydecay.i.i608 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %72, i8 0, i64 16, i1 false) #16 + %flags.i.i610 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i610, align 8, !tbaa !37 + %dims.i3.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 1 + %73 = bitcast i32* %dims.i3.i to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %73, i8 0, i64 60, i1 false) #16 + %74 = bitcast [2 x i32]* %sz.i.i to i8* + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %74) #16 + %arrayinit.begin.i.i = getelementptr inbounds [2 x i32], [2 x i32]* %sz.i.i, i64 0, i64 0 + store i32 %70, i32* %arrayinit.begin.i.i, align 4, !tbaa !61 + %arrayinit.element.i.i = getelementptr inbounds [2 x i32], [2 x i32]* %sz.i.i, i64 0, i64 1 + store i32 %71, i32* %arrayinit.element.i.i, align 4, !tbaa !61 + invoke void @_ZN2cv3Mat6createEiPKii(%"class.cv::Mat"* nonnull %ref.tmp65, i32 2, i32* nonnull %arrayinit.begin.i.i, i32 5) + to label %invoke.cont73 unwind label %lpad67 + +invoke.cont73: ; preds = %if.end64 + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %74) #16 + %refcount.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 5 + %75 = load i32*, i32** %refcount.i, align 8, !tbaa !62 + %tobool.i612 = icmp eq i32* %75, null + br i1 %tobool.i612, label %if.end.i614, label %if.then2.i + +if.then2.i: ; preds = %invoke.cont73 + %76 = atomicrmw add i32* %75, i32 1 seq_cst + br label %if.end.i614 + +if.end.i614: ; preds = %if.then2.i, %invoke.cont73 + %refcount.i.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 5 + %77 = load i32*, i32** %refcount.i.i, align 8, !tbaa !62 + %tobool.i.i = icmp eq i32* %77, null + br i1 %tobool.i.i, label %_ZN2cv3Mat7releaseEv.exit.i, label %land.lhs.true.i.i + +land.lhs.true.i.i: ; preds = %if.end.i614 + %78 = atomicrmw add i32* %77, i32 -1 seq_cst + %cmp.i.i = icmp eq i32 %78, 1 + br i1 %cmp.i.i, label %if.then.i.i615, label %_ZN2cv3Mat7releaseEv.exit.i + +if.then.i.i615: ; preds = %land.lhs.true.i.i + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %Is) + to label %_ZN2cv3Mat7releaseEv.exit.i unwind label %lpad74 + +_ZN2cv3Mat7releaseEv.exit.i: ; preds = %if.then.i.i615, %land.lhs.true.i.i, %if.end.i614 + %datastart.i.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 6 + %data.i.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 4 + store i8* null, i8** %data.i.i, align 8, !tbaa !63 + %79 = bitcast i8** %datastart.i.i to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %79, i8 0, i64 24, i1 false) + %80 = load i32*, i32** %p.i.i546, align 8, !tbaa !64 + store i32 0, i32* %80, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i, align 8, !tbaa !62 + %81 = load i32, i32* %flags.i.i610, align 8, !tbaa !37 + store i32 %81, i32* %flags.i.i549, align 8, !tbaa !37 + %82 = load i32, i32* %dims.i.i550, align 4, !tbaa !65 + %cmp5.i = icmp slt i32 %82, 3 + br i1 %cmp5.i, label %land.lhs.true.i, label %if.else.i619 + +land.lhs.true.i: ; preds = %_ZN2cv3Mat7releaseEv.exit.i + %83 = load i32, i32* %dims.i3.i, align 4, !tbaa !65 + %cmp7.i = icmp slt i32 %83, 3 + br i1 %cmp7.i, label %if.then8.i, label %if.else.i619 + +if.then8.i: ; preds = %land.lhs.true.i + store i32 %83, i32* %dims.i.i550, align 4, !tbaa !65 + %84 = load i32, i32* %rows.i606, align 8, !tbaa !66 + store i32 %84, i32* %rows.i545, align 8, !tbaa !66 + %cols.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 3 + %85 = load i32, i32* %cols.i, align 4, !tbaa !67 + %cols12.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 3 + store i32 %85, i32* %cols12.i, align 4, !tbaa !67 + %86 = load i64*, i64** %p.i2.i609, align 8, !tbaa !57 + %87 = load i64, i64* %86, align 8, !tbaa !51 + %88 = load i64*, i64** %p.i2.i548, align 8, !tbaa !57 + store i64 %87, i64* %88, align 8, !tbaa !51 + %arrayidx.i48.i = getelementptr inbounds i64, i64* %86, i64 1 + %89 = load i64, i64* %arrayidx.i48.i, align 8, !tbaa !51 + %arrayidx.i.i = getelementptr inbounds i64, i64* %88, i64 1 + store i64 %89, i64* %arrayidx.i.i, align 8, !tbaa !51 + br label %invoke.cont75 + +if.else.i619: ; preds = %land.lhs.true.i, %_ZN2cv3Mat7releaseEv.exit.i + invoke void @_ZN2cv3Mat8copySizeERKS0_(%"class.cv::Mat"* nonnull %Is, %"class.cv::Mat"* nonnull dereferenceable(96) %ref.tmp65) + to label %invoke.cont75 unwind label %lpad74 + +invoke.cont75: ; preds = %if.then8.i, %if.else.i619 + %data.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 4 + %90 = bitcast i8** %data.i to i64* + %91 = load i64, i64* %90, align 8, !tbaa !63 + %92 = bitcast i8** %data.i.i to i64* + store i64 %91, i64* %92, align 8, !tbaa !63 + %datastart.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 6 + %93 = bitcast i8** %datastart.i to i64* + %94 = load i64, i64* %93, align 8, !tbaa !68 + %95 = bitcast i8** %datastart.i.i to i64* + store i64 %94, i64* %95, align 8, !tbaa !68 + %dataend.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 7 + %96 = bitcast i8** %dataend.i to i64* + %97 = load i64, i64* %96, align 8, !tbaa !69 + %dataend22.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 7 + %98 = bitcast i8** %dataend22.i to i64* + store i64 %97, i64* %98, align 8, !tbaa !69 + %datalimit.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 8 + %99 = bitcast i8** %datalimit.i to i64* + %100 = load i64, i64* %99, align 8, !tbaa !70 + %datalimit23.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 8 + %101 = bitcast i8** %datalimit23.i to i64* + store i64 %100, i64* %101, align 8, !tbaa !70 + %102 = bitcast i32** %refcount.i to i64* + %103 = load i64, i64* %102, align 8, !tbaa !62 + %104 = bitcast i32** %refcount.i.i to i64* + store i64 %103, i64* %104, align 8, !tbaa !62 + %allocator.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 9 + %105 = bitcast %"class.cv::MatAllocator"** %allocator.i to i64* + %106 = load i64, i64* %105, align 8, !tbaa !71 + %allocator26.i = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 9 + %107 = bitcast %"class.cv::MatAllocator"** %allocator26.i to i64* + store i64 %106, i64* %107, align 8, !tbaa !71 + %tobool.i.i623 = icmp eq i64 %103, 0 + br i1 %tobool.i.i623, label %invoke.cont.i, label %land.lhs.true.i.i625 + +land.lhs.true.i.i625: ; preds = %invoke.cont75 + %108 = inttoptr i64 %103 to i32* + %109 = atomicrmw add i32* %108, i32 -1 seq_cst + %cmp.i.i624 = icmp eq i32 %109, 1 + br i1 %cmp.i.i624, label %if.then.i.i626, label %invoke.cont.i + +if.then.i.i626: ; preds = %land.lhs.true.i.i625 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp65) + to label %invoke.cont.i unwind label %terminate.lpad.i + +invoke.cont.i: ; preds = %if.then.i.i626, %land.lhs.true.i.i625, %invoke.cont75 + store i8* null, i8** %data.i, align 8, !tbaa !63 + %110 = bitcast i8** %datastart.i to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %110, i8 0, i64 24, i1 false) #16 + %111 = load i32*, i32** %p.i.i607, align 8, !tbaa !64 + store i32 0, i32* %111, align 4, !tbaa !61 + store i32* null, i32** %refcount.i, align 8, !tbaa !62 + %112 = load i64*, i64** %p.i2.i609, align 8, !tbaa !72 + %cmp.i631 = icmp eq i64* %112, %arraydecay.i.i608 + br i1 %cmp.i631, label %_ZN2cv3MatD2Ev.exit, label %if.then.i632 + +if.then.i632: ; preds = %invoke.cont.i + %113 = bitcast i64* %112 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %113) + to label %_ZN2cv3MatD2Ev.exit unwind label %terminate.lpad.i + +terminate.lpad.i: ; preds = %if.then.i632, %if.then.i.i626 + %114 = landingpad { i8*, i32 } + catch i8* null + %115 = extractvalue { i8*, i32 } %114, 0 + call void @__clang_call_terminate(i8* %115) #18 + unreachable + +_ZN2cv3MatD2Ev.exit: ; preds = %invoke.cont.i, %if.then.i632 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %68) #16 + %116 = bitcast %"class.cv::Mat"* %ref.tmp79 to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %116) #16 + %117 = load i32*, i32** %p.i.i, align 8, !tbaa !56 + %118 = load i32, i32* %117, align 4, !tbaa !61 + %arrayidx.i636 = getelementptr inbounds i32, i32* %117, i64 1 + %119 = load i32, i32* %arrayidx.i636, align 4, !tbaa !61 + %rows.i638 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 2 + %p.i.i639 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 10, i32 0 + store i32* %rows.i638, i32** %p.i.i639, align 8, !tbaa !56 + %arraydecay.i.i640 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 11, i32 1, i64 0 + %p.i2.i641 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i640, i64** %p.i2.i641, align 8, !tbaa !57 + %120 = bitcast i64* %arraydecay.i.i640 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %120, i8 0, i64 16, i1 false) #16 + %flags.i.i642 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i642, align 8, !tbaa !37 + %dims.i3.i643 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 1 + %121 = bitcast i32* %dims.i3.i643 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %121, i8 0, i64 60, i1 false) #16 + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %74) #16 + store i32 %118, i32* %arrayinit.begin.i.i, align 4, !tbaa !61 + store i32 %119, i32* %arrayinit.element.i.i, align 4, !tbaa !61 + invoke void @_ZN2cv3Mat6createEiPKii(%"class.cv::Mat"* nonnull %ref.tmp79, i32 2, i32* nonnull %arrayinit.begin.i.i, i32 5) + to label %invoke.cont87 unwind label %lpad81 + +invoke.cont87: ; preds = %_ZN2cv3MatD2Ev.exit + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %74) #16 + %refcount.i649 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 5 + %122 = load i32*, i32** %refcount.i649, align 8, !tbaa !62 + %tobool.i650 = icmp eq i32* %122, null + br i1 %tobool.i650, label %if.end.i655, label %if.then2.i652 + +if.then2.i652: ; preds = %invoke.cont87 + %123 = atomicrmw add i32* %122, i32 1 seq_cst + br label %if.end.i655 + +if.end.i655: ; preds = %if.then2.i652, %invoke.cont87 + %refcount.i.i653 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 5 + %124 = load i32*, i32** %refcount.i.i653, align 8, !tbaa !62 + %tobool.i.i654 = icmp eq i32* %124, null + br i1 %tobool.i.i654, label %_ZN2cv3Mat7releaseEv.exit.i666, label %land.lhs.true.i.i657 + +land.lhs.true.i.i657: ; preds = %if.end.i655 + %125 = atomicrmw add i32* %124, i32 -1 seq_cst + %cmp.i.i656 = icmp eq i32 %125, 1 + br i1 %cmp.i.i656, label %if.then.i.i658, label %_ZN2cv3Mat7releaseEv.exit.i666 + +if.then.i.i658: ; preds = %land.lhs.true.i.i657 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %L) + to label %_ZN2cv3Mat7releaseEv.exit.i666 unwind label %lpad88 + +_ZN2cv3Mat7releaseEv.exit.i666: ; preds = %if.then.i.i658, %land.lhs.true.i.i657, %if.end.i655 + %datastart.i.i659 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 6 + %data.i.i660 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 4 + store i8* null, i8** %data.i.i660, align 8, !tbaa !63 + %126 = bitcast i8** %datastart.i.i659 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %126, i8 0, i64 24, i1 false) + %127 = load i32*, i32** %p.i.i552, align 8, !tbaa !64 + store i32 0, i32* %127, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i653, align 8, !tbaa !62 + %128 = load i32, i32* %flags.i.i642, align 8, !tbaa !37 + store i32 %128, i32* %flags.i.i555, align 8, !tbaa !37 + %129 = load i32, i32* %dims.i.i556, align 4, !tbaa !65 + %cmp5.i665 = icmp slt i32 %129, 3 + br i1 %cmp5.i665, label %land.lhs.true.i669, label %if.else.i679 + +land.lhs.true.i669: ; preds = %_ZN2cv3Mat7releaseEv.exit.i666 + %130 = load i32, i32* %dims.i3.i643, align 4, !tbaa !65 + %cmp7.i668 = icmp slt i32 %130, 3 + br i1 %cmp7.i668, label %if.then8.i678, label %if.else.i679 + +if.then8.i678: ; preds = %land.lhs.true.i669 + store i32 %130, i32* %dims.i.i556, align 4, !tbaa !65 + %131 = load i32, i32* %rows.i638, align 8, !tbaa !66 + store i32 %131, i32* %rows.i551, align 8, !tbaa !66 + %cols.i672 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 3 + %132 = load i32, i32* %cols.i672, align 4, !tbaa !67 + %cols12.i673 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 3 + store i32 %132, i32* %cols12.i673, align 4, !tbaa !67 + %133 = load i64*, i64** %p.i2.i641, align 8, !tbaa !57 + %134 = load i64, i64* %133, align 8, !tbaa !51 + %135 = load i64*, i64** %p.i2.i554, align 8, !tbaa !57 + store i64 %134, i64* %135, align 8, !tbaa !51 + %arrayidx.i48.i676 = getelementptr inbounds i64, i64* %133, i64 1 + %136 = load i64, i64* %arrayidx.i48.i676, align 8, !tbaa !51 + %arrayidx.i.i677 = getelementptr inbounds i64, i64* %135, i64 1 + store i64 %136, i64* %arrayidx.i.i677, align 8, !tbaa !51 + br label %invoke.cont89 + +if.else.i679: ; preds = %land.lhs.true.i669, %_ZN2cv3Mat7releaseEv.exit.i666 + invoke void @_ZN2cv3Mat8copySizeERKS0_(%"class.cv::Mat"* nonnull %L, %"class.cv::Mat"* nonnull dereferenceable(96) %ref.tmp79) + to label %invoke.cont89 unwind label %lpad88 + +invoke.cont89: ; preds = %if.then8.i678, %if.else.i679 + %data.i680 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 4 + %137 = bitcast i8** %data.i680 to i64* + %138 = load i64, i64* %137, align 8, !tbaa !63 + %139 = bitcast i8** %data.i.i660 to i64* + store i64 %138, i64* %139, align 8, !tbaa !63 + %datastart.i681 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 6 + %140 = bitcast i8** %datastart.i681 to i64* + %141 = load i64, i64* %140, align 8, !tbaa !68 + %142 = bitcast i8** %datastart.i.i659 to i64* + store i64 %141, i64* %142, align 8, !tbaa !68 + %dataend.i682 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 7 + %143 = bitcast i8** %dataend.i682 to i64* + %144 = load i64, i64* %143, align 8, !tbaa !69 + %dataend22.i683 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 7 + %145 = bitcast i8** %dataend22.i683 to i64* + store i64 %144, i64* %145, align 8, !tbaa !69 + %datalimit.i684 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 8 + %146 = bitcast i8** %datalimit.i684 to i64* + %147 = load i64, i64* %146, align 8, !tbaa !70 + %datalimit23.i685 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 8 + %148 = bitcast i8** %datalimit23.i685 to i64* + store i64 %147, i64* %148, align 8, !tbaa !70 + %149 = bitcast i32** %refcount.i649 to i64* + %150 = load i64, i64* %149, align 8, !tbaa !62 + %151 = bitcast i32** %refcount.i.i653 to i64* + store i64 %150, i64* %151, align 8, !tbaa !62 + %allocator.i686 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 9 + %152 = bitcast %"class.cv::MatAllocator"** %allocator.i686 to i64* + %153 = load i64, i64* %152, align 8, !tbaa !71 + %allocator26.i687 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 9 + %154 = bitcast %"class.cv::MatAllocator"** %allocator26.i687 to i64* + store i64 %153, i64* %154, align 8, !tbaa !71 + %tobool.i.i692 = icmp eq i64 %150, 0 + br i1 %tobool.i.i692, label %invoke.cont.i702, label %land.lhs.true.i.i694 + +land.lhs.true.i.i694: ; preds = %invoke.cont89 + %155 = inttoptr i64 %150 to i32* + %156 = atomicrmw add i32* %155, i32 -1 seq_cst + %cmp.i.i693 = icmp eq i32 %156, 1 + br i1 %cmp.i.i693, label %if.then.i.i695, label %invoke.cont.i702 + +if.then.i.i695: ; preds = %land.lhs.true.i.i694 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp79) + to label %invoke.cont.i702 unwind label %terminate.lpad.i705 + +invoke.cont.i702: ; preds = %if.then.i.i695, %land.lhs.true.i.i694, %invoke.cont89 + store i8* null, i8** %data.i680, align 8, !tbaa !63 + %157 = bitcast i8** %datastart.i681 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %157, i8 0, i64 24, i1 false) #16 + %158 = load i32*, i32** %p.i.i639, align 8, !tbaa !64 + store i32 0, i32* %158, align 4, !tbaa !61 + store i32* null, i32** %refcount.i649, align 8, !tbaa !62 + %159 = load i64*, i64** %p.i2.i641, align 8, !tbaa !72 + %cmp.i701 = icmp eq i64* %159, %arraydecay.i.i640 + br i1 %cmp.i701, label %_ZN2cv3MatD2Ev.exit706, label %if.then.i703 + +if.then.i703: ; preds = %invoke.cont.i702 + %160 = bitcast i64* %159 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %160) + to label %_ZN2cv3MatD2Ev.exit706 unwind label %terminate.lpad.i705 + +terminate.lpad.i705: ; preds = %if.then.i703, %if.then.i.i695 + %161 = landingpad { i8*, i32 } + catch i8* null + %162 = extractvalue { i8*, i32 } %161, 0 + call void @__clang_call_terminate(i8* %162) #18 + unreachable + +_ZN2cv3MatD2Ev.exit706: ; preds = %invoke.cont.i702, %if.then.i703 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %116) #16 + %163 = bitcast %"class.cv::Mat"* %ref.tmp93 to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %163) #16 + %164 = load i32*, i32** %p.i.i, align 8, !tbaa !56 + %165 = load i32, i32* %164, align 4, !tbaa !61 + %arrayidx.i709 = getelementptr inbounds i32, i32* %164, i64 1 + %166 = load i32, i32* %arrayidx.i709, align 4, !tbaa !61 + %rows.i711 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 2 + %p.i.i712 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 10, i32 0 + store i32* %rows.i711, i32** %p.i.i712, align 8, !tbaa !56 + %arraydecay.i.i713 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 11, i32 1, i64 0 + %p.i2.i714 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i713, i64** %p.i2.i714, align 8, !tbaa !57 + %167 = bitcast i64* %arraydecay.i.i713 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %167, i8 0, i64 16, i1 false) #16 + %flags.i.i715 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i715, align 8, !tbaa !37 + %dims.i3.i716 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 1 + %168 = bitcast i32* %dims.i3.i716 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %168, i8 0, i64 60, i1 false) #16 + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %74) #16 + store i32 %165, i32* %arrayinit.begin.i.i, align 4, !tbaa !61 + store i32 %166, i32* %arrayinit.element.i.i, align 4, !tbaa !61 + invoke void @_ZN2cv3Mat6createEiPKii(%"class.cv::Mat"* nonnull %ref.tmp93, i32 2, i32* nonnull %arrayinit.begin.i.i, i32 5) + to label %invoke.cont101 unwind label %lpad95 + +invoke.cont101: ; preds = %_ZN2cv3MatD2Ev.exit706 + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %74) #16 + %refcount.i722 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 5 + %169 = load i32*, i32** %refcount.i722, align 8, !tbaa !62 + %tobool.i723 = icmp eq i32* %169, null + br i1 %tobool.i723, label %if.end.i728, label %if.then2.i725 + +if.then2.i725: ; preds = %invoke.cont101 + %170 = atomicrmw add i32* %169, i32 1 seq_cst + br label %if.end.i728 + +if.end.i728: ; preds = %if.then2.i725, %invoke.cont101 + %refcount.i.i726 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 5 + %171 = load i32*, i32** %refcount.i.i726, align 8, !tbaa !62 + %tobool.i.i727 = icmp eq i32* %171, null + br i1 %tobool.i.i727, label %_ZN2cv3Mat7releaseEv.exit.i739, label %land.lhs.true.i.i730 + +land.lhs.true.i.i730: ; preds = %if.end.i728 + %172 = atomicrmw add i32* %171, i32 -1 seq_cst + %cmp.i.i729 = icmp eq i32 %172, 1 + br i1 %cmp.i.i729, label %if.then.i.i731, label %_ZN2cv3Mat7releaseEv.exit.i739 + +if.then.i.i731: ; preds = %land.lhs.true.i.i730 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %S) + to label %_ZN2cv3Mat7releaseEv.exit.i739 unwind label %lpad102 + +_ZN2cv3Mat7releaseEv.exit.i739: ; preds = %if.then.i.i731, %land.lhs.true.i.i730, %if.end.i728 + %datastart.i.i732 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 6 + %data.i.i733 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 4 + store i8* null, i8** %data.i.i733, align 8, !tbaa !63 + %173 = bitcast i8** %datastart.i.i732 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %173, i8 0, i64 24, i1 false) + %174 = load i32*, i32** %p.i.i558, align 8, !tbaa !64 + store i32 0, i32* %174, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i726, align 8, !tbaa !62 + %175 = load i32, i32* %flags.i.i715, align 8, !tbaa !37 + store i32 %175, i32* %flags.i.i561, align 8, !tbaa !37 + %176 = load i32, i32* %dims.i.i562, align 4, !tbaa !65 + %cmp5.i738 = icmp slt i32 %176, 3 + br i1 %cmp5.i738, label %land.lhs.true.i742, label %if.else.i752 + +land.lhs.true.i742: ; preds = %_ZN2cv3Mat7releaseEv.exit.i739 + %177 = load i32, i32* %dims.i3.i716, align 4, !tbaa !65 + %cmp7.i741 = icmp slt i32 %177, 3 + br i1 %cmp7.i741, label %if.then8.i751, label %if.else.i752 + +if.then8.i751: ; preds = %land.lhs.true.i742 + store i32 %177, i32* %dims.i.i562, align 4, !tbaa !65 + %178 = load i32, i32* %rows.i711, align 8, !tbaa !66 + store i32 %178, i32* %rows.i557, align 8, !tbaa !66 + %cols.i745 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 3 + %179 = load i32, i32* %cols.i745, align 4, !tbaa !67 + %cols12.i746 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 3 + store i32 %179, i32* %cols12.i746, align 4, !tbaa !67 + %180 = load i64*, i64** %p.i2.i714, align 8, !tbaa !57 + %181 = load i64, i64* %180, align 8, !tbaa !51 + %182 = load i64*, i64** %p.i2.i560, align 8, !tbaa !57 + store i64 %181, i64* %182, align 8, !tbaa !51 + %arrayidx.i48.i749 = getelementptr inbounds i64, i64* %180, i64 1 + %183 = load i64, i64* %arrayidx.i48.i749, align 8, !tbaa !51 + %arrayidx.i.i750 = getelementptr inbounds i64, i64* %182, i64 1 + store i64 %183, i64* %arrayidx.i.i750, align 8, !tbaa !51 + br label %invoke.cont103 + +if.else.i752: ; preds = %land.lhs.true.i742, %_ZN2cv3Mat7releaseEv.exit.i739 + invoke void @_ZN2cv3Mat8copySizeERKS0_(%"class.cv::Mat"* nonnull %S, %"class.cv::Mat"* nonnull dereferenceable(96) %ref.tmp93) + to label %invoke.cont103 unwind label %lpad102 + +invoke.cont103: ; preds = %if.then8.i751, %if.else.i752 + %data.i753 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 4 + %184 = bitcast i8** %data.i753 to i64* + %185 = load i64, i64* %184, align 8, !tbaa !63 + %186 = bitcast i8** %data.i.i733 to i64* + store i64 %185, i64* %186, align 8, !tbaa !63 + %datastart.i754 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 6 + %187 = bitcast i8** %datastart.i754 to i64* + %188 = load i64, i64* %187, align 8, !tbaa !68 + %189 = bitcast i8** %datastart.i.i732 to i64* + store i64 %188, i64* %189, align 8, !tbaa !68 + %dataend.i755 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 7 + %190 = bitcast i8** %dataend.i755 to i64* + %191 = load i64, i64* %190, align 8, !tbaa !69 + %dataend22.i756 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 7 + %192 = bitcast i8** %dataend22.i756 to i64* + store i64 %191, i64* %192, align 8, !tbaa !69 + %datalimit.i757 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 8 + %193 = bitcast i8** %datalimit.i757 to i64* + %194 = load i64, i64* %193, align 8, !tbaa !70 + %datalimit23.i758 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 8 + %195 = bitcast i8** %datalimit23.i758 to i64* + store i64 %194, i64* %195, align 8, !tbaa !70 + %196 = bitcast i32** %refcount.i722 to i64* + %197 = load i64, i64* %196, align 8, !tbaa !62 + %198 = bitcast i32** %refcount.i.i726 to i64* + store i64 %197, i64* %198, align 8, !tbaa !62 + %allocator.i759 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 9 + %199 = bitcast %"class.cv::MatAllocator"** %allocator.i759 to i64* + %200 = load i64, i64* %199, align 8, !tbaa !71 + %allocator26.i760 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 9 + %201 = bitcast %"class.cv::MatAllocator"** %allocator26.i760 to i64* + store i64 %200, i64* %201, align 8, !tbaa !71 + %tobool.i.i765 = icmp eq i64 %197, 0 + br i1 %tobool.i.i765, label %invoke.cont.i775, label %land.lhs.true.i.i767 + +land.lhs.true.i.i767: ; preds = %invoke.cont103 + %202 = inttoptr i64 %197 to i32* + %203 = atomicrmw add i32* %202, i32 -1 seq_cst + %cmp.i.i766 = icmp eq i32 %203, 1 + br i1 %cmp.i.i766, label %if.then.i.i768, label %invoke.cont.i775 + +if.then.i.i768: ; preds = %land.lhs.true.i.i767 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp93) + to label %invoke.cont.i775 unwind label %terminate.lpad.i778 + +invoke.cont.i775: ; preds = %if.then.i.i768, %land.lhs.true.i.i767, %invoke.cont103 + store i8* null, i8** %data.i753, align 8, !tbaa !63 + %204 = bitcast i8** %datastart.i754 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %204, i8 0, i64 24, i1 false) #16 + %205 = load i32*, i32** %p.i.i712, align 8, !tbaa !64 + store i32 0, i32* %205, align 4, !tbaa !61 + store i32* null, i32** %refcount.i722, align 8, !tbaa !62 + %206 = load i64*, i64** %p.i2.i714, align 8, !tbaa !72 + %cmp.i774 = icmp eq i64* %206, %arraydecay.i.i713 + br i1 %cmp.i774, label %_ZN2cv3MatD2Ev.exit779, label %if.then.i776 + +if.then.i776: ; preds = %invoke.cont.i775 + %207 = bitcast i64* %206 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %207) + to label %_ZN2cv3MatD2Ev.exit779 unwind label %terminate.lpad.i778 + +terminate.lpad.i778: ; preds = %if.then.i776, %if.then.i.i768 + %208 = landingpad { i8*, i32 } + catch i8* null + %209 = extractvalue { i8*, i32 } %208, 0 + call void @__clang_call_terminate(i8* %209) #18 + unreachable + +_ZN2cv3MatD2Ev.exit779: ; preds = %invoke.cont.i775, %if.then.i776 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %163) #16 + %210 = bitcast %"class.cv::Mat"* %ref.tmp107 to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %210) #16 + %211 = load i32*, i32** %p.i.i, align 8, !tbaa !56 + %212 = load i32, i32* %211, align 4, !tbaa !61 + %arrayidx.i782 = getelementptr inbounds i32, i32* %211, i64 1 + %213 = load i32, i32* %arrayidx.i782, align 4, !tbaa !61 + %rows.i784 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 2 + %p.i.i785 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 10, i32 0 + store i32* %rows.i784, i32** %p.i.i785, align 8, !tbaa !56 + %arraydecay.i.i786 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 11, i32 1, i64 0 + %p.i2.i787 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i786, i64** %p.i2.i787, align 8, !tbaa !57 + %214 = bitcast i64* %arraydecay.i.i786 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %214, i8 0, i64 16, i1 false) #16 + %flags.i.i788 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i788, align 8, !tbaa !37 + %dims.i3.i789 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 1 + %215 = bitcast i32* %dims.i3.i789 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %215, i8 0, i64 60, i1 false) #16 + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %74) #16 + store i32 %212, i32* %arrayinit.begin.i.i, align 4, !tbaa !61 + store i32 %213, i32* %arrayinit.element.i.i, align 4, !tbaa !61 + invoke void @_ZN2cv3Mat6createEiPKii(%"class.cv::Mat"* nonnull %ref.tmp107, i32 2, i32* nonnull %arrayinit.begin.i.i, i32 5) + to label %invoke.cont115 unwind label %lpad109 + +invoke.cont115: ; preds = %_ZN2cv3MatD2Ev.exit779 + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %74) #16 + %refcount.i795 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 5 + %216 = load i32*, i32** %refcount.i795, align 8, !tbaa !62 + %tobool.i796 = icmp eq i32* %216, null + br i1 %tobool.i796, label %if.end.i801, label %if.then2.i798 + +if.then2.i798: ; preds = %invoke.cont115 + %217 = atomicrmw add i32* %216, i32 1 seq_cst + br label %if.end.i801 + +if.end.i801: ; preds = %if.then2.i798, %invoke.cont115 + %refcount.i.i799 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 5 + %218 = load i32*, i32** %refcount.i.i799, align 8, !tbaa !62 + %tobool.i.i800 = icmp eq i32* %218, null + br i1 %tobool.i.i800, label %_ZN2cv3Mat7releaseEv.exit.i812, label %land.lhs.true.i.i803 + +land.lhs.true.i.i803: ; preds = %if.end.i801 + %219 = atomicrmw add i32* %218, i32 -1 seq_cst + %cmp.i.i802 = icmp eq i32 %219, 1 + br i1 %cmp.i.i802, label %if.then.i.i804, label %_ZN2cv3Mat7releaseEv.exit.i812 + +if.then.i.i804: ; preds = %land.lhs.true.i.i803 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %G) + to label %_ZN2cv3Mat7releaseEv.exit.i812 unwind label %lpad116 + +_ZN2cv3Mat7releaseEv.exit.i812: ; preds = %if.then.i.i804, %land.lhs.true.i.i803, %if.end.i801 + %datastart.i.i805 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 6 + %data.i.i806 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 4 + store i8* null, i8** %data.i.i806, align 8, !tbaa !63 + %220 = bitcast i8** %datastart.i.i805 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %220, i8 0, i64 24, i1 false) + %221 = load i32*, i32** %p.i.i564, align 8, !tbaa !64 + store i32 0, i32* %221, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i799, align 8, !tbaa !62 + %222 = load i32, i32* %flags.i.i788, align 8, !tbaa !37 + store i32 %222, i32* %flags.i.i567, align 8, !tbaa !37 + %223 = load i32, i32* %dims.i.i568, align 4, !tbaa !65 + %cmp5.i811 = icmp slt i32 %223, 3 + br i1 %cmp5.i811, label %land.lhs.true.i815, label %if.else.i825 + +land.lhs.true.i815: ; preds = %_ZN2cv3Mat7releaseEv.exit.i812 + %224 = load i32, i32* %dims.i3.i789, align 4, !tbaa !65 + %cmp7.i814 = icmp slt i32 %224, 3 + br i1 %cmp7.i814, label %if.then8.i824, label %if.else.i825 + +if.then8.i824: ; preds = %land.lhs.true.i815 + store i32 %224, i32* %dims.i.i568, align 4, !tbaa !65 + %225 = load i32, i32* %rows.i784, align 8, !tbaa !66 + store i32 %225, i32* %rows.i563, align 8, !tbaa !66 + %cols.i818 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 3 + %226 = load i32, i32* %cols.i818, align 4, !tbaa !67 + %cols12.i819 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 3 + store i32 %226, i32* %cols12.i819, align 4, !tbaa !67 + %227 = load i64*, i64** %p.i2.i787, align 8, !tbaa !57 + %228 = load i64, i64* %227, align 8, !tbaa !51 + %229 = load i64*, i64** %p.i2.i566, align 8, !tbaa !57 + store i64 %228, i64* %229, align 8, !tbaa !51 + %arrayidx.i48.i822 = getelementptr inbounds i64, i64* %227, i64 1 + %230 = load i64, i64* %arrayidx.i48.i822, align 8, !tbaa !51 + %arrayidx.i.i823 = getelementptr inbounds i64, i64* %229, i64 1 + store i64 %230, i64* %arrayidx.i.i823, align 8, !tbaa !51 + br label %invoke.cont117 + +if.else.i825: ; preds = %land.lhs.true.i815, %_ZN2cv3Mat7releaseEv.exit.i812 + invoke void @_ZN2cv3Mat8copySizeERKS0_(%"class.cv::Mat"* nonnull %G, %"class.cv::Mat"* nonnull dereferenceable(96) %ref.tmp107) + to label %invoke.cont117 unwind label %lpad116 + +invoke.cont117: ; preds = %if.then8.i824, %if.else.i825 + %data.i826 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 4 + %231 = bitcast i8** %data.i826 to i64* + %232 = load i64, i64* %231, align 8, !tbaa !63 + %233 = bitcast i8** %data.i.i806 to i64* + store i64 %232, i64* %233, align 8, !tbaa !63 + %datastart.i827 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 6 + %234 = bitcast i8** %datastart.i827 to i64* + %235 = load i64, i64* %234, align 8, !tbaa !68 + %236 = bitcast i8** %datastart.i.i805 to i64* + store i64 %235, i64* %236, align 8, !tbaa !68 + %dataend.i828 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 7 + %237 = bitcast i8** %dataend.i828 to i64* + %238 = load i64, i64* %237, align 8, !tbaa !69 + %dataend22.i829 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 7 + %239 = bitcast i8** %dataend22.i829 to i64* + store i64 %238, i64* %239, align 8, !tbaa !69 + %datalimit.i830 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 8 + %240 = bitcast i8** %datalimit.i830 to i64* + %241 = load i64, i64* %240, align 8, !tbaa !70 + %datalimit23.i831 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 8 + %242 = bitcast i8** %datalimit23.i831 to i64* + store i64 %241, i64* %242, align 8, !tbaa !70 + %243 = bitcast i32** %refcount.i795 to i64* + %244 = load i64, i64* %243, align 8, !tbaa !62 + %245 = bitcast i32** %refcount.i.i799 to i64* + store i64 %244, i64* %245, align 8, !tbaa !62 + %allocator.i832 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 9 + %246 = bitcast %"class.cv::MatAllocator"** %allocator.i832 to i64* + %247 = load i64, i64* %246, align 8, !tbaa !71 + %allocator26.i833 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 9 + %248 = bitcast %"class.cv::MatAllocator"** %allocator26.i833 to i64* + store i64 %247, i64* %248, align 8, !tbaa !71 + %tobool.i.i838 = icmp eq i64 %244, 0 + br i1 %tobool.i.i838, label %invoke.cont.i848, label %land.lhs.true.i.i840 + +land.lhs.true.i.i840: ; preds = %invoke.cont117 + %249 = inttoptr i64 %244 to i32* + %250 = atomicrmw add i32* %249, i32 -1 seq_cst + %cmp.i.i839 = icmp eq i32 %250, 1 + br i1 %cmp.i.i839, label %if.then.i.i841, label %invoke.cont.i848 + +if.then.i.i841: ; preds = %land.lhs.true.i.i840 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp107) + to label %invoke.cont.i848 unwind label %terminate.lpad.i851 + +invoke.cont.i848: ; preds = %if.then.i.i841, %land.lhs.true.i.i840, %invoke.cont117 + store i8* null, i8** %data.i826, align 8, !tbaa !63 + %251 = bitcast i8** %datastart.i827 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %251, i8 0, i64 24, i1 false) #16 + %252 = load i32*, i32** %p.i.i785, align 8, !tbaa !64 + store i32 0, i32* %252, align 4, !tbaa !61 + store i32* null, i32** %refcount.i795, align 8, !tbaa !62 + %253 = load i64*, i64** %p.i2.i787, align 8, !tbaa !72 + %cmp.i847 = icmp eq i64* %253, %arraydecay.i.i786 + br i1 %cmp.i847, label %_ZN2cv3MatD2Ev.exit852, label %if.then.i849 + +if.then.i849: ; preds = %invoke.cont.i848 + %254 = bitcast i64* %253 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %254) + to label %_ZN2cv3MatD2Ev.exit852 unwind label %terminate.lpad.i851 + +terminate.lpad.i851: ; preds = %if.then.i849, %if.then.i.i841 + %255 = landingpad { i8*, i32 } + catch i8* null + %256 = extractvalue { i8*, i32 } %255, 0 + call void @__clang_call_terminate(i8* %256) #18 + unreachable + +_ZN2cv3MatD2Ev.exit852: ; preds = %invoke.cont.i848, %if.then.i849 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %210) #16 + %257 = bitcast %"class.cv::Mat"* %ref.tmp121 to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %257) #16 + %258 = load i32*, i32** %p.i.i, align 8, !tbaa !56 + %259 = load i32, i32* %258, align 4, !tbaa !61 + %arrayidx.i855 = getelementptr inbounds i32, i32* %258, i64 1 + %260 = load i32, i32* %arrayidx.i855, align 4, !tbaa !61 + %rows.i857 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 2 + %p.i.i858 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 10, i32 0 + store i32* %rows.i857, i32** %p.i.i858, align 8, !tbaa !56 + %arraydecay.i.i859 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 11, i32 1, i64 0 + %p.i2.i860 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i859, i64** %p.i2.i860, align 8, !tbaa !57 + %261 = bitcast i64* %arraydecay.i.i859 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %261, i8 0, i64 16, i1 false) #16 + %flags.i.i861 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i861, align 8, !tbaa !37 + %dims.i3.i862 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 1 + %262 = bitcast i32* %dims.i3.i862 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %262, i8 0, i64 60, i1 false) #16 + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %74) #16 + store i32 %259, i32* %arrayinit.begin.i.i, align 4, !tbaa !61 + store i32 %260, i32* %arrayinit.element.i.i, align 4, !tbaa !61 + invoke void @_ZN2cv3Mat6createEiPKii(%"class.cv::Mat"* nonnull %ref.tmp121, i32 2, i32* nonnull %arrayinit.begin.i.i, i32 5) + to label %invoke.cont129 unwind label %lpad123 + +invoke.cont129: ; preds = %_ZN2cv3MatD2Ev.exit852 + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %74) #16 + %refcount.i868 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 5 + %263 = load i32*, i32** %refcount.i868, align 8, !tbaa !62 + %tobool.i869 = icmp eq i32* %263, null + br i1 %tobool.i869, label %if.end.i874, label %if.then2.i871 + +if.then2.i871: ; preds = %invoke.cont129 + %264 = atomicrmw add i32* %263, i32 1 seq_cst + br label %if.end.i874 + +if.end.i874: ; preds = %if.then2.i871, %invoke.cont129 + %refcount.i.i872 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 5 + %265 = load i32*, i32** %refcount.i.i872, align 8, !tbaa !62 + %tobool.i.i873 = icmp eq i32* %265, null + br i1 %tobool.i.i873, label %_ZN2cv3Mat7releaseEv.exit.i885, label %land.lhs.true.i.i876 + +land.lhs.true.i.i876: ; preds = %if.end.i874 + %266 = atomicrmw add i32* %265, i32 -1 seq_cst + %cmp.i.i875 = icmp eq i32 %266, 1 + br i1 %cmp.i.i875, label %if.then.i.i877, label %_ZN2cv3Mat7releaseEv.exit.i885 + +if.then.i.i877: ; preds = %land.lhs.true.i.i876 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %E) + to label %_ZN2cv3Mat7releaseEv.exit.i885 unwind label %lpad130 + +_ZN2cv3Mat7releaseEv.exit.i885: ; preds = %if.then.i.i877, %land.lhs.true.i.i876, %if.end.i874 + %datastart.i.i878 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 6 + %data.i.i879 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 4 + store i8* null, i8** %data.i.i879, align 8, !tbaa !63 + %267 = bitcast i8** %datastart.i.i878 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %267, i8 0, i64 24, i1 false) + %268 = load i32*, i32** %p.i.i570, align 8, !tbaa !64 + store i32 0, i32* %268, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i872, align 8, !tbaa !62 + %269 = load i32, i32* %flags.i.i861, align 8, !tbaa !37 + store i32 %269, i32* %flags.i.i573, align 8, !tbaa !37 + %270 = load i32, i32* %dims.i.i574, align 4, !tbaa !65 + %cmp5.i884 = icmp slt i32 %270, 3 + br i1 %cmp5.i884, label %land.lhs.true.i888, label %if.else.i898 + +land.lhs.true.i888: ; preds = %_ZN2cv3Mat7releaseEv.exit.i885 + %271 = load i32, i32* %dims.i3.i862, align 4, !tbaa !65 + %cmp7.i887 = icmp slt i32 %271, 3 + br i1 %cmp7.i887, label %if.then8.i897, label %if.else.i898 + +if.then8.i897: ; preds = %land.lhs.true.i888 + store i32 %271, i32* %dims.i.i574, align 4, !tbaa !65 + %272 = load i32, i32* %rows.i857, align 8, !tbaa !66 + store i32 %272, i32* %rows.i569, align 8, !tbaa !66 + %cols.i891 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 3 + %273 = load i32, i32* %cols.i891, align 4, !tbaa !67 + %cols12.i892 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 3 + store i32 %273, i32* %cols12.i892, align 4, !tbaa !67 + %274 = load i64*, i64** %p.i2.i860, align 8, !tbaa !57 + %275 = load i64, i64* %274, align 8, !tbaa !51 + %276 = load i64*, i64** %p.i2.i572, align 8, !tbaa !57 + store i64 %275, i64* %276, align 8, !tbaa !51 + %arrayidx.i48.i895 = getelementptr inbounds i64, i64* %274, i64 1 + %277 = load i64, i64* %arrayidx.i48.i895, align 8, !tbaa !51 + %arrayidx.i.i896 = getelementptr inbounds i64, i64* %276, i64 1 + store i64 %277, i64* %arrayidx.i.i896, align 8, !tbaa !51 + br label %invoke.cont131 + +if.else.i898: ; preds = %land.lhs.true.i888, %_ZN2cv3Mat7releaseEv.exit.i885 + invoke void @_ZN2cv3Mat8copySizeERKS0_(%"class.cv::Mat"* nonnull %E, %"class.cv::Mat"* nonnull dereferenceable(96) %ref.tmp121) + to label %invoke.cont131 unwind label %lpad130 + +invoke.cont131: ; preds = %if.then8.i897, %if.else.i898 + %data.i899 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 4 + %278 = bitcast i8** %data.i899 to i64* + %279 = load i64, i64* %278, align 8, !tbaa !63 + %280 = bitcast i8** %data.i.i879 to i64* + store i64 %279, i64* %280, align 8, !tbaa !63 + %datastart.i900 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 6 + %281 = bitcast i8** %datastart.i900 to i64* + %282 = load i64, i64* %281, align 8, !tbaa !68 + %283 = bitcast i8** %datastart.i.i878 to i64* + store i64 %282, i64* %283, align 8, !tbaa !68 + %dataend.i901 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 7 + %284 = bitcast i8** %dataend.i901 to i64* + %285 = load i64, i64* %284, align 8, !tbaa !69 + %dataend22.i902 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 7 + %286 = bitcast i8** %dataend22.i902 to i64* + store i64 %285, i64* %286, align 8, !tbaa !69 + %datalimit.i903 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 8 + %287 = bitcast i8** %datalimit.i903 to i64* + %288 = load i64, i64* %287, align 8, !tbaa !70 + %datalimit23.i904 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 8 + %289 = bitcast i8** %datalimit23.i904 to i64* + store i64 %288, i64* %289, align 8, !tbaa !70 + %290 = bitcast i32** %refcount.i868 to i64* + %291 = load i64, i64* %290, align 8, !tbaa !62 + %292 = bitcast i32** %refcount.i.i872 to i64* + store i64 %291, i64* %292, align 8, !tbaa !62 + %allocator.i905 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 9 + %293 = bitcast %"class.cv::MatAllocator"** %allocator.i905 to i64* + %294 = load i64, i64* %293, align 8, !tbaa !71 + %allocator26.i906 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 9 + %295 = bitcast %"class.cv::MatAllocator"** %allocator26.i906 to i64* + store i64 %294, i64* %295, align 8, !tbaa !71 + %tobool.i.i911 = icmp eq i64 %291, 0 + br i1 %tobool.i.i911, label %invoke.cont.i921, label %land.lhs.true.i.i913 + +land.lhs.true.i.i913: ; preds = %invoke.cont131 + %296 = inttoptr i64 %291 to i32* + %297 = atomicrmw add i32* %296, i32 -1 seq_cst + %cmp.i.i912 = icmp eq i32 %297, 1 + br i1 %cmp.i.i912, label %if.then.i.i914, label %invoke.cont.i921 + +if.then.i.i914: ; preds = %land.lhs.true.i.i913 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp121) + to label %invoke.cont.i921 unwind label %terminate.lpad.i924 + +invoke.cont.i921: ; preds = %if.then.i.i914, %land.lhs.true.i.i913, %invoke.cont131 + store i8* null, i8** %data.i899, align 8, !tbaa !63 + %298 = bitcast i8** %datastart.i900 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %298, i8 0, i64 24, i1 false) #16 + %299 = load i32*, i32** %p.i.i858, align 8, !tbaa !64 + store i32 0, i32* %299, align 4, !tbaa !61 + store i32* null, i32** %refcount.i868, align 8, !tbaa !62 + %300 = load i64*, i64** %p.i2.i860, align 8, !tbaa !72 + %cmp.i920 = icmp eq i64* %300, %arraydecay.i.i859 + br i1 %cmp.i920, label %_ZN2cv3MatD2Ev.exit925, label %if.then.i922 + +if.then.i922: ; preds = %invoke.cont.i921 + %301 = bitcast i64* %300 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %301) + to label %_ZN2cv3MatD2Ev.exit925 unwind label %terminate.lpad.i924 + +terminate.lpad.i924: ; preds = %if.then.i922, %if.then.i.i914 + %302 = landingpad { i8*, i32 } + catch i8* null + %303 = extractvalue { i8*, i32 } %302, 0 + call void @__clang_call_terminate(i8* %303) #18 + unreachable + +_ZN2cv3MatD2Ev.exit925: ; preds = %invoke.cont.i921, %if.then.i922 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %257) #16 + %304 = load i32, i32* %flags.i.i, align 8, !tbaa !37 + %and.i927 = and i32 %304, 16384 + %cmp.i928 = icmp eq i32 %and.i927, 0 + br i1 %cmp.i928, label %cond.false, label %land.lhs.true + +land.lhs.true: ; preds = %_ZN2cv3MatD2Ev.exit925 + %305 = load i32, i32* %flags.i.i549, align 8, !tbaa !37 + %and.i930 = and i32 %305, 16384 + %cmp.i931 = icmp eq i32 %and.i930, 0 + br i1 %cmp.i931, label %cond.false, label %land.lhs.true139 + +land.lhs.true139: ; preds = %land.lhs.true + %306 = load i32, i32* %flags.i.i555, align 8, !tbaa !37 + %and.i933 = and i32 %306, 16384 + %cmp.i934 = icmp eq i32 %and.i933, 0 + br i1 %cmp.i934, label %cond.false, label %land.lhs.true142 + +land.lhs.true142: ; preds = %land.lhs.true139 + %307 = load i32, i32* %flags.i.i561, align 8, !tbaa !37 + %and.i936 = and i32 %307, 16384 + %cmp.i937 = icmp eq i32 %and.i936, 0 + br i1 %cmp.i937, label %cond.false, label %land.lhs.true145 + +land.lhs.true145: ; preds = %land.lhs.true142 + %308 = load i32, i32* %flags.i.i567, align 8, !tbaa !37 + %and.i939 = and i32 %308, 16384 + %cmp.i940 = icmp eq i32 %and.i939, 0 + br i1 %cmp.i940, label %cond.false, label %land.lhs.true148 + +land.lhs.true148: ; preds = %land.lhs.true145 + %309 = load i32, i32* %flags.i.i573, align 8, !tbaa !37 + %and.i942 = and i32 %309, 16384 + %cmp.i943 = icmp eq i32 %and.i942, 0 + br i1 %cmp.i943, label %cond.false, label %cond.end + +cond.false: ; preds = %land.lhs.true148, %land.lhs.true145, %land.lhs.true142, %land.lhs.true139, %land.lhs.true, %_ZN2cv3MatD2Ev.exit925 + call void @__assert_fail(i8* getelementptr inbounds ([120 x i8], [120 x i8]* @.str.14, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.15, i64 0, i64 0), i32 813, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @__PRETTY_FUNCTION__.main, i64 0, i64 0)) #18 + unreachable + +lpad67: ; preds = %if.end64 + %310 = landingpad { i8*, i32 } + cleanup + %311 = extractvalue { i8*, i32 } %310, 0 + %312 = extractvalue { i8*, i32 } %310, 1 + br label %ehcleanup78 + +lpad74: ; preds = %if.else.i619, %if.then.i.i615 + %313 = landingpad { i8*, i32 } + cleanup + %314 = extractvalue { i8*, i32 } %313, 0 + %315 = extractvalue { i8*, i32 } %313, 1 + %316 = load i32*, i32** %refcount.i, align 8, !tbaa !62 + %tobool.i.i945 = icmp eq i32* %316, null + br i1 %tobool.i.i945, label %invoke.cont.i955, label %land.lhs.true.i.i947 + +land.lhs.true.i.i947: ; preds = %lpad74 + %317 = atomicrmw add i32* %316, i32 -1 seq_cst + %cmp.i.i946 = icmp eq i32 %317, 1 + br i1 %cmp.i.i946, label %if.then.i.i948, label %invoke.cont.i955 + +if.then.i.i948: ; preds = %land.lhs.true.i.i947 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp65) + to label %invoke.cont.i955 unwind label %terminate.lpad.i958 + +invoke.cont.i955: ; preds = %if.then.i.i948, %land.lhs.true.i.i947, %lpad74 + %datastart.i.i949 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 6 + %data.i.i950 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp65, i64 0, i32 4 + store i8* null, i8** %data.i.i950, align 8, !tbaa !63 + %318 = bitcast i8** %datastart.i.i949 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %318, i8 0, i64 24, i1 false) #16 + %319 = load i32*, i32** %p.i.i607, align 8, !tbaa !64 + store i32 0, i32* %319, align 4, !tbaa !61 + store i32* null, i32** %refcount.i, align 8, !tbaa !62 + %320 = load i64*, i64** %p.i2.i609, align 8, !tbaa !72 + %cmp.i954 = icmp eq i64* %320, %arraydecay.i.i608 + br i1 %cmp.i954, label %ehcleanup78, label %if.then.i956 + +if.then.i956: ; preds = %invoke.cont.i955 + %321 = bitcast i64* %320 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %321) + to label %ehcleanup78 unwind label %terminate.lpad.i958 + +terminate.lpad.i958: ; preds = %if.then.i956, %if.then.i.i948 + %322 = landingpad { i8*, i32 } + catch i8* null + %323 = extractvalue { i8*, i32 } %322, 0 + call void @__clang_call_terminate(i8* %323) #18 + unreachable + +ehcleanup78: ; preds = %if.then.i956, %invoke.cont.i955, %lpad67 + %ehselector.slot.1 = phi i32 [ %312, %lpad67 ], [ %315, %invoke.cont.i955 ], [ %315, %if.then.i956 ] + %exn.slot.1 = phi i8* [ %311, %lpad67 ], [ %314, %invoke.cont.i955 ], [ %314, %if.then.i956 ] + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %68) #16 + br label %ehcleanup405 + +lpad81: ; preds = %_ZN2cv3MatD2Ev.exit + %324 = landingpad { i8*, i32 } + cleanup + %325 = extractvalue { i8*, i32 } %324, 0 + %326 = extractvalue { i8*, i32 } %324, 1 + br label %ehcleanup92 + +lpad88: ; preds = %if.else.i679, %if.then.i.i658 + %327 = landingpad { i8*, i32 } + cleanup + %328 = extractvalue { i8*, i32 } %327, 0 + %329 = extractvalue { i8*, i32 } %327, 1 + %330 = load i32*, i32** %refcount.i649, align 8, !tbaa !62 + %tobool.i.i961 = icmp eq i32* %330, null + br i1 %tobool.i.i961, label %invoke.cont.i971, label %land.lhs.true.i.i963 + +land.lhs.true.i.i963: ; preds = %lpad88 + %331 = atomicrmw add i32* %330, i32 -1 seq_cst + %cmp.i.i962 = icmp eq i32 %331, 1 + br i1 %cmp.i.i962, label %if.then.i.i964, label %invoke.cont.i971 + +if.then.i.i964: ; preds = %land.lhs.true.i.i963 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp79) + to label %invoke.cont.i971 unwind label %terminate.lpad.i974 + +invoke.cont.i971: ; preds = %if.then.i.i964, %land.lhs.true.i.i963, %lpad88 + %datastart.i.i965 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 6 + %data.i.i966 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp79, i64 0, i32 4 + store i8* null, i8** %data.i.i966, align 8, !tbaa !63 + %332 = bitcast i8** %datastart.i.i965 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %332, i8 0, i64 24, i1 false) #16 + %333 = load i32*, i32** %p.i.i639, align 8, !tbaa !64 + store i32 0, i32* %333, align 4, !tbaa !61 + store i32* null, i32** %refcount.i649, align 8, !tbaa !62 + %334 = load i64*, i64** %p.i2.i641, align 8, !tbaa !72 + %cmp.i970 = icmp eq i64* %334, %arraydecay.i.i640 + br i1 %cmp.i970, label %ehcleanup92, label %if.then.i972 + +if.then.i972: ; preds = %invoke.cont.i971 + %335 = bitcast i64* %334 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %335) + to label %ehcleanup92 unwind label %terminate.lpad.i974 + +terminate.lpad.i974: ; preds = %if.then.i972, %if.then.i.i964 + %336 = landingpad { i8*, i32 } + catch i8* null + %337 = extractvalue { i8*, i32 } %336, 0 + call void @__clang_call_terminate(i8* %337) #18 + unreachable + +ehcleanup92: ; preds = %if.then.i972, %invoke.cont.i971, %lpad81 + %ehselector.slot.2 = phi i32 [ %326, %lpad81 ], [ %329, %invoke.cont.i971 ], [ %329, %if.then.i972 ] + %exn.slot.2 = phi i8* [ %325, %lpad81 ], [ %328, %invoke.cont.i971 ], [ %328, %if.then.i972 ] + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %116) #16 + br label %ehcleanup405 + +lpad95: ; preds = %_ZN2cv3MatD2Ev.exit706 + %338 = landingpad { i8*, i32 } + cleanup + %339 = extractvalue { i8*, i32 } %338, 0 + %340 = extractvalue { i8*, i32 } %338, 1 + br label %ehcleanup106 + +lpad102: ; preds = %if.else.i752, %if.then.i.i731 + %341 = landingpad { i8*, i32 } + cleanup + %342 = extractvalue { i8*, i32 } %341, 0 + %343 = extractvalue { i8*, i32 } %341, 1 + %344 = load i32*, i32** %refcount.i722, align 8, !tbaa !62 + %tobool.i.i977 = icmp eq i32* %344, null + br i1 %tobool.i.i977, label %invoke.cont.i987, label %land.lhs.true.i.i979 + +land.lhs.true.i.i979: ; preds = %lpad102 + %345 = atomicrmw add i32* %344, i32 -1 seq_cst + %cmp.i.i978 = icmp eq i32 %345, 1 + br i1 %cmp.i.i978, label %if.then.i.i980, label %invoke.cont.i987 + +if.then.i.i980: ; preds = %land.lhs.true.i.i979 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp93) + to label %invoke.cont.i987 unwind label %terminate.lpad.i990 + +invoke.cont.i987: ; preds = %if.then.i.i980, %land.lhs.true.i.i979, %lpad102 + %datastart.i.i981 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 6 + %data.i.i982 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp93, i64 0, i32 4 + store i8* null, i8** %data.i.i982, align 8, !tbaa !63 + %346 = bitcast i8** %datastart.i.i981 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %346, i8 0, i64 24, i1 false) #16 + %347 = load i32*, i32** %p.i.i712, align 8, !tbaa !64 + store i32 0, i32* %347, align 4, !tbaa !61 + store i32* null, i32** %refcount.i722, align 8, !tbaa !62 + %348 = load i64*, i64** %p.i2.i714, align 8, !tbaa !72 + %cmp.i986 = icmp eq i64* %348, %arraydecay.i.i713 + br i1 %cmp.i986, label %ehcleanup106, label %if.then.i988 + +if.then.i988: ; preds = %invoke.cont.i987 + %349 = bitcast i64* %348 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %349) + to label %ehcleanup106 unwind label %terminate.lpad.i990 + +terminate.lpad.i990: ; preds = %if.then.i988, %if.then.i.i980 + %350 = landingpad { i8*, i32 } + catch i8* null + %351 = extractvalue { i8*, i32 } %350, 0 + call void @__clang_call_terminate(i8* %351) #18 + unreachable + +ehcleanup106: ; preds = %if.then.i988, %invoke.cont.i987, %lpad95 + %ehselector.slot.3 = phi i32 [ %340, %lpad95 ], [ %343, %invoke.cont.i987 ], [ %343, %if.then.i988 ] + %exn.slot.3 = phi i8* [ %339, %lpad95 ], [ %342, %invoke.cont.i987 ], [ %342, %if.then.i988 ] + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %163) #16 + br label %ehcleanup405 + +lpad109: ; preds = %_ZN2cv3MatD2Ev.exit779 + %352 = landingpad { i8*, i32 } + cleanup + %353 = extractvalue { i8*, i32 } %352, 0 + %354 = extractvalue { i8*, i32 } %352, 1 + br label %ehcleanup120 + +lpad116: ; preds = %if.else.i825, %if.then.i.i804 + %355 = landingpad { i8*, i32 } + cleanup + %356 = extractvalue { i8*, i32 } %355, 0 + %357 = extractvalue { i8*, i32 } %355, 1 + %358 = load i32*, i32** %refcount.i795, align 8, !tbaa !62 + %tobool.i.i993 = icmp eq i32* %358, null + br i1 %tobool.i.i993, label %invoke.cont.i1003, label %land.lhs.true.i.i995 + +land.lhs.true.i.i995: ; preds = %lpad116 + %359 = atomicrmw add i32* %358, i32 -1 seq_cst + %cmp.i.i994 = icmp eq i32 %359, 1 + br i1 %cmp.i.i994, label %if.then.i.i996, label %invoke.cont.i1003 + +if.then.i.i996: ; preds = %land.lhs.true.i.i995 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp107) + to label %invoke.cont.i1003 unwind label %terminate.lpad.i1006 + +invoke.cont.i1003: ; preds = %if.then.i.i996, %land.lhs.true.i.i995, %lpad116 + %datastart.i.i997 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 6 + %data.i.i998 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp107, i64 0, i32 4 + store i8* null, i8** %data.i.i998, align 8, !tbaa !63 + %360 = bitcast i8** %datastart.i.i997 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %360, i8 0, i64 24, i1 false) #16 + %361 = load i32*, i32** %p.i.i785, align 8, !tbaa !64 + store i32 0, i32* %361, align 4, !tbaa !61 + store i32* null, i32** %refcount.i795, align 8, !tbaa !62 + %362 = load i64*, i64** %p.i2.i787, align 8, !tbaa !72 + %cmp.i1002 = icmp eq i64* %362, %arraydecay.i.i786 + br i1 %cmp.i1002, label %ehcleanup120, label %if.then.i1004 + +if.then.i1004: ; preds = %invoke.cont.i1003 + %363 = bitcast i64* %362 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %363) + to label %ehcleanup120 unwind label %terminate.lpad.i1006 + +terminate.lpad.i1006: ; preds = %if.then.i1004, %if.then.i.i996 + %364 = landingpad { i8*, i32 } + catch i8* null + %365 = extractvalue { i8*, i32 } %364, 0 + call void @__clang_call_terminate(i8* %365) #18 + unreachable + +ehcleanup120: ; preds = %if.then.i1004, %invoke.cont.i1003, %lpad109 + %ehselector.slot.4 = phi i32 [ %354, %lpad109 ], [ %357, %invoke.cont.i1003 ], [ %357, %if.then.i1004 ] + %exn.slot.4 = phi i8* [ %353, %lpad109 ], [ %356, %invoke.cont.i1003 ], [ %356, %if.then.i1004 ] + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %210) #16 + br label %ehcleanup405 + +lpad123: ; preds = %_ZN2cv3MatD2Ev.exit852 + %366 = landingpad { i8*, i32 } + cleanup + %367 = extractvalue { i8*, i32 } %366, 0 + %368 = extractvalue { i8*, i32 } %366, 1 + br label %ehcleanup134 + +lpad130: ; preds = %if.else.i898, %if.then.i.i877 + %369 = landingpad { i8*, i32 } + cleanup + %370 = extractvalue { i8*, i32 } %369, 0 + %371 = extractvalue { i8*, i32 } %369, 1 + %372 = load i32*, i32** %refcount.i868, align 8, !tbaa !62 + %tobool.i.i1009 = icmp eq i32* %372, null + br i1 %tobool.i.i1009, label %invoke.cont.i1019, label %land.lhs.true.i.i1011 + +land.lhs.true.i.i1011: ; preds = %lpad130 + %373 = atomicrmw add i32* %372, i32 -1 seq_cst + %cmp.i.i1010 = icmp eq i32 %373, 1 + br i1 %cmp.i.i1010, label %if.then.i.i1012, label %invoke.cont.i1019 + +if.then.i.i1012: ; preds = %land.lhs.true.i.i1011 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %ref.tmp121) + to label %invoke.cont.i1019 unwind label %terminate.lpad.i1022 + +invoke.cont.i1019: ; preds = %if.then.i.i1012, %land.lhs.true.i.i1011, %lpad130 + %datastart.i.i1013 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 6 + %data.i.i1014 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %ref.tmp121, i64 0, i32 4 + store i8* null, i8** %data.i.i1014, align 8, !tbaa !63 + %374 = bitcast i8** %datastart.i.i1013 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %374, i8 0, i64 24, i1 false) #16 + %375 = load i32*, i32** %p.i.i858, align 8, !tbaa !64 + store i32 0, i32* %375, align 4, !tbaa !61 + store i32* null, i32** %refcount.i868, align 8, !tbaa !62 + %376 = load i64*, i64** %p.i2.i860, align 8, !tbaa !72 + %cmp.i1018 = icmp eq i64* %376, %arraydecay.i.i859 + br i1 %cmp.i1018, label %ehcleanup134, label %if.then.i1020 + +if.then.i1020: ; preds = %invoke.cont.i1019 + %377 = bitcast i64* %376 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %377) + to label %ehcleanup134 unwind label %terminate.lpad.i1022 + +terminate.lpad.i1022: ; preds = %if.then.i1020, %if.then.i.i1012 + %378 = landingpad { i8*, i32 } + catch i8* null + %379 = extractvalue { i8*, i32 } %378, 0 + call void @__clang_call_terminate(i8* %379) #18 + unreachable + +ehcleanup134: ; preds = %if.then.i1020, %invoke.cont.i1019, %lpad123 + %ehselector.slot.5 = phi i32 [ %368, %lpad123 ], [ %371, %invoke.cont.i1019 ], [ %371, %if.then.i1020 ] + %exn.slot.5 = phi i8* [ %367, %lpad123 ], [ %370, %invoke.cont.i1019 ], [ %370, %if.then.i1020 ] + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %257) #16 + br label %ehcleanup405 + +cond.end: ; preds = %land.lhs.true148 + invoke void @__visc__init() + to label %invoke.cont164 unwind label %lpad47 + +invoke.cont164: ; preds = %cond.end + %380 = load i32*, i32** %p.i.i, align 8, !tbaa !56 + %381 = load i32, i32* %380, align 4, !tbaa !61 + %arrayidx.i1026 = getelementptr inbounds i32, i32* %380, i64 1 + %382 = load i32, i32* %arrayidx.i1026, align 4, !tbaa !61 + %mul = mul nsw i32 %382, %381 + %conv158 = sext i32 %mul to i64 + %mul159 = shl nsw i64 %conv158, 2 + %call160 = call noalias i8* @malloc(i64 4) #16 + %383 = bitcast i8* %call160 to float* + %384 = bitcast [9 x float]* %B to i8* + call void @llvm.lifetime.start.p0i8(i64 36, i8* nonnull %384) #16 + call void @llvm.memcpy.p0i8.p0i8.i64(i8* nonnull align 16 %384, i8* align 16 bitcast ([9 x float]* @__const.main.B to i8*), i64 36, i1 false) + %385 = bitcast [9 x float]* %Sx to i8* + call void @llvm.lifetime.start.p0i8(i64 36, i8* nonnull %385) #16 + call void @llvm.memset.p0i8.i64(i8* nonnull align 16 %385, i8 0, i64 32, i1 false) + %386 = getelementptr inbounds [9 x float], [9 x float]* %Sx, i64 0, i64 0 + store float -1.000000e+00, float* %386, align 16 + %387 = getelementptr inbounds [9 x float], [9 x float]* %Sx, i64 0, i64 2 + store float 1.000000e+00, float* %387, align 8 + %388 = getelementptr inbounds [9 x float], [9 x float]* %Sx, i64 0, i64 3 + store float -2.000000e+00, float* %388, align 4 + %389 = getelementptr inbounds [9 x float], [9 x float]* %Sx, i64 0, i64 5 + store float 2.000000e+00, float* %389, align 4 + %390 = getelementptr inbounds [9 x float], [9 x float]* %Sx, i64 0, i64 6 + store float -1.000000e+00, float* %390, align 8 + %391 = getelementptr inbounds [9 x float], [9 x float]* %Sx, i64 0, i64 8 + store float 1.000000e+00, float* %391, align 16 + %392 = bitcast [9 x float]* %Sy to i8* + call void @llvm.lifetime.start.p0i8(i64 36, i8* nonnull %392) #16 + call void @llvm.memset.p0i8.i64(i8* nonnull align 16 %392, i8 0, i64 36, i1 false) + %393 = getelementptr inbounds [9 x float], [9 x float]* %Sy, i64 0, i64 0 + store float -1.000000e+00, float* %393, align 16 + %394 = getelementptr inbounds [9 x float], [9 x float]* %Sy, i64 0, i64 1 + store float -2.000000e+00, float* %394, align 4 + %395 = getelementptr inbounds [9 x float], [9 x float]* %Sy, i64 0, i64 2 + store float -1.000000e+00, float* %395, align 8 + %396 = getelementptr inbounds [9 x float], [9 x float]* %Sy, i64 0, i64 6 + store float 1.000000e+00, float* %396, align 8 + %397 = getelementptr inbounds [9 x float], [9 x float]* %Sy, i64 0, i64 7 + store float 2.000000e+00, float* %397, align 4 + %398 = getelementptr inbounds [9 x float], [9 x float]* %Sy, i64 0, i64 8 + store float 1.000000e+00, float* %398, align 16 + %399 = bitcast [49 x float]* %Gs to i8* + call void @llvm.lifetime.start.p0i8(i64 196, i8* nonnull %399) #16 + call void @llvm.memcpy.p0i8.p0i8.i64(i8* nonnull align 16 %399, i8* align 16 bitcast ([49 x float]* @__const.main.Gs to i8*), i64 196, i1 false) + %400 = bitcast %"class.cv::Mat"* %in to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %400) #16 + %rows.i1027 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 2 + %p.i.i1028 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 10, i32 0 + store i32* %rows.i1027, i32** %p.i.i1028, align 8, !tbaa !56 + %arraydecay.i.i1029 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 11, i32 1, i64 0 + %p.i2.i1030 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i1029, i64** %p.i2.i1030, align 8, !tbaa !57 + %401 = bitcast i64* %arraydecay.i.i1029 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %401, i8 0, i64 16, i1 false) #16 + %flags.i.i1031 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i1031, align 8, !tbaa !37 + %dims.i.i1032 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 1 + %402 = bitcast i32* %dims.i.i1032 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %402, i8 0, i64 60, i1 false) #16 + %403 = bitcast %"class.cv::Mat"* %out to i8* + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %403) #16 + %rows.i1033 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 2 + %p.i.i1034 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 10, i32 0 + store i32* %rows.i1033, i32** %p.i.i1034, align 8, !tbaa !56 + %arraydecay.i.i1035 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 11, i32 1, i64 0 + %p.i2.i1036 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 11, i32 0 + store i64* %arraydecay.i.i1035, i64** %p.i2.i1036, align 8, !tbaa !57 + %404 = bitcast i64* %arraydecay.i.i1035 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %404, i8 0, i64 16, i1 false) #16 + %flags.i.i1037 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 0 + store i32 1124007936, i32* %flags.i.i1037, align 8, !tbaa !37 + %dims.i.i1038 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 1 + %405 = bitcast i32* %dims.i.i1038 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %405, i8 0, i64 60, i1 false) #16 + %406 = bitcast %"class.cv::_InputArray"* %ref.tmp165 to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %406) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp165, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %invoke.cont167 unwind label %lpad166 + +invoke.cont167: ; preds = %invoke.cont164 + %407 = bitcast %"class.cv::_OutputArray"* %ref.tmp168 to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %407) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp168, %"class.cv::Mat"* nonnull dereferenceable(96) %in) + to label %invoke.cont170 unwind label %lpad169 + +invoke.cont170: ; preds = %invoke.cont167 + %width.i1039 = getelementptr inbounds %"class.cv::Size_", %"class.cv::Size_"* %agg.tmp, i64 0, i32 0 + store i32 640, i32* %width.i1039, align 4, !tbaa !73 + %height.i1040 = getelementptr inbounds %"class.cv::Size_", %"class.cv::Size_"* %agg.tmp, i64 0, i32 1 + store i32 480, i32* %height.i1040, align 4, !tbaa !75 + invoke void @_ZN2cv6resizeERKNS_11_InputArrayERKNS_12_OutputArrayENS_5Size_IiEEddi(%"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp165, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp168, %"class.cv::Size_"* nonnull %agg.tmp, double 0.000000e+00, double 0.000000e+00, i32 1) + to label %invoke.cont172 unwind label %lpad169 + +invoke.cont172: ; preds = %invoke.cont170 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %407) #16 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %406) #16 + %408 = bitcast %"class.cv::_InputArray"* %ref.tmp175 to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %408) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp175, %"class.cv::Mat"* nonnull dereferenceable(96) %E) + to label %invoke.cont177 unwind label %lpad176 + +invoke.cont177: ; preds = %invoke.cont172 + %409 = bitcast %"class.cv::_OutputArray"* %ref.tmp178 to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %409) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp178, %"class.cv::Mat"* nonnull dereferenceable(96) %out) + to label %invoke.cont180 unwind label %lpad179 + +invoke.cont180: ; preds = %invoke.cont177 + %width.i1041 = getelementptr inbounds %"class.cv::Size_", %"class.cv::Size_"* %agg.tmp181, i64 0, i32 0 + store i32 640, i32* %width.i1041, align 4, !tbaa !73 + %height.i1042 = getelementptr inbounds %"class.cv::Size_", %"class.cv::Size_"* %agg.tmp181, i64 0, i32 1 + store i32 480, i32* %height.i1042, align 4, !tbaa !75 + invoke void @_ZN2cv6resizeERKNS_11_InputArrayERKNS_12_OutputArrayENS_5Size_IiEEddi(%"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp175, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp178, %"class.cv::Size_"* nonnull %agg.tmp181, double 0.000000e+00, double 0.000000e+00, i32 1) + to label %invoke.cont183 unwind label %lpad179 + +invoke.cont183: ; preds = %invoke.cont180 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %409) #16 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %408) #16 + %410 = bitcast %"class.cv::_InputArray"* %ref.tmp186 to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %410) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp186, %"class.cv::Mat"* nonnull dereferenceable(96) %in) + to label %invoke.cont188 unwind label %lpad187 + +invoke.cont188: ; preds = %invoke.cont183 + invoke void @_ZN2cv6imshowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS_11_InputArrayE(%"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) @_Z12input_windowB5cxx11, %"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp186) + to label %invoke.cont189 unwind label %lpad187 + +invoke.cont189: ; preds = %invoke.cont188 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %410) #16 + %411 = bitcast %"class.cv::_InputArray"* %ref.tmp191 to i8* + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %411) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp191, %"class.cv::Mat"* nonnull dereferenceable(96) %out) + to label %invoke.cont193 unwind label %lpad192 + +invoke.cont193: ; preds = %invoke.cont189 + invoke void @_ZN2cv6imshowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS_11_InputArrayE(%"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) @_Z13output_windowB5cxx11, %"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp191) + to label %invoke.cont194 unwind label %lpad192 + +invoke.cont194: ; preds = %invoke.cont193 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %411) #16 + %call198 = invoke i32 @_ZN2cv7waitKeyEi(i32 0) + to label %invoke.cont197 unwind label %lpad196 + +invoke.cont197: ; preds = %invoke.cont194 + %call199 = call noalias i8* @malloc(i64 208) #16 + %data = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 4 + %412 = bitcast i8** %data to i64* + %413 = load i64, i64* %412, align 8, !tbaa !63 + %414 = load i64, i64* %92, align 8, !tbaa !63 + %415 = load i64, i64* %139, align 8, !tbaa !63 + %416 = load i64, i64* %186, align 8, !tbaa !63 + %417 = load i64, i64* %233, align 8, !tbaa !63 + %418 = load i64, i64* %280, align 8, !tbaa !63 + %arraydecay = getelementptr inbounds [49 x float], [49 x float]* %Gs, i64 0, i64 0 + %arraydecay205 = getelementptr inbounds [9 x float], [9 x float]* %B, i64 0, i64 0 + %419 = load i32*, i32** %p.i.i, align 8, !tbaa !56 + %420 = load i32, i32* %419, align 4, !tbaa !61 + %conv212 = sext i32 %420 to i64 + %arrayidx.i1045 = getelementptr inbounds i32, i32* %419, i64 1 + %421 = load i32, i32* %arrayidx.i1045, align 4, !tbaa !61 + %conv216 = sext i32 %421 to i64 + %422 = bitcast i8* %call199 to i64* + store i64 %413, i64* %422, align 1, !tbaa !2 + %bytesI2.i = getelementptr inbounds i8, i8* %call199, i64 8 + %423 = bitcast i8* %bytesI2.i to i64* + store i64 %mul159, i64* %423, align 1, !tbaa !8 + %Is3.i = getelementptr inbounds i8, i8* %call199, i64 16 + %424 = bitcast i8* %Is3.i to i64* + store i64 %414, i64* %424, align 1, !tbaa !9 + %bytesIs4.i = getelementptr inbounds i8, i8* %call199, i64 24 + %425 = bitcast i8* %bytesIs4.i to i64* + store i64 %mul159, i64* %425, align 1, !tbaa !10 + %L5.i = getelementptr inbounds i8, i8* %call199, i64 32 + %426 = bitcast i8* %L5.i to i64* + store i64 %415, i64* %426, align 1, !tbaa !11 + %bytesL6.i = getelementptr inbounds i8, i8* %call199, i64 40 + %427 = bitcast i8* %bytesL6.i to i64* + store i64 %mul159, i64* %427, align 1, !tbaa !12 + %S7.i = getelementptr inbounds i8, i8* %call199, i64 48 + %428 = bitcast i8* %S7.i to i64* + store i64 %416, i64* %428, align 1, !tbaa !13 + %bytesS8.i = getelementptr inbounds i8, i8* %call199, i64 56 + %429 = bitcast i8* %bytesS8.i to i64* + store i64 %mul159, i64* %429, align 1, !tbaa !14 + %G9.i = getelementptr inbounds i8, i8* %call199, i64 64 + %430 = bitcast i8* %G9.i to i64* + store i64 %417, i64* %430, align 1, !tbaa !15 + %bytesG10.i = getelementptr inbounds i8, i8* %call199, i64 72 + %431 = bitcast i8* %bytesG10.i to i64* + store i64 %mul159, i64* %431, align 1, !tbaa !16 + %maxG11.i = getelementptr inbounds i8, i8* %call199, i64 80 + %432 = bitcast i8* %maxG11.i to i8** + store i8* %call160, i8** %432, align 1, !tbaa !17 + %bytesMaxG12.i = getelementptr inbounds i8, i8* %call199, i64 88 + %433 = bitcast i8* %bytesMaxG12.i to i64* + store i64 4, i64* %433, align 1, !tbaa !18 + %E13.i = getelementptr inbounds i8, i8* %call199, i64 96 + %434 = bitcast i8* %E13.i to i64* + store i64 %418, i64* %434, align 1, !tbaa !19 + %bytesE14.i = getelementptr inbounds i8, i8* %call199, i64 104 + %435 = bitcast i8* %bytesE14.i to i64* + store i64 %mul159, i64* %435, align 1, !tbaa !20 + %Gs15.i = getelementptr inbounds i8, i8* %call199, i64 112 + %436 = bitcast i8* %Gs15.i to float** + store float* %arraydecay, float** %436, align 1, !tbaa !21 + %bytesGs16.i = getelementptr inbounds i8, i8* %call199, i64 120 + %437 = bitcast i8* %bytesGs16.i to i64* + store i64 196, i64* %437, align 1, !tbaa !22 + %B17.i = getelementptr inbounds i8, i8* %call199, i64 128 + %438 = bitcast i8* %B17.i to float** + store float* %arraydecay205, float** %438, align 1, !tbaa !23 + %bytesB18.i = getelementptr inbounds i8, i8* %call199, i64 136 + %439 = bitcast i8* %bytesB18.i to i64* + store i64 36, i64* %439, align 1, !tbaa !24 + %Sx19.i = getelementptr inbounds i8, i8* %call199, i64 144 + %440 = bitcast i8* %Sx19.i to float** + store float* %386, float** %440, align 1, !tbaa !25 + %bytesSx20.i = getelementptr inbounds i8, i8* %call199, i64 152 + %441 = bitcast i8* %bytesSx20.i to i64* + store i64 36, i64* %441, align 1, !tbaa !26 + %Sy21.i = getelementptr inbounds i8, i8* %call199, i64 160 + %442 = bitcast i8* %Sy21.i to float** + store float* %393, float** %442, align 1, !tbaa !27 + %bytesSy22.i = getelementptr inbounds i8, i8* %call199, i64 168 + %443 = bitcast i8* %bytesSy22.i to i64* + store i64 36, i64* %443, align 1, !tbaa !28 + %m23.i = getelementptr inbounds i8, i8* %call199, i64 176 + %444 = bitcast i8* %m23.i to i64* + store i64 %conv212, i64* %444, align 1, !tbaa !29 + %n24.i = getelementptr inbounds i8, i8* %call199, i64 184 + %445 = bitcast i8* %n24.i to i64* + store i64 %conv216, i64* %445, align 1, !tbaa !30 + %block_x25.i = getelementptr inbounds i8, i8* %call199, i64 192 + %446 = bitcast i8* %block_x25.i to i64* + store i64 256, i64* %446, align 1, !tbaa !31 + %grid_x26.i = getelementptr inbounds i8, i8* %call199, i64 200 + %447 = bitcast i8* %grid_x26.i to i64* + store i64 1, i64* %447, align 1, !tbaa !32 + %mul224 = mul nsw i32 %421, %420 + %448 = and i32 %mul224, 255 + %cmp226 = icmp eq i32 %448, 0 + br i1 %cmp226, label %for.cond.preheader, label %cond.false228 + +for.cond.preheader: ; preds = %invoke.cont197 + %449 = bitcast %"class.cv::VideoCapture"* %ref.tmp241 to i8* + %450 = bitcast %"class.std::__cxx11::basic_string"* %ref.tmp242 to i8* + %451 = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp242, i64 0, i32 2 + %452 = bitcast %"class.std::__cxx11::basic_string"* %ref.tmp242 to %union.anon** + %453 = bitcast %union.anon* %451 to i8* + %454 = bitcast i64* %__dnew.i.i.i.i1063 to i8* + %_M_p.i18.i.i.i.i1069 = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp242, i64 0, i32 0, i32 0 + %_M_allocated_capacity.i.i.i.i.i1070 = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp242, i64 0, i32 2, i32 0 + %_M_string_length.i.i.i.i.i.i1076 = getelementptr inbounds %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* %ref.tmp242, i64 0, i32 1 + %cap.i = getelementptr inbounds %"class.cv::VideoCapture", %"class.cv::VideoCapture"* %cap, i64 0, i32 1 + %cap2.i = getelementptr inbounds %"class.cv::VideoCapture", %"class.cv::VideoCapture"* %ref.tmp241, i64 0, i32 1 + %refcount.i.i1082 = getelementptr inbounds %"class.cv::VideoCapture", %"class.cv::VideoCapture"* %ref.tmp241, i64 0, i32 1, i32 1 + %refcount.i.i.i = getelementptr inbounds %"class.cv::VideoCapture", %"class.cv::VideoCapture"* %cap, i64 0, i32 1, i32 1 + %455 = bitcast i32** %refcount.i.i.i to i8** + %456 = bitcast %"class.cv::Ptr"* %cap.i to i64* + %457 = bitcast %"class.cv::Ptr"* %cap2.i to i64* + %458 = bitcast %"class.cv::_InputArray"* %ref.tmp.i1094 to i8* + %459 = bitcast %"class.cv::_OutputArray"* %ref.tmp2.i1095 to i8* + %460 = bitcast %"class.cv::_OutputArray"* %ref.tmp3.i1096 to i8* + %461 = bitcast %"class.cv::Mat"* %in310 to i8* + %rows.i1148 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 2 + %p.i.i1149 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 10, i32 0 + %arraydecay.i.i1150 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 11, i32 1, i64 0 + %p.i2.i1151 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 11, i32 0 + %462 = bitcast i64* %arraydecay.i.i1150 to i8* + %flags.i.i1152 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 0 + %dims.i.i1153 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 1 + %463 = bitcast i32* %dims.i.i1153 to i8* + %464 = bitcast %"class.cv::Mat"* %out313 to i8* + %rows.i1154 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 2 + %p.i.i1155 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 10, i32 0 + %arraydecay.i.i1156 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 11, i32 1, i64 0 + %p.i2.i1157 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 11, i32 0 + %465 = bitcast i64* %arraydecay.i.i1156 to i8* + %flags.i.i1158 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 0 + %dims.i.i1159 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 1 + %466 = bitcast i32* %dims.i.i1159 to i8* + %467 = bitcast %"class.cv::_InputArray"* %ref.tmp316 to i8* + %468 = bitcast %"class.cv::_OutputArray"* %ref.tmp319 to i8* + %width.i1160 = getelementptr inbounds %"class.cv::Size_", %"class.cv::Size_"* %agg.tmp322, i64 0, i32 0 + %height.i1161 = getelementptr inbounds %"class.cv::Size_", %"class.cv::Size_"* %agg.tmp322, i64 0, i32 1 + %469 = bitcast %"class.cv::_InputArray"* %ref.tmp327 to i8* + %470 = bitcast %"class.cv::_OutputArray"* %ref.tmp330 to i8* + %width.i1162 = getelementptr inbounds %"class.cv::Size_", %"class.cv::Size_"* %agg.tmp333, i64 0, i32 0 + %height.i1163 = getelementptr inbounds %"class.cv::Size_", %"class.cv::Size_"* %agg.tmp333, i64 0, i32 1 + %471 = bitcast %"class.cv::_InputArray"* %ref.tmp338 to i8* + %472 = bitcast %"class.cv::_InputArray"* %ref.tmp343 to i8* + %473 = bitcast %"class.cv::_InputArray"* %ref.tmp.i1164 to i8* + %474 = bitcast %"class.cv::_OutputArray"* %ref.tmp2.i1165 to i8* + %475 = bitcast %"class.cv::_OutputArray"* %ref.tmp3.i1166 to i8* + %refcount.i.i1181 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 5 + %datastart.i.i1186 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 6 + %data.i.i1187 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out313, i64 0, i32 4 + %476 = bitcast i8** %datastart.i.i1186 to i8* + %refcount.i.i1197 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 5 + %datastart.i.i1202 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 6 + %data.i.i1203 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in310, i64 0, i32 4 + %477 = bitcast i8** %datastart.i.i1202 to i8* + br label %for.body + +cond.false228: ; preds = %invoke.cont197 + call void @__assert_fail(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.16, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.15, i64 0, i64 0), i32 873, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @__PRETTY_FUNCTION__.main, i64 0, i64 0)) #18 + unreachable + +lpad166: ; preds = %invoke.cont164 + %478 = landingpad { i8*, i32 } + cleanup + %479 = extractvalue { i8*, i32 } %478, 0 + %480 = extractvalue { i8*, i32 } %478, 1 + br label %ehcleanup174 + +lpad169: ; preds = %invoke.cont170, %invoke.cont167 + %481 = landingpad { i8*, i32 } + cleanup + %482 = extractvalue { i8*, i32 } %481, 0 + %483 = extractvalue { i8*, i32 } %481, 1 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %407) #16 + br label %ehcleanup174 + +ehcleanup174: ; preds = %lpad169, %lpad166 + %ehselector.slot.6 = phi i32 [ %483, %lpad169 ], [ %480, %lpad166 ] + %exn.slot.6 = phi i8* [ %482, %lpad169 ], [ %479, %lpad166 ] + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %406) #16 + br label %ehcleanup391 + +lpad176: ; preds = %invoke.cont172 + %484 = landingpad { i8*, i32 } + cleanup + %485 = extractvalue { i8*, i32 } %484, 0 + %486 = extractvalue { i8*, i32 } %484, 1 + br label %ehcleanup185 + +lpad179: ; preds = %invoke.cont180, %invoke.cont177 + %487 = landingpad { i8*, i32 } + cleanup + %488 = extractvalue { i8*, i32 } %487, 0 + %489 = extractvalue { i8*, i32 } %487, 1 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %409) #16 + br label %ehcleanup185 + +ehcleanup185: ; preds = %lpad179, %lpad176 + %ehselector.slot.7 = phi i32 [ %489, %lpad179 ], [ %486, %lpad176 ] + %exn.slot.7 = phi i8* [ %488, %lpad179 ], [ %485, %lpad176 ] + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %408) #16 + br label %ehcleanup391 + +lpad187: ; preds = %invoke.cont188, %invoke.cont183 + %490 = landingpad { i8*, i32 } + cleanup + %491 = extractvalue { i8*, i32 } %490, 0 + %492 = extractvalue { i8*, i32 } %490, 1 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %410) #16 + br label %ehcleanup391 + +lpad192: ; preds = %invoke.cont193, %invoke.cont189 + %493 = landingpad { i8*, i32 } + cleanup + %494 = extractvalue { i8*, i32 } %493, 0 + %495 = extractvalue { i8*, i32 } %493, 1 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %411) #16 + br label %ehcleanup391 + +lpad196: ; preds = %invoke.cont194 + %496 = landingpad { i8*, i32 } + cleanup + %497 = extractvalue { i8*, i32 } %496, 0 + %498 = extractvalue { i8*, i32 } %496, 1 + br label %ehcleanup391 + +lpad209: ; preds = %for.cond.cleanup + %499 = landingpad { i8*, i32 } + cleanup + %500 = extractvalue { i8*, i32 } %499, 0 + %501 = extractvalue { i8*, i32 } %499, 1 + br label %ehcleanup391 + +for.cond.cleanup: ; preds = %invoke.cont383 + invoke void @__visc__cleanup() + to label %invoke.cont389 unwind label %lpad209 + +for.body: ; preds = %invoke.cont383, %for.cond.preheader + %indvars.iv = phi i64 [ 0, %for.cond.preheader ], [ %indvars.iv.next, %invoke.cont383 ] + %call1.i10501053 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i64 5) + to label %invoke.cont232 unwind label %lpad231 + +invoke.cont232: ; preds = %for.body + %call.i1056 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZNSo9_M_insertImEERSoT_(%"class.std::basic_ostream"* nonnull @_ZSt4cout, i64 %indvars.iv) + to label %invoke.cont234 unwind label %lpad231 + +invoke.cont234: ; preds = %invoke.cont232 + %call1.i10581061 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) %call.i1056, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i64 1) + to label %invoke.cont236 unwind label %lpad231 + +invoke.cont236: ; preds = %invoke.cont234 + %call240 = invoke i8* (i32, ...) @__visc__launch(i32 1, void (float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, float*, i64, i64, i64, i64, i64)* nonnull @edgeDetection, i8* %call199) + to label %cond.end.thread.i1067 unwind label %lpad238 + +cond.end.thread.i1067: ; preds = %invoke.cont236 + call void @llvm.lifetime.start.p0i8(i64 24, i8* nonnull %449) #16 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %450) #16 + store %union.anon* %451, %union.anon** %452, align 8, !tbaa !49 + %call.i.i1065 = call i64 @strlen(i8* nonnull %2) #16 + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %454) #16 + store i64 %call.i.i1065, i64* %__dnew.i.i.i.i1063, align 8, !tbaa !51 + %cmp3.i.i.i.i1066 = icmp ugt i64 %call.i.i1065, 15 + br i1 %cmp3.i.i.i.i1066, label %if.then4.i.i.i.i1071, label %if.end6.i.i.i.i1073 + +if.then4.i.i.i.i1071: ; preds = %cond.end.thread.i1067 + %call5.i.i.i9.i1080 = invoke i8* @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_createERmm(%"class.std::__cxx11::basic_string"* nonnull %ref.tmp242, i64* nonnull dereferenceable(8) %__dnew.i.i.i.i1063, i64 0) + to label %call5.i.i.i9.i.noexc1079 unwind label %lpad244 + +call5.i.i.i9.i.noexc1079: ; preds = %if.then4.i.i.i.i1071 + store i8* %call5.i.i.i9.i1080, i8** %_M_p.i18.i.i.i.i1069, align 8, !tbaa !52 + %502 = load i64, i64* %__dnew.i.i.i.i1063, align 8, !tbaa !51 + store i64 %502, i64* %_M_allocated_capacity.i.i.i.i.i1070, align 8, !tbaa !54 + br label %if.end6.i.i.i.i1073 + +if.end6.i.i.i.i1073: ; preds = %call5.i.i.i9.i.noexc1079, %cond.end.thread.i1067 + %503 = phi i8* [ %call5.i.i.i9.i1080, %call5.i.i.i9.i.noexc1079 ], [ %453, %cond.end.thread.i1067 ] + switch i64 %call.i.i1065, label %if.end.i.i.i.i.i.i.i1075 [ + i64 1, label %if.then.i.i.i.i.i.i1074 + i64 0, label %invoke.cont245 + ] + +if.then.i.i.i.i.i.i1074: ; preds = %if.end6.i.i.i.i1073 + %504 = load i8, i8* %2, align 1, !tbaa !54 + store i8 %504, i8* %503, align 1, !tbaa !54 + br label %invoke.cont245 + +if.end.i.i.i.i.i.i.i1075: ; preds = %if.end6.i.i.i.i1073 + call void @llvm.memcpy.p0i8.p0i8.i64(i8* align 1 %503, i8* nonnull align 1 %2, i64 %call.i.i1065, i1 false) #16 + br label %invoke.cont245 + +invoke.cont245: ; preds = %if.end.i.i.i.i.i.i.i1075, %if.then.i.i.i.i.i.i1074, %if.end6.i.i.i.i1073 + %505 = load i64, i64* %__dnew.i.i.i.i1063, align 8, !tbaa !51 + store i64 %505, i64* %_M_string_length.i.i.i.i.i.i1076, align 8, !tbaa !55 + %506 = load i8*, i8** %_M_p.i18.i.i.i.i1069, align 8, !tbaa !52 + %arrayidx.i.i.i.i.i1077 = getelementptr inbounds i8, i8* %506, i64 %505 + store i8 0, i8* %arrayidx.i.i.i.i.i1077, align 1, !tbaa !54 + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %454) #16 + invoke void @_ZN2cv12VideoCaptureC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(%"class.cv::VideoCapture"* nonnull %ref.tmp241, %"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) %ref.tmp242) + to label %invoke.cont247 unwind label %lpad246 + +invoke.cont247: ; preds = %invoke.cont245 + %507 = load i32*, i32** %refcount.i.i1082, align 8, !tbaa !76 + %tobool.i.i1083 = icmp eq i32* %507, null + br i1 %tobool.i.i1083, label %if.end.i.i, label %if.then.i.i1084 + +if.then.i.i1084: ; preds = %invoke.cont247 + %508 = atomicrmw add i32* %507, i32 1 seq_cst + br label %if.end.i.i + +if.end.i.i: ; preds = %if.then.i.i1084, %invoke.cont247 + %509 = load i32*, i32** %refcount.i.i.i, align 8, !tbaa !76 + %tobool.i.i.i = icmp eq i32* %509, null + br i1 %tobool.i.i.i, label %invoke.cont249, label %land.lhs.true.i.i.i + +land.lhs.true.i.i.i: ; preds = %if.end.i.i + %510 = atomicrmw add i32* %509, i32 -1 seq_cst + %cmp.i.i.i1085 = icmp eq i32 %510, 1 + br i1 %cmp.i.i.i1085, label %if.then.i.i.i, label %invoke.cont249 + +if.then.i.i.i: ; preds = %land.lhs.true.i.i.i + invoke void @_ZN2cv3PtrI9CvCaptureE10delete_objEv(%"class.cv::Ptr"* nonnull %cap.i) + to label %.noexc1086 unwind label %lpad248 + +.noexc1086: ; preds = %if.then.i.i.i + %511 = load i8*, i8** %455, align 8, !tbaa !76 + invoke void @_ZN2cv8fastFreeEPv(i8* %511) + to label %invoke.cont249 unwind label %lpad248 + +invoke.cont249: ; preds = %land.lhs.true.i.i.i, %if.end.i.i, %.noexc1086 + %512 = load i64, i64* %457, align 8, !tbaa !78 + store i64 %512, i64* %456, align 8, !tbaa !78 + store i32* %507, i32** %refcount.i.i.i, align 8, !tbaa !76 + call void @_ZN2cv12VideoCaptureD1Ev(%"class.cv::VideoCapture"* nonnull %ref.tmp241) #16 + %513 = load i8*, i8** %_M_p.i18.i.i.i.i1069, align 8, !tbaa !52 + %cmp.i.i.i1090 = icmp eq i8* %513, %453 + br i1 %cmp.i.i.i1090, label %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit1093, label %if.then.i.i1091 + +if.then.i.i1091: ; preds = %invoke.cont249 + call void @_ZdlPv(i8* %513) #16 + br label %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit1093 + +_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit1093: ; preds = %invoke.cont249, %if.then.i.i1091 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %450) #16 + call void @llvm.lifetime.end.p0i8(i64 24, i8* nonnull %449) #16 + %vtable.i1097 = load %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)**, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*** %48, align 8, !tbaa !35 + %vfn.i1098 = getelementptr inbounds %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)** %vtable.i1097, i64 8 + %514 = load %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)** %vfn.i1098, align 8 + %call.i1104 = invoke dereferenceable(24) %"class.cv::VideoCapture"* %514(%"class.cv::VideoCapture"* nonnull %cap, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %call.i.noexc1103 unwind label %lpad238 + +call.i.noexc1103: ; preds = %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit1093 + %515 = load i32, i32* %flags.i.i, align 8, !tbaa !37 + %516 = and i32 %515, 4088 + %cmp.i1100 = icmp eq i32 %516, 16 + br i1 %cmp.i1100, label %if.then.i1101, label %if.end.i1102 + +if.then.i1101: ; preds = %call.i.noexc1103 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %458) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp.i1094, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc1105 unwind label %lpad238 + +.noexc1105: ; preds = %if.then.i1101 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %459) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp2.i1095, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc1106 unwind label %lpad238 + +.noexc1106: ; preds = %.noexc1105 + invoke void @_ZN2cv8cvtColorERKNS_11_InputArrayERKNS_12_OutputArrayEii(%"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp.i1094, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp2.i1095, i32 6, i32 0) + to label %.noexc1107 unwind label %lpad238 + +.noexc1107: ; preds = %.noexc1106 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %459) #16 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %458) #16 + br label %if.end.i1102 + +if.end.i1102: ; preds = %.noexc1107, %call.i.noexc1103 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %460) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp3.i1096, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc1108 unwind label %lpad238 + +.noexc1108: ; preds = %if.end.i1102 + invoke void @_ZNK2cv3Mat9convertToERKNS_12_OutputArrayEidd(%"class.cv::Mat"* nonnull %src, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp3.i1096, i32 5, double 0x3F70101010101010, double 0.000000e+00) + to label %_Z12getNextFrameRN2cv12VideoCaptureERNS_3MatE.exit1110 unwind label %lpad238 + +_Z12getNextFrameRN2cv12VideoCaptureERNS_3MatE.exit1110: ; preds = %.noexc1108 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %460) #16 + br label %for.body263 + +lpad231: ; preds = %invoke.cont234, %invoke.cont232, %for.body + %517 = landingpad { i8*, i32 } + cleanup + %518 = extractvalue { i8*, i32 } %517, 0 + %519 = extractvalue { i8*, i32 } %517, 1 + br label %ehcleanup391 + +lpad238: ; preds = %.noexc1108, %if.end.i1102, %.noexc1106, %.noexc1105, %if.then.i1101, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit1093, %if.end382, %invoke.cont236 + %520 = landingpad { i8*, i32 } + cleanup + %521 = extractvalue { i8*, i32 } %520, 0 + %522 = extractvalue { i8*, i32 } %520, 1 + br label %ehcleanup391 + +lpad244: ; preds = %if.then4.i.i.i.i1071 + %523 = landingpad { i8*, i32 } + cleanup + %524 = extractvalue { i8*, i32 } %523, 0 + %525 = extractvalue { i8*, i32 } %523, 1 + br label %ehcleanup253 + +lpad246: ; preds = %invoke.cont245 + %526 = landingpad { i8*, i32 } + cleanup + %527 = extractvalue { i8*, i32 } %526, 0 + %528 = extractvalue { i8*, i32 } %526, 1 + br label %ehcleanup252 + +lpad248: ; preds = %.noexc1086, %if.then.i.i.i + %529 = landingpad { i8*, i32 } + cleanup + %530 = extractvalue { i8*, i32 } %529, 0 + %531 = extractvalue { i8*, i32 } %529, 1 + call void @_ZN2cv12VideoCaptureD1Ev(%"class.cv::VideoCapture"* nonnull %ref.tmp241) #16 + br label %ehcleanup252 + +ehcleanup252: ; preds = %lpad248, %lpad246 + %ehselector.slot.8 = phi i32 [ %531, %lpad248 ], [ %528, %lpad246 ] + %exn.slot.8 = phi i8* [ %530, %lpad248 ], [ %527, %lpad246 ] + %532 = load i8*, i8** %_M_p.i18.i.i.i.i1069, align 8, !tbaa !52 + %cmp.i.i.i1113 = icmp eq i8* %532, %453 + br i1 %cmp.i.i.i1113, label %ehcleanup253, label %if.then.i.i1114 + +if.then.i.i1114: ; preds = %ehcleanup252 + call void @_ZdlPv(i8* %532) #16 + br label %ehcleanup253 + +ehcleanup253: ; preds = %if.then.i.i1114, %ehcleanup252, %lpad244 + %ehselector.slot.9 = phi i32 [ %525, %lpad244 ], [ %ehselector.slot.8, %ehcleanup252 ], [ %ehselector.slot.8, %if.then.i.i1114 ] + %exn.slot.9 = phi i8* [ %524, %lpad244 ], [ %exn.slot.8, %ehcleanup252 ], [ %exn.slot.8, %if.then.i.i1114 ] + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %450) #16 + call void @llvm.lifetime.end.p0i8(i64 24, i8* nonnull %449) #16 + br label %ehcleanup391 + +for.body263: ; preds = %_ZN2cv3MatD2Ev.exit1212, %_Z12getNextFrameRN2cv12VideoCaptureERNS_3MatE.exit1110 + %i.01682 = phi i32 [ 0, %_Z12getNextFrameRN2cv12VideoCaptureERNS_3MatE.exit1110 ], [ %inc, %_ZN2cv3MatD2Ev.exit1212 ] + %call1.i11181121 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([7 x i8], [7 x i8]* @.str.18, i64 0, i64 0), i64 6) + to label %invoke.cont265 unwind label %lpad264 + +invoke.cont265: ; preds = %for.body263 + %call268 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZNSolsEi(%"class.std::basic_ostream"* nonnull @_ZSt4cout, i32 %i.01682) + to label %invoke.cont267 unwind label %lpad264 + +invoke.cont267: ; preds = %invoke.cont265 + %call1.i11241127 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) %call268, i8* nonnull getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i64 1) + to label %invoke.cont269 unwind label %lpad264 + +invoke.cont269: ; preds = %invoke.cont267 + %533 = load i64, i64* %412, align 8, !tbaa !63 + store i64 %533, i64* %422, align 1, !tbaa !2 + store float 0.000000e+00, float* %383, align 4, !tbaa !33 + %.cast = inttoptr i64 %533 to i8* + invoke void @llvm_visc_track_mem(i8* %.cast, i64 %mul159) + to label %invoke.cont273 unwind label %lpad264 + +invoke.cont273: ; preds = %invoke.cont269 + %534 = load i8*, i8** %data.i.i, align 8, !tbaa !63 + invoke void @llvm_visc_track_mem(i8* %534, i64 %mul159) + to label %invoke.cont275 unwind label %lpad264 + +invoke.cont275: ; preds = %invoke.cont273 + %535 = load i8*, i8** %data.i.i660, align 8, !tbaa !63 + invoke void @llvm_visc_track_mem(i8* %535, i64 %mul159) + to label %invoke.cont277 unwind label %lpad264 + +invoke.cont277: ; preds = %invoke.cont275 + %536 = load i8*, i8** %data.i.i733, align 8, !tbaa !63 + invoke void @llvm_visc_track_mem(i8* %536, i64 %mul159) + to label %invoke.cont279 unwind label %lpad264 + +invoke.cont279: ; preds = %invoke.cont277 + %537 = load i8*, i8** %data.i.i806, align 8, !tbaa !63 + invoke void @llvm_visc_track_mem(i8* %537, i64 %mul159) + to label %invoke.cont281 unwind label %lpad264 + +invoke.cont281: ; preds = %invoke.cont279 + invoke void @llvm_visc_track_mem(i8* nonnull %call160, i64 4) + to label %invoke.cont282 unwind label %lpad264 + +invoke.cont282: ; preds = %invoke.cont281 + %538 = load i8*, i8** %data.i.i879, align 8, !tbaa !63 + invoke void @llvm_visc_track_mem(i8* %538, i64 %mul159) + to label %invoke.cont284 unwind label %lpad264 + +invoke.cont284: ; preds = %invoke.cont282 + invoke void @llvm_visc_track_mem(i8* nonnull %399, i64 196) + to label %invoke.cont286 unwind label %lpad264 + +invoke.cont286: ; preds = %invoke.cont284 + invoke void @llvm_visc_track_mem(i8* nonnull %384, i64 36) + to label %invoke.cont288 unwind label %lpad264 + +invoke.cont288: ; preds = %invoke.cont286 + invoke void @llvm_visc_track_mem(i8* nonnull %385, i64 36) + to label %invoke.cont290 unwind label %lpad264 + +invoke.cont290: ; preds = %invoke.cont288 + invoke void @llvm_visc_track_mem(i8* nonnull %392, i64 36) + to label %invoke.cont292 unwind label %lpad264 + +invoke.cont292: ; preds = %invoke.cont290 + invoke void @__visc__push(i8* %call240, i8* nonnull %call199) + to label %invoke.cont293 unwind label %lpad264 + +invoke.cont293: ; preds = %invoke.cont292 + %call296 = invoke i8* @__visc__pop(i8* %call240) + to label %invoke.cont295 unwind label %lpad294 + +invoke.cont295: ; preds = %invoke.cont293 + %call1.i11301133 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) @_ZSt4cout, i8* nonnull getelementptr inbounds ([16 x i8], [16 x i8]* @.str.19, i64 0, i64 0), i64 15) + to label %invoke.cont297 unwind label %lpad294 + +invoke.cont297: ; preds = %invoke.cont295 + %539 = bitcast i8* %call296 to i64* + %540 = load i64, i64* %539, align 8, !tbaa !51 + %call.i1136 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZNSo9_M_insertImEERSoT_(%"class.std::basic_ostream"* nonnull @_ZSt4cout, i64 %540) + to label %invoke.cont299 unwind label %lpad294 + +invoke.cont299: ; preds = %invoke.cont297 + %call1.i11381141 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) %call.i1136, i8* nonnull getelementptr inbounds ([11 x i8], [11 x i8]* @.str.20, i64 0, i64 0), i64 10) + to label %invoke.cont301 unwind label %lpad294 + +invoke.cont301: ; preds = %invoke.cont299 + %call.i1144 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZNSo9_M_insertImEERSoT_(%"class.std::basic_ostream"* nonnull %call.i1136, i64 %mul159) + to label %invoke.cont303 unwind label %lpad294 + +invoke.cont303: ; preds = %invoke.cont301 + call void @llvm.lifetime.start.p0i8(i64 1, i8* nonnull %__c.addr.i) + store i8 10, i8* %__c.addr.i, align 1, !tbaa !54 + %call.i1147 = invoke dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* nonnull dereferenceable(272) %call.i1144, i8* nonnull %__c.addr.i, i64 1) + to label %invoke.cont305 unwind label %lpad294 + +invoke.cont305: ; preds = %invoke.cont303 + call void @llvm.lifetime.end.p0i8(i64 1, i8* nonnull %__c.addr.i) + invoke void @llvm_visc_request_mem(i8* nonnull %call160, i64 4) + to label %invoke.cont307 unwind label %lpad294 + +invoke.cont307: ; preds = %invoke.cont305 + %541 = load i8*, i8** %data.i.i879, align 8, !tbaa !63 + invoke void @llvm_visc_request_mem(i8* %541, i64 %mul159) + to label %invoke.cont315 unwind label %lpad294 + +invoke.cont315: ; preds = %invoke.cont307 + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %461) #16 + store i32* %rows.i1148, i32** %p.i.i1149, align 8, !tbaa !56 + store i64* %arraydecay.i.i1150, i64** %p.i2.i1151, align 8, !tbaa !57 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %462, i8 0, i64 16, i1 false) #16 + store i32 1124007936, i32* %flags.i.i1152, align 8, !tbaa !37 + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %463, i8 0, i64 60, i1 false) #16 + call void @llvm.lifetime.start.p0i8(i64 96, i8* nonnull %464) #16 + store i32* %rows.i1154, i32** %p.i.i1155, align 8, !tbaa !56 + store i64* %arraydecay.i.i1156, i64** %p.i2.i1157, align 8, !tbaa !57 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %465, i8 0, i64 16, i1 false) #16 + store i32 1124007936, i32* %flags.i.i1158, align 8, !tbaa !37 + call void @llvm.memset.p0i8.i64(i8* nonnull align 4 %466, i8 0, i64 60, i1 false) #16 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %467) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp316, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %invoke.cont318 unwind label %lpad317 + +invoke.cont318: ; preds = %invoke.cont315 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %468) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp319, %"class.cv::Mat"* nonnull dereferenceable(96) %in310) + to label %invoke.cont321 unwind label %lpad320 + +invoke.cont321: ; preds = %invoke.cont318 + store i32 640, i32* %width.i1160, align 4, !tbaa !73 + store i32 480, i32* %height.i1161, align 4, !tbaa !75 + invoke void @_ZN2cv6resizeERKNS_11_InputArrayERKNS_12_OutputArrayENS_5Size_IiEEddi(%"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp316, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp319, %"class.cv::Size_"* nonnull %agg.tmp322, double 0.000000e+00, double 0.000000e+00, i32 1) + to label %invoke.cont324 unwind label %lpad320 + +invoke.cont324: ; preds = %invoke.cont321 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %468) #16 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %467) #16 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %469) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp327, %"class.cv::Mat"* nonnull dereferenceable(96) %E) + to label %invoke.cont329 unwind label %lpad328 + +invoke.cont329: ; preds = %invoke.cont324 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %470) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp330, %"class.cv::Mat"* nonnull dereferenceable(96) %out313) + to label %invoke.cont332 unwind label %lpad331 + +invoke.cont332: ; preds = %invoke.cont329 + store i32 640, i32* %width.i1162, align 4, !tbaa !73 + store i32 480, i32* %height.i1163, align 4, !tbaa !75 + invoke void @_ZN2cv6resizeERKNS_11_InputArrayERKNS_12_OutputArrayENS_5Size_IiEEddi(%"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp327, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp330, %"class.cv::Size_"* nonnull %agg.tmp333, double 0.000000e+00, double 0.000000e+00, i32 1) + to label %invoke.cont335 unwind label %lpad331 + +invoke.cont335: ; preds = %invoke.cont332 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %470) #16 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %469) #16 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %471) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp338, %"class.cv::Mat"* nonnull dereferenceable(96) %out313) + to label %invoke.cont340 unwind label %lpad339 + +invoke.cont340: ; preds = %invoke.cont335 + invoke void @_ZN2cv6imshowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS_11_InputArrayE(%"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) @_Z13output_windowB5cxx11, %"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp338) + to label %invoke.cont341 unwind label %lpad339 + +invoke.cont341: ; preds = %invoke.cont340 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %471) #16 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %472) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp343, %"class.cv::Mat"* nonnull dereferenceable(96) %in310) + to label %invoke.cont345 unwind label %lpad344 + +invoke.cont345: ; preds = %invoke.cont341 + invoke void @_ZN2cv6imshowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS_11_InputArrayE(%"class.std::__cxx11::basic_string"* nonnull dereferenceable(32) @_Z12input_windowB5cxx11, %"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp343) + to label %invoke.cont346 unwind label %lpad344 + +invoke.cont346: ; preds = %invoke.cont345 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %472) #16 + %call350 = invoke i32 @_ZN2cv7waitKeyEi(i32 1) + to label %invoke.cont349 unwind label %lpad348 + +invoke.cont349: ; preds = %invoke.cont346 + %542 = load i8*, i8** %data, align 8, !tbaa !63 + invoke void @llvm_visc_untrack_mem(i8* %542) + to label %invoke.cont352 unwind label %lpad348 + +invoke.cont352: ; preds = %invoke.cont349 + %543 = load i8*, i8** %data.i.i, align 8, !tbaa !63 + invoke void @llvm_visc_untrack_mem(i8* %543) + to label %invoke.cont354 unwind label %lpad348 + +invoke.cont354: ; preds = %invoke.cont352 + %544 = load i8*, i8** %data.i.i660, align 8, !tbaa !63 + invoke void @llvm_visc_untrack_mem(i8* %544) + to label %invoke.cont356 unwind label %lpad348 + +invoke.cont356: ; preds = %invoke.cont354 + %545 = load i8*, i8** %data.i.i733, align 8, !tbaa !63 + invoke void @llvm_visc_untrack_mem(i8* %545) + to label %invoke.cont358 unwind label %lpad348 + +invoke.cont358: ; preds = %invoke.cont356 + %546 = load i8*, i8** %data.i.i806, align 8, !tbaa !63 + invoke void @llvm_visc_untrack_mem(i8* %546) + to label %invoke.cont360 unwind label %lpad348 + +invoke.cont360: ; preds = %invoke.cont358 + invoke void @llvm_visc_untrack_mem(i8* nonnull %call160) + to label %invoke.cont361 unwind label %lpad348 + +invoke.cont361: ; preds = %invoke.cont360 + %547 = load i8*, i8** %data.i.i879, align 8, !tbaa !63 + invoke void @llvm_visc_untrack_mem(i8* %547) + to label %invoke.cont363 unwind label %lpad348 + +invoke.cont363: ; preds = %invoke.cont361 + invoke void @llvm_visc_untrack_mem(i8* nonnull %399) + to label %invoke.cont365 unwind label %lpad348 + +invoke.cont365: ; preds = %invoke.cont363 + invoke void @llvm_visc_untrack_mem(i8* nonnull %384) + to label %invoke.cont367 unwind label %lpad348 + +invoke.cont367: ; preds = %invoke.cont365 + invoke void @llvm_visc_untrack_mem(i8* nonnull %385) + to label %invoke.cont369 unwind label %lpad348 + +invoke.cont369: ; preds = %invoke.cont367 + invoke void @llvm_visc_untrack_mem(i8* nonnull %392) + to label %invoke.cont371 unwind label %lpad348 + +invoke.cont371: ; preds = %invoke.cont369 + %vtable.i1167 = load %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)**, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*** %48, align 8, !tbaa !35 + %vfn.i1168 = getelementptr inbounds %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)** %vtable.i1167, i64 8 + %548 = load %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)*, %"class.cv::VideoCapture"* (%"class.cv::VideoCapture"*, %"class.cv::Mat"*)** %vfn.i1168, align 8 + %call.i1174 = invoke dereferenceable(24) %"class.cv::VideoCapture"* %548(%"class.cv::VideoCapture"* nonnull %cap, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %call.i.noexc1173 unwind label %lpad348 + +call.i.noexc1173: ; preds = %invoke.cont371 + %549 = load i32, i32* %flags.i.i, align 8, !tbaa !37 + %550 = and i32 %549, 4088 + %cmp.i1170 = icmp eq i32 %550, 16 + br i1 %cmp.i1170, label %if.then.i1171, label %if.end.i1172 + +if.then.i1171: ; preds = %call.i.noexc1173 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %473) #16 + invoke void @_ZN2cv11_InputArrayC1ERKNS_3MatE(%"class.cv::_InputArray"* nonnull %ref.tmp.i1164, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc1175 unwind label %lpad348 + +.noexc1175: ; preds = %if.then.i1171 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %474) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp2.i1165, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc1176 unwind label %lpad348 + +.noexc1176: ; preds = %.noexc1175 + invoke void @_ZN2cv8cvtColorERKNS_11_InputArrayERKNS_12_OutputArrayEii(%"class.cv::_InputArray"* nonnull dereferenceable(32) %ref.tmp.i1164, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp2.i1165, i32 6, i32 0) + to label %.noexc1177 unwind label %lpad348 + +.noexc1177: ; preds = %.noexc1176 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %474) #16 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %473) #16 + br label %if.end.i1172 + +if.end.i1172: ; preds = %.noexc1177, %call.i.noexc1173 + call void @llvm.lifetime.start.p0i8(i64 32, i8* nonnull %475) #16 + invoke void @_ZN2cv12_OutputArrayC1ERNS_3MatE(%"class.cv::_OutputArray"* nonnull %ref.tmp3.i1166, %"class.cv::Mat"* nonnull dereferenceable(96) %src) + to label %.noexc1178 unwind label %lpad348 + +.noexc1178: ; preds = %if.end.i1172 + invoke void @_ZNK2cv3Mat9convertToERKNS_12_OutputArrayEidd(%"class.cv::Mat"* nonnull %src, %"class.cv::_OutputArray"* nonnull dereferenceable(32) %ref.tmp3.i1166, i32 5, double 0x3F70101010101010, double 0.000000e+00) + to label %invoke.cont372 unwind label %lpad348 + +invoke.cont372: ; preds = %.noexc1178 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %475) #16 + %551 = load i32*, i32** %refcount.i.i1181, align 8, !tbaa !62 + %tobool.i.i1182 = icmp eq i32* %551, null + br i1 %tobool.i.i1182, label %invoke.cont.i1192, label %land.lhs.true.i.i1184 + +land.lhs.true.i.i1184: ; preds = %invoke.cont372 + %552 = atomicrmw add i32* %551, i32 -1 seq_cst + %cmp.i.i1183 = icmp eq i32 %552, 1 + br i1 %cmp.i.i1183, label %if.then.i.i1185, label %invoke.cont.i1192 + +if.then.i.i1185: ; preds = %land.lhs.true.i.i1184 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %out313) + to label %invoke.cont.i1192 unwind label %terminate.lpad.i1195 + +invoke.cont.i1192: ; preds = %if.then.i.i1185, %land.lhs.true.i.i1184, %invoke.cont372 + store i8* null, i8** %data.i.i1187, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %476, i8 0, i64 24, i1 false) #16 + %553 = load i32*, i32** %p.i.i1155, align 8, !tbaa !64 + store i32 0, i32* %553, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1181, align 8, !tbaa !62 + %554 = load i64*, i64** %p.i2.i1157, align 8, !tbaa !72 + %cmp.i1191 = icmp eq i64* %554, %arraydecay.i.i1156 + br i1 %cmp.i1191, label %_ZN2cv3MatD2Ev.exit1196, label %if.then.i1193 + +if.then.i1193: ; preds = %invoke.cont.i1192 + %555 = bitcast i64* %554 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %555) + to label %_ZN2cv3MatD2Ev.exit1196 unwind label %terminate.lpad.i1195 + +terminate.lpad.i1195: ; preds = %if.then.i1193, %if.then.i.i1185 + %556 = landingpad { i8*, i32 } + catch i8* null + %557 = extractvalue { i8*, i32 } %556, 0 + call void @__clang_call_terminate(i8* %557) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1196: ; preds = %invoke.cont.i1192, %if.then.i1193 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %464) #16 + %558 = load i32*, i32** %refcount.i.i1197, align 8, !tbaa !62 + %tobool.i.i1198 = icmp eq i32* %558, null + br i1 %tobool.i.i1198, label %invoke.cont.i1208, label %land.lhs.true.i.i1200 + +land.lhs.true.i.i1200: ; preds = %_ZN2cv3MatD2Ev.exit1196 + %559 = atomicrmw add i32* %558, i32 -1 seq_cst + %cmp.i.i1199 = icmp eq i32 %559, 1 + br i1 %cmp.i.i1199, label %if.then.i.i1201, label %invoke.cont.i1208 + +if.then.i.i1201: ; preds = %land.lhs.true.i.i1200 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %in310) + to label %invoke.cont.i1208 unwind label %terminate.lpad.i1211 + +invoke.cont.i1208: ; preds = %if.then.i.i1201, %land.lhs.true.i.i1200, %_ZN2cv3MatD2Ev.exit1196 + store i8* null, i8** %data.i.i1203, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %477, i8 0, i64 24, i1 false) #16 + %560 = load i32*, i32** %p.i.i1149, align 8, !tbaa !64 + store i32 0, i32* %560, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1197, align 8, !tbaa !62 + %561 = load i64*, i64** %p.i2.i1151, align 8, !tbaa !72 + %cmp.i1207 = icmp eq i64* %561, %arraydecay.i.i1150 + br i1 %cmp.i1207, label %_ZN2cv3MatD2Ev.exit1212, label %if.then.i1209 + +if.then.i1209: ; preds = %invoke.cont.i1208 + %562 = bitcast i64* %561 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %562) + to label %_ZN2cv3MatD2Ev.exit1212 unwind label %terminate.lpad.i1211 + +terminate.lpad.i1211: ; preds = %if.then.i1209, %if.then.i.i1201 + %563 = landingpad { i8*, i32 } + catch i8* null + %564 = extractvalue { i8*, i32 } %563, 0 + call void @__clang_call_terminate(i8* %564) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1212: ; preds = %invoke.cont.i1208, %if.then.i1209 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %461) #16 + %inc = add nuw nsw i32 %i.01682, 1 + %exitcond = icmp eq i32 %inc, 600 + br i1 %exitcond, label %if.end382, label %for.body263 + +lpad264: ; preds = %invoke.cont267, %for.body263, %invoke.cont292, %invoke.cont290, %invoke.cont288, %invoke.cont286, %invoke.cont284, %invoke.cont282, %invoke.cont281, %invoke.cont279, %invoke.cont277, %invoke.cont275, %invoke.cont273, %invoke.cont269, %invoke.cont265 + %565 = landingpad { i8*, i32 } + cleanup + %566 = extractvalue { i8*, i32 } %565, 0 + %567 = extractvalue { i8*, i32 } %565, 1 + br label %ehcleanup391 + +lpad294: ; preds = %invoke.cont303, %invoke.cont301, %invoke.cont299, %invoke.cont297, %invoke.cont295, %invoke.cont307, %invoke.cont305, %invoke.cont293 + %568 = landingpad { i8*, i32 } + cleanup + %569 = extractvalue { i8*, i32 } %568, 0 + %570 = extractvalue { i8*, i32 } %568, 1 + br label %ehcleanup391 + +lpad317: ; preds = %invoke.cont315 + %571 = landingpad { i8*, i32 } + cleanup + %572 = extractvalue { i8*, i32 } %571, 0 + %573 = extractvalue { i8*, i32 } %571, 1 + br label %ehcleanup326 + +lpad320: ; preds = %invoke.cont321, %invoke.cont318 + %574 = landingpad { i8*, i32 } + cleanup + %575 = extractvalue { i8*, i32 } %574, 0 + %576 = extractvalue { i8*, i32 } %574, 1 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %468) #16 + br label %ehcleanup326 + +ehcleanup326: ; preds = %lpad320, %lpad317 + %ehselector.slot.10 = phi i32 [ %576, %lpad320 ], [ %573, %lpad317 ] + %exn.slot.10 = phi i8* [ %575, %lpad320 ], [ %572, %lpad317 ] + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %467) #16 + br label %ehcleanup373 + +lpad328: ; preds = %invoke.cont324 + %577 = landingpad { i8*, i32 } + cleanup + %578 = extractvalue { i8*, i32 } %577, 0 + %579 = extractvalue { i8*, i32 } %577, 1 + br label %ehcleanup337 + +lpad331: ; preds = %invoke.cont332, %invoke.cont329 + %580 = landingpad { i8*, i32 } + cleanup + %581 = extractvalue { i8*, i32 } %580, 0 + %582 = extractvalue { i8*, i32 } %580, 1 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %470) #16 + br label %ehcleanup337 + +ehcleanup337: ; preds = %lpad331, %lpad328 + %ehselector.slot.11 = phi i32 [ %582, %lpad331 ], [ %579, %lpad328 ] + %exn.slot.11 = phi i8* [ %581, %lpad331 ], [ %578, %lpad328 ] + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %469) #16 + br label %ehcleanup373 + +lpad339: ; preds = %invoke.cont340, %invoke.cont335 + %583 = landingpad { i8*, i32 } + cleanup + %584 = extractvalue { i8*, i32 } %583, 0 + %585 = extractvalue { i8*, i32 } %583, 1 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %471) #16 + br label %ehcleanup373 + +lpad344: ; preds = %invoke.cont345, %invoke.cont341 + %586 = landingpad { i8*, i32 } + cleanup + %587 = extractvalue { i8*, i32 } %586, 0 + %588 = extractvalue { i8*, i32 } %586, 1 + call void @llvm.lifetime.end.p0i8(i64 32, i8* nonnull %472) #16 + br label %ehcleanup373 + +lpad348: ; preds = %.noexc1178, %if.end.i1172, %.noexc1176, %.noexc1175, %if.then.i1171, %invoke.cont371, %invoke.cont369, %invoke.cont367, %invoke.cont365, %invoke.cont363, %invoke.cont361, %invoke.cont360, %invoke.cont358, %invoke.cont356, %invoke.cont354, %invoke.cont352, %invoke.cont349, %invoke.cont346 + %589 = landingpad { i8*, i32 } + cleanup + %590 = extractvalue { i8*, i32 } %589, 0 + %591 = extractvalue { i8*, i32 } %589, 1 + br label %ehcleanup373 + +ehcleanup373: ; preds = %lpad348, %lpad344, %lpad339, %ehcleanup337, %ehcleanup326 + %ehselector.slot.12 = phi i32 [ %591, %lpad348 ], [ %588, %lpad344 ], [ %585, %lpad339 ], [ %ehselector.slot.11, %ehcleanup337 ], [ %ehselector.slot.10, %ehcleanup326 ] + %exn.slot.12 = phi i8* [ %590, %lpad348 ], [ %587, %lpad344 ], [ %584, %lpad339 ], [ %exn.slot.11, %ehcleanup337 ], [ %exn.slot.10, %ehcleanup326 ] + %592 = load i32*, i32** %refcount.i.i1181, align 8, !tbaa !62 + %tobool.i.i1214 = icmp eq i32* %592, null + br i1 %tobool.i.i1214, label %invoke.cont.i1224, label %land.lhs.true.i.i1216 + +land.lhs.true.i.i1216: ; preds = %ehcleanup373 + %593 = atomicrmw add i32* %592, i32 -1 seq_cst + %cmp.i.i1215 = icmp eq i32 %593, 1 + br i1 %cmp.i.i1215, label %if.then.i.i1217, label %invoke.cont.i1224 + +if.then.i.i1217: ; preds = %land.lhs.true.i.i1216 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %out313) + to label %invoke.cont.i1224 unwind label %terminate.lpad.i1227 + +invoke.cont.i1224: ; preds = %if.then.i.i1217, %land.lhs.true.i.i1216, %ehcleanup373 + store i8* null, i8** %data.i.i1187, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %476, i8 0, i64 24, i1 false) #16 + %594 = load i32*, i32** %p.i.i1155, align 8, !tbaa !64 + store i32 0, i32* %594, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1181, align 8, !tbaa !62 + %595 = load i64*, i64** %p.i2.i1157, align 8, !tbaa !72 + %cmp.i1223 = icmp eq i64* %595, %arraydecay.i.i1156 + br i1 %cmp.i1223, label %ehcleanup374, label %if.then.i1225 + +if.then.i1225: ; preds = %invoke.cont.i1224 + %596 = bitcast i64* %595 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %596) + to label %ehcleanup374 unwind label %terminate.lpad.i1227 + +terminate.lpad.i1227: ; preds = %if.then.i1225, %if.then.i.i1217 + %597 = landingpad { i8*, i32 } + catch i8* null + %598 = extractvalue { i8*, i32 } %597, 0 + call void @__clang_call_terminate(i8* %598) #18 + unreachable + +ehcleanup374: ; preds = %if.then.i1225, %invoke.cont.i1224 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %464) #16 + %599 = load i32*, i32** %refcount.i.i1197, align 8, !tbaa !62 + %tobool.i.i1230 = icmp eq i32* %599, null + br i1 %tobool.i.i1230, label %invoke.cont.i1240, label %land.lhs.true.i.i1232 + +land.lhs.true.i.i1232: ; preds = %ehcleanup374 + %600 = atomicrmw add i32* %599, i32 -1 seq_cst + %cmp.i.i1231 = icmp eq i32 %600, 1 + br i1 %cmp.i.i1231, label %if.then.i.i1233, label %invoke.cont.i1240 + +if.then.i.i1233: ; preds = %land.lhs.true.i.i1232 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %in310) + to label %invoke.cont.i1240 unwind label %terminate.lpad.i1243 + +invoke.cont.i1240: ; preds = %if.then.i.i1233, %land.lhs.true.i.i1232, %ehcleanup374 + store i8* null, i8** %data.i.i1203, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %477, i8 0, i64 24, i1 false) #16 + %601 = load i32*, i32** %p.i.i1149, align 8, !tbaa !64 + store i32 0, i32* %601, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1197, align 8, !tbaa !62 + %602 = load i64*, i64** %p.i2.i1151, align 8, !tbaa !72 + %cmp.i1239 = icmp eq i64* %602, %arraydecay.i.i1150 + br i1 %cmp.i1239, label %ehcleanup376, label %if.then.i1241 + +if.then.i1241: ; preds = %invoke.cont.i1240 + %603 = bitcast i64* %602 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %603) + to label %ehcleanup376 unwind label %terminate.lpad.i1243 + +terminate.lpad.i1243: ; preds = %if.then.i1241, %if.then.i.i1233 + %604 = landingpad { i8*, i32 } + catch i8* null + %605 = extractvalue { i8*, i32 } %604, 0 + call void @__clang_call_terminate(i8* %605) #18 + unreachable + +ehcleanup376: ; preds = %if.then.i1241, %invoke.cont.i1240 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %461) #16 + br label %ehcleanup391 + +if.end382: ; preds = %_ZN2cv3MatD2Ev.exit1212 + invoke void @__visc__wait(i8* %call240) + to label %invoke.cont383 unwind label %lpad238 + +invoke.cont383: ; preds = %if.end382 + %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 + %exitcond1685 = icmp eq i64 %indvars.iv.next, 100 + br i1 %exitcond1685, label %for.cond.cleanup, label %for.body + +invoke.cont389: ; preds = %for.cond.cleanup + %refcount.i.i1245 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 5 + %606 = load i32*, i32** %refcount.i.i1245, align 8, !tbaa !62 + %tobool.i.i1246 = icmp eq i32* %606, null + br i1 %tobool.i.i1246, label %invoke.cont.i1256, label %land.lhs.true.i.i1248 + +land.lhs.true.i.i1248: ; preds = %invoke.cont389 + %607 = atomicrmw add i32* %606, i32 -1 seq_cst + %cmp.i.i1247 = icmp eq i32 %607, 1 + br i1 %cmp.i.i1247, label %if.then.i.i1249, label %invoke.cont.i1256 + +if.then.i.i1249: ; preds = %land.lhs.true.i.i1248 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %out) + to label %invoke.cont.i1256 unwind label %terminate.lpad.i1259 + +invoke.cont.i1256: ; preds = %if.then.i.i1249, %land.lhs.true.i.i1248, %invoke.cont389 + %datastart.i.i1250 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 6 + %data.i.i1251 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 4 + store i8* null, i8** %data.i.i1251, align 8, !tbaa !63 + %608 = bitcast i8** %datastart.i.i1250 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %608, i8 0, i64 24, i1 false) #16 + %609 = load i32*, i32** %p.i.i1034, align 8, !tbaa !64 + store i32 0, i32* %609, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1245, align 8, !tbaa !62 + %610 = load i64*, i64** %p.i2.i1036, align 8, !tbaa !72 + %cmp.i1255 = icmp eq i64* %610, %arraydecay.i.i1035 + br i1 %cmp.i1255, label %_ZN2cv3MatD2Ev.exit1260, label %if.then.i1257 + +if.then.i1257: ; preds = %invoke.cont.i1256 + %611 = bitcast i64* %610 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %611) + to label %_ZN2cv3MatD2Ev.exit1260 unwind label %terminate.lpad.i1259 + +terminate.lpad.i1259: ; preds = %if.then.i1257, %if.then.i.i1249 + %612 = landingpad { i8*, i32 } + catch i8* null + %613 = extractvalue { i8*, i32 } %612, 0 + call void @__clang_call_terminate(i8* %613) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1260: ; preds = %invoke.cont.i1256, %if.then.i1257 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %403) #16 + %refcount.i.i1261 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 5 + %614 = load i32*, i32** %refcount.i.i1261, align 8, !tbaa !62 + %tobool.i.i1262 = icmp eq i32* %614, null + br i1 %tobool.i.i1262, label %invoke.cont.i1272, label %land.lhs.true.i.i1264 + +land.lhs.true.i.i1264: ; preds = %_ZN2cv3MatD2Ev.exit1260 + %615 = atomicrmw add i32* %614, i32 -1 seq_cst + %cmp.i.i1263 = icmp eq i32 %615, 1 + br i1 %cmp.i.i1263, label %if.then.i.i1265, label %invoke.cont.i1272 + +if.then.i.i1265: ; preds = %land.lhs.true.i.i1264 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %in) + to label %invoke.cont.i1272 unwind label %terminate.lpad.i1275 + +invoke.cont.i1272: ; preds = %if.then.i.i1265, %land.lhs.true.i.i1264, %_ZN2cv3MatD2Ev.exit1260 + %datastart.i.i1266 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 6 + %data.i.i1267 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 4 + store i8* null, i8** %data.i.i1267, align 8, !tbaa !63 + %616 = bitcast i8** %datastart.i.i1266 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %616, i8 0, i64 24, i1 false) #16 + %617 = load i32*, i32** %p.i.i1028, align 8, !tbaa !64 + store i32 0, i32* %617, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1261, align 8, !tbaa !62 + %618 = load i64*, i64** %p.i2.i1030, align 8, !tbaa !72 + %cmp.i1271 = icmp eq i64* %618, %arraydecay.i.i1029 + br i1 %cmp.i1271, label %_ZN2cv3MatD2Ev.exit1276, label %if.then.i1273 + +if.then.i1273: ; preds = %invoke.cont.i1272 + %619 = bitcast i64* %618 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %619) + to label %_ZN2cv3MatD2Ev.exit1276 unwind label %terminate.lpad.i1275 + +terminate.lpad.i1275: ; preds = %if.then.i1273, %if.then.i.i1265 + %620 = landingpad { i8*, i32 } + catch i8* null + %621 = extractvalue { i8*, i32 } %620, 0 + call void @__clang_call_terminate(i8* %621) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1276: ; preds = %invoke.cont.i1272, %if.then.i1273 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %400) #16 + call void @llvm.lifetime.end.p0i8(i64 196, i8* nonnull %399) #16 + call void @llvm.lifetime.end.p0i8(i64 36, i8* nonnull %392) #16 + call void @llvm.lifetime.end.p0i8(i64 36, i8* nonnull %385) #16 + call void @llvm.lifetime.end.p0i8(i64 36, i8* nonnull %384) #16 + %622 = load i32*, i32** %refcount.i.i872, align 8, !tbaa !62 + %tobool.i.i1278 = icmp eq i32* %622, null + br i1 %tobool.i.i1278, label %invoke.cont.i1288, label %land.lhs.true.i.i1280 + +land.lhs.true.i.i1280: ; preds = %_ZN2cv3MatD2Ev.exit1276 + %623 = atomicrmw add i32* %622, i32 -1 seq_cst + %cmp.i.i1279 = icmp eq i32 %623, 1 + br i1 %cmp.i.i1279, label %if.then.i.i1281, label %invoke.cont.i1288 + +if.then.i.i1281: ; preds = %land.lhs.true.i.i1280 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %E) + to label %invoke.cont.i1288 unwind label %terminate.lpad.i1291 + +invoke.cont.i1288: ; preds = %if.then.i.i1281, %land.lhs.true.i.i1280, %_ZN2cv3MatD2Ev.exit1276 + store i8* null, i8** %data.i.i879, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %267, i8 0, i64 24, i1 false) #16 + %624 = load i32*, i32** %p.i.i570, align 8, !tbaa !64 + store i32 0, i32* %624, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i872, align 8, !tbaa !62 + %625 = load i64*, i64** %p.i2.i572, align 8, !tbaa !72 + %cmp.i1287 = icmp eq i64* %625, %arraydecay.i.i571 + br i1 %cmp.i1287, label %_ZN2cv3MatD2Ev.exit1292, label %if.then.i1289 + +if.then.i1289: ; preds = %invoke.cont.i1288 + %626 = bitcast i64* %625 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %626) + to label %_ZN2cv3MatD2Ev.exit1292 unwind label %terminate.lpad.i1291 + +terminate.lpad.i1291: ; preds = %if.then.i1289, %if.then.i.i1281 + %627 = landingpad { i8*, i32 } + catch i8* null + %628 = extractvalue { i8*, i32 } %627, 0 + call void @__clang_call_terminate(i8* %628) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1292: ; preds = %invoke.cont.i1288, %if.then.i1289 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %45) #16 + %629 = load i32*, i32** %refcount.i.i799, align 8, !tbaa !62 + %tobool.i.i1294 = icmp eq i32* %629, null + br i1 %tobool.i.i1294, label %invoke.cont.i1304, label %land.lhs.true.i.i1296 + +land.lhs.true.i.i1296: ; preds = %_ZN2cv3MatD2Ev.exit1292 + %630 = atomicrmw add i32* %629, i32 -1 seq_cst + %cmp.i.i1295 = icmp eq i32 %630, 1 + br i1 %cmp.i.i1295, label %if.then.i.i1297, label %invoke.cont.i1304 + +if.then.i.i1297: ; preds = %land.lhs.true.i.i1296 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %G) + to label %invoke.cont.i1304 unwind label %terminate.lpad.i1307 + +invoke.cont.i1304: ; preds = %if.then.i.i1297, %land.lhs.true.i.i1296, %_ZN2cv3MatD2Ev.exit1292 + store i8* null, i8** %data.i.i806, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %220, i8 0, i64 24, i1 false) #16 + %631 = load i32*, i32** %p.i.i564, align 8, !tbaa !64 + store i32 0, i32* %631, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i799, align 8, !tbaa !62 + %632 = load i64*, i64** %p.i2.i566, align 8, !tbaa !72 + %cmp.i1303 = icmp eq i64* %632, %arraydecay.i.i565 + br i1 %cmp.i1303, label %_ZN2cv3MatD2Ev.exit1308, label %if.then.i1305 + +if.then.i1305: ; preds = %invoke.cont.i1304 + %633 = bitcast i64* %632 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %633) + to label %_ZN2cv3MatD2Ev.exit1308 unwind label %terminate.lpad.i1307 + +terminate.lpad.i1307: ; preds = %if.then.i1305, %if.then.i.i1297 + %634 = landingpad { i8*, i32 } + catch i8* null + %635 = extractvalue { i8*, i32 } %634, 0 + call void @__clang_call_terminate(i8* %635) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1308: ; preds = %invoke.cont.i1304, %if.then.i1305 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %42) #16 + %636 = load i32*, i32** %refcount.i.i726, align 8, !tbaa !62 + %tobool.i.i1310 = icmp eq i32* %636, null + br i1 %tobool.i.i1310, label %invoke.cont.i1320, label %land.lhs.true.i.i1312 + +land.lhs.true.i.i1312: ; preds = %_ZN2cv3MatD2Ev.exit1308 + %637 = atomicrmw add i32* %636, i32 -1 seq_cst + %cmp.i.i1311 = icmp eq i32 %637, 1 + br i1 %cmp.i.i1311, label %if.then.i.i1313, label %invoke.cont.i1320 + +if.then.i.i1313: ; preds = %land.lhs.true.i.i1312 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %S) + to label %invoke.cont.i1320 unwind label %terminate.lpad.i1323 + +invoke.cont.i1320: ; preds = %if.then.i.i1313, %land.lhs.true.i.i1312, %_ZN2cv3MatD2Ev.exit1308 + store i8* null, i8** %data.i.i733, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %173, i8 0, i64 24, i1 false) #16 + %638 = load i32*, i32** %p.i.i558, align 8, !tbaa !64 + store i32 0, i32* %638, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i726, align 8, !tbaa !62 + %639 = load i64*, i64** %p.i2.i560, align 8, !tbaa !72 + %cmp.i1319 = icmp eq i64* %639, %arraydecay.i.i559 + br i1 %cmp.i1319, label %_ZN2cv3MatD2Ev.exit1324, label %if.then.i1321 + +if.then.i1321: ; preds = %invoke.cont.i1320 + %640 = bitcast i64* %639 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %640) + to label %_ZN2cv3MatD2Ev.exit1324 unwind label %terminate.lpad.i1323 + +terminate.lpad.i1323: ; preds = %if.then.i1321, %if.then.i.i1313 + %641 = landingpad { i8*, i32 } + catch i8* null + %642 = extractvalue { i8*, i32 } %641, 0 + call void @__clang_call_terminate(i8* %642) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1324: ; preds = %invoke.cont.i1320, %if.then.i1321 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %39) #16 + %643 = load i32*, i32** %refcount.i.i653, align 8, !tbaa !62 + %tobool.i.i1326 = icmp eq i32* %643, null + br i1 %tobool.i.i1326, label %invoke.cont.i1336, label %land.lhs.true.i.i1328 + +land.lhs.true.i.i1328: ; preds = %_ZN2cv3MatD2Ev.exit1324 + %644 = atomicrmw add i32* %643, i32 -1 seq_cst + %cmp.i.i1327 = icmp eq i32 %644, 1 + br i1 %cmp.i.i1327, label %if.then.i.i1329, label %invoke.cont.i1336 + +if.then.i.i1329: ; preds = %land.lhs.true.i.i1328 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %L) + to label %invoke.cont.i1336 unwind label %terminate.lpad.i1339 + +invoke.cont.i1336: ; preds = %if.then.i.i1329, %land.lhs.true.i.i1328, %_ZN2cv3MatD2Ev.exit1324 + store i8* null, i8** %data.i.i660, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %126, i8 0, i64 24, i1 false) #16 + %645 = load i32*, i32** %p.i.i552, align 8, !tbaa !64 + store i32 0, i32* %645, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i653, align 8, !tbaa !62 + %646 = load i64*, i64** %p.i2.i554, align 8, !tbaa !72 + %cmp.i1335 = icmp eq i64* %646, %arraydecay.i.i553 + br i1 %cmp.i1335, label %_ZN2cv3MatD2Ev.exit1340, label %if.then.i1337 + +if.then.i1337: ; preds = %invoke.cont.i1336 + %647 = bitcast i64* %646 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %647) + to label %_ZN2cv3MatD2Ev.exit1340 unwind label %terminate.lpad.i1339 + +terminate.lpad.i1339: ; preds = %if.then.i1337, %if.then.i.i1329 + %648 = landingpad { i8*, i32 } + catch i8* null + %649 = extractvalue { i8*, i32 } %648, 0 + call void @__clang_call_terminate(i8* %649) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1340: ; preds = %invoke.cont.i1336, %if.then.i1337 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %36) #16 + %650 = load i32*, i32** %refcount.i.i, align 8, !tbaa !62 + %tobool.i.i1342 = icmp eq i32* %650, null + br i1 %tobool.i.i1342, label %invoke.cont.i1352, label %land.lhs.true.i.i1344 + +land.lhs.true.i.i1344: ; preds = %_ZN2cv3MatD2Ev.exit1340 + %651 = atomicrmw add i32* %650, i32 -1 seq_cst + %cmp.i.i1343 = icmp eq i32 %651, 1 + br i1 %cmp.i.i1343, label %if.then.i.i1345, label %invoke.cont.i1352 + +if.then.i.i1345: ; preds = %land.lhs.true.i.i1344 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %Is) + to label %invoke.cont.i1352 unwind label %terminate.lpad.i1355 + +invoke.cont.i1352: ; preds = %if.then.i.i1345, %land.lhs.true.i.i1344, %_ZN2cv3MatD2Ev.exit1340 + store i8* null, i8** %data.i.i, align 8, !tbaa !63 + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %79, i8 0, i64 24, i1 false) #16 + %652 = load i32*, i32** %p.i.i546, align 8, !tbaa !64 + store i32 0, i32* %652, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i, align 8, !tbaa !62 + %653 = load i64*, i64** %p.i2.i548, align 8, !tbaa !72 + %cmp.i1351 = icmp eq i64* %653, %arraydecay.i.i547 + br i1 %cmp.i1351, label %_ZN2cv3MatD2Ev.exit1356, label %if.then.i1353 + +if.then.i1353: ; preds = %invoke.cont.i1352 + %654 = bitcast i64* %653 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %654) + to label %_ZN2cv3MatD2Ev.exit1356 unwind label %terminate.lpad.i1355 + +terminate.lpad.i1355: ; preds = %if.then.i1353, %if.then.i.i1345 + %655 = landingpad { i8*, i32 } + catch i8* null + %656 = extractvalue { i8*, i32 } %655, 0 + call void @__clang_call_terminate(i8* %656) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1356: ; preds = %invoke.cont.i1352, %if.then.i1353 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %33) #16 + %refcount.i.i1357 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 5 + %657 = load i32*, i32** %refcount.i.i1357, align 8, !tbaa !62 + %tobool.i.i1358 = icmp eq i32* %657, null + br i1 %tobool.i.i1358, label %invoke.cont.i1368, label %land.lhs.true.i.i1360 + +land.lhs.true.i.i1360: ; preds = %_ZN2cv3MatD2Ev.exit1356 + %658 = atomicrmw add i32* %657, i32 -1 seq_cst + %cmp.i.i1359 = icmp eq i32 %658, 1 + br i1 %cmp.i.i1359, label %if.then.i.i1361, label %invoke.cont.i1368 + +if.then.i.i1361: ; preds = %land.lhs.true.i.i1360 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %src) + to label %invoke.cont.i1368 unwind label %terminate.lpad.i1371 + +invoke.cont.i1368: ; preds = %if.then.i.i1361, %land.lhs.true.i.i1360, %_ZN2cv3MatD2Ev.exit1356 + %datastart.i.i1362 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 6 + store i8* null, i8** %data, align 8, !tbaa !63 + %659 = bitcast i8** %datastart.i.i1362 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %659, i8 0, i64 24, i1 false) #16 + %660 = load i32*, i32** %p.i.i, align 8, !tbaa !64 + store i32 0, i32* %660, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1357, align 8, !tbaa !62 + %661 = load i64*, i64** %p.i2.i, align 8, !tbaa !72 + %cmp.i1367 = icmp eq i64* %661, %arraydecay.i.i + br i1 %cmp.i1367, label %_ZN2cv3MatD2Ev.exit1372, label %if.then.i1369 + +if.then.i1369: ; preds = %invoke.cont.i1368 + %662 = bitcast i64* %661 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %662) + to label %_ZN2cv3MatD2Ev.exit1372 unwind label %terminate.lpad.i1371 + +terminate.lpad.i1371: ; preds = %if.then.i1369, %if.then.i.i1361 + %663 = landingpad { i8*, i32 } + catch i8* null + %664 = extractvalue { i8*, i32 } %663, 0 + call void @__clang_call_terminate(i8* %664) #18 + unreachable + +_ZN2cv3MatD2Ev.exit1372: ; preds = %invoke.cont.i1368, %if.then.i1369 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %30) #16 + br label %cleanup + +ehcleanup391: ; preds = %lpad209, %lpad238, %ehcleanup253, %lpad294, %ehcleanup376, %lpad264, %lpad231, %lpad196, %lpad192, %lpad187, %ehcleanup185, %ehcleanup174 + %ehselector.slot.20 = phi i32 [ %498, %lpad196 ], [ %495, %lpad192 ], [ %492, %lpad187 ], [ %ehselector.slot.7, %ehcleanup185 ], [ %ehselector.slot.6, %ehcleanup174 ], [ %501, %lpad209 ], [ %519, %lpad231 ], [ %522, %lpad238 ], [ %ehselector.slot.9, %ehcleanup253 ], [ %567, %lpad264 ], [ %ehselector.slot.12, %ehcleanup376 ], [ %570, %lpad294 ] + %exn.slot.20 = phi i8* [ %497, %lpad196 ], [ %494, %lpad192 ], [ %491, %lpad187 ], [ %exn.slot.7, %ehcleanup185 ], [ %exn.slot.6, %ehcleanup174 ], [ %500, %lpad209 ], [ %518, %lpad231 ], [ %521, %lpad238 ], [ %exn.slot.9, %ehcleanup253 ], [ %566, %lpad264 ], [ %exn.slot.12, %ehcleanup376 ], [ %569, %lpad294 ] + %refcount.i.i1373 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 5 + %665 = load i32*, i32** %refcount.i.i1373, align 8, !tbaa !62 + %tobool.i.i1374 = icmp eq i32* %665, null + br i1 %tobool.i.i1374, label %invoke.cont.i1384, label %land.lhs.true.i.i1376 + +land.lhs.true.i.i1376: ; preds = %ehcleanup391 + %666 = atomicrmw add i32* %665, i32 -1 seq_cst + %cmp.i.i1375 = icmp eq i32 %666, 1 + br i1 %cmp.i.i1375, label %if.then.i.i1377, label %invoke.cont.i1384 + +if.then.i.i1377: ; preds = %land.lhs.true.i.i1376 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %out) + to label %invoke.cont.i1384 unwind label %terminate.lpad.i1387 + +invoke.cont.i1384: ; preds = %if.then.i.i1377, %land.lhs.true.i.i1376, %ehcleanup391 + %datastart.i.i1378 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 6 + %data.i.i1379 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %out, i64 0, i32 4 + store i8* null, i8** %data.i.i1379, align 8, !tbaa !63 + %667 = bitcast i8** %datastart.i.i1378 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %667, i8 0, i64 24, i1 false) #16 + %668 = load i32*, i32** %p.i.i1034, align 8, !tbaa !64 + store i32 0, i32* %668, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1373, align 8, !tbaa !62 + %669 = load i64*, i64** %p.i2.i1036, align 8, !tbaa !72 + %cmp.i1383 = icmp eq i64* %669, %arraydecay.i.i1035 + br i1 %cmp.i1383, label %ehcleanup392, label %if.then.i1385 + +if.then.i1385: ; preds = %invoke.cont.i1384 + %670 = bitcast i64* %669 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %670) + to label %ehcleanup392 unwind label %terminate.lpad.i1387 + +terminate.lpad.i1387: ; preds = %if.then.i1385, %if.then.i.i1377 + %671 = landingpad { i8*, i32 } + catch i8* null + %672 = extractvalue { i8*, i32 } %671, 0 + call void @__clang_call_terminate(i8* %672) #18 + unreachable + +ehcleanup392: ; preds = %if.then.i1385, %invoke.cont.i1384 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %403) #16 + %refcount.i.i1389 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 5 + %673 = load i32*, i32** %refcount.i.i1389, align 8, !tbaa !62 + %tobool.i.i1390 = icmp eq i32* %673, null + br i1 %tobool.i.i1390, label %invoke.cont.i1400, label %land.lhs.true.i.i1392 + +land.lhs.true.i.i1392: ; preds = %ehcleanup392 + %674 = atomicrmw add i32* %673, i32 -1 seq_cst + %cmp.i.i1391 = icmp eq i32 %674, 1 + br i1 %cmp.i.i1391, label %if.then.i.i1393, label %invoke.cont.i1400 + +if.then.i.i1393: ; preds = %land.lhs.true.i.i1392 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %in) + to label %invoke.cont.i1400 unwind label %terminate.lpad.i1403 + +invoke.cont.i1400: ; preds = %if.then.i.i1393, %land.lhs.true.i.i1392, %ehcleanup392 + %datastart.i.i1394 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 6 + %data.i.i1395 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %in, i64 0, i32 4 + store i8* null, i8** %data.i.i1395, align 8, !tbaa !63 + %675 = bitcast i8** %datastart.i.i1394 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %675, i8 0, i64 24, i1 false) #16 + %676 = load i32*, i32** %p.i.i1028, align 8, !tbaa !64 + store i32 0, i32* %676, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1389, align 8, !tbaa !62 + %677 = load i64*, i64** %p.i2.i1030, align 8, !tbaa !72 + %cmp.i1399 = icmp eq i64* %677, %arraydecay.i.i1029 + br i1 %cmp.i1399, label %ehcleanup394, label %if.then.i1401 + +if.then.i1401: ; preds = %invoke.cont.i1400 + %678 = bitcast i64* %677 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %678) + to label %ehcleanup394 unwind label %terminate.lpad.i1403 + +terminate.lpad.i1403: ; preds = %if.then.i1401, %if.then.i.i1393 + %679 = landingpad { i8*, i32 } + catch i8* null + %680 = extractvalue { i8*, i32 } %679, 0 + call void @__clang_call_terminate(i8* %680) #18 + unreachable + +ehcleanup394: ; preds = %if.then.i1401, %invoke.cont.i1400 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %400) #16 + call void @llvm.lifetime.end.p0i8(i64 196, i8* nonnull %399) #16 + call void @llvm.lifetime.end.p0i8(i64 36, i8* nonnull %392) #16 + call void @llvm.lifetime.end.p0i8(i64 36, i8* nonnull %385) #16 + call void @llvm.lifetime.end.p0i8(i64 36, i8* nonnull %384) #16 + br label %ehcleanup405 + +ehcleanup405: ; preds = %ehcleanup394, %ehcleanup134, %ehcleanup120, %ehcleanup106, %ehcleanup92, %ehcleanup78, %lpad52, %lpad47 + %ehselector.slot.23 = phi i32 [ %ehselector.slot.20, %ehcleanup394 ], [ %64, %lpad47 ], [ %ehselector.slot.5, %ehcleanup134 ], [ %ehselector.slot.4, %ehcleanup120 ], [ %ehselector.slot.3, %ehcleanup106 ], [ %ehselector.slot.2, %ehcleanup92 ], [ %ehselector.slot.1, %ehcleanup78 ], [ %67, %lpad52 ] + %exn.slot.23 = phi i8* [ %exn.slot.20, %ehcleanup394 ], [ %63, %lpad47 ], [ %exn.slot.5, %ehcleanup134 ], [ %exn.slot.4, %ehcleanup120 ], [ %exn.slot.3, %ehcleanup106 ], [ %exn.slot.2, %ehcleanup92 ], [ %exn.slot.1, %ehcleanup78 ], [ %66, %lpad52 ] + %refcount.i.i1405 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 5 + %681 = load i32*, i32** %refcount.i.i1405, align 8, !tbaa !62 + %tobool.i.i1406 = icmp eq i32* %681, null + br i1 %tobool.i.i1406, label %invoke.cont.i1416, label %land.lhs.true.i.i1408 + +land.lhs.true.i.i1408: ; preds = %ehcleanup405 + %682 = atomicrmw add i32* %681, i32 -1 seq_cst + %cmp.i.i1407 = icmp eq i32 %682, 1 + br i1 %cmp.i.i1407, label %if.then.i.i1409, label %invoke.cont.i1416 + +if.then.i.i1409: ; preds = %land.lhs.true.i.i1408 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %E) + to label %invoke.cont.i1416 unwind label %terminate.lpad.i1419 + +invoke.cont.i1416: ; preds = %if.then.i.i1409, %land.lhs.true.i.i1408, %ehcleanup405 + %datastart.i.i1410 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 6 + %data.i.i1411 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %E, i64 0, i32 4 + store i8* null, i8** %data.i.i1411, align 8, !tbaa !63 + %683 = bitcast i8** %datastart.i.i1410 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %683, i8 0, i64 24, i1 false) #16 + %684 = load i32*, i32** %p.i.i570, align 8, !tbaa !64 + store i32 0, i32* %684, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1405, align 8, !tbaa !62 + %685 = load i64*, i64** %p.i2.i572, align 8, !tbaa !72 + %cmp.i1415 = icmp eq i64* %685, %arraydecay.i.i571 + br i1 %cmp.i1415, label %ehcleanup406, label %if.then.i1417 + +if.then.i1417: ; preds = %invoke.cont.i1416 + %686 = bitcast i64* %685 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %686) + to label %ehcleanup406 unwind label %terminate.lpad.i1419 + +terminate.lpad.i1419: ; preds = %if.then.i1417, %if.then.i.i1409 + %687 = landingpad { i8*, i32 } + catch i8* null + %688 = extractvalue { i8*, i32 } %687, 0 + call void @__clang_call_terminate(i8* %688) #18 + unreachable + +ehcleanup406: ; preds = %if.then.i1417, %invoke.cont.i1416 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %45) #16 + %refcount.i.i1421 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 5 + %689 = load i32*, i32** %refcount.i.i1421, align 8, !tbaa !62 + %tobool.i.i1422 = icmp eq i32* %689, null + br i1 %tobool.i.i1422, label %invoke.cont.i1432, label %land.lhs.true.i.i1424 + +land.lhs.true.i.i1424: ; preds = %ehcleanup406 + %690 = atomicrmw add i32* %689, i32 -1 seq_cst + %cmp.i.i1423 = icmp eq i32 %690, 1 + br i1 %cmp.i.i1423, label %if.then.i.i1425, label %invoke.cont.i1432 + +if.then.i.i1425: ; preds = %land.lhs.true.i.i1424 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %G) + to label %invoke.cont.i1432 unwind label %terminate.lpad.i1435 + +invoke.cont.i1432: ; preds = %if.then.i.i1425, %land.lhs.true.i.i1424, %ehcleanup406 + %datastart.i.i1426 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 6 + %data.i.i1427 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %G, i64 0, i32 4 + store i8* null, i8** %data.i.i1427, align 8, !tbaa !63 + %691 = bitcast i8** %datastart.i.i1426 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %691, i8 0, i64 24, i1 false) #16 + %692 = load i32*, i32** %p.i.i564, align 8, !tbaa !64 + store i32 0, i32* %692, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1421, align 8, !tbaa !62 + %693 = load i64*, i64** %p.i2.i566, align 8, !tbaa !72 + %cmp.i1431 = icmp eq i64* %693, %arraydecay.i.i565 + br i1 %cmp.i1431, label %ehcleanup408, label %if.then.i1433 + +if.then.i1433: ; preds = %invoke.cont.i1432 + %694 = bitcast i64* %693 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %694) + to label %ehcleanup408 unwind label %terminate.lpad.i1435 + +terminate.lpad.i1435: ; preds = %if.then.i1433, %if.then.i.i1425 + %695 = landingpad { i8*, i32 } + catch i8* null + %696 = extractvalue { i8*, i32 } %695, 0 + call void @__clang_call_terminate(i8* %696) #18 + unreachable + +ehcleanup408: ; preds = %if.then.i1433, %invoke.cont.i1432 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %42) #16 + %refcount.i.i1437 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 5 + %697 = load i32*, i32** %refcount.i.i1437, align 8, !tbaa !62 + %tobool.i.i1438 = icmp eq i32* %697, null + br i1 %tobool.i.i1438, label %invoke.cont.i1448, label %land.lhs.true.i.i1440 + +land.lhs.true.i.i1440: ; preds = %ehcleanup408 + %698 = atomicrmw add i32* %697, i32 -1 seq_cst + %cmp.i.i1439 = icmp eq i32 %698, 1 + br i1 %cmp.i.i1439, label %if.then.i.i1441, label %invoke.cont.i1448 + +if.then.i.i1441: ; preds = %land.lhs.true.i.i1440 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %S) + to label %invoke.cont.i1448 unwind label %terminate.lpad.i1451 + +invoke.cont.i1448: ; preds = %if.then.i.i1441, %land.lhs.true.i.i1440, %ehcleanup408 + %datastart.i.i1442 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 6 + %data.i.i1443 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %S, i64 0, i32 4 + store i8* null, i8** %data.i.i1443, align 8, !tbaa !63 + %699 = bitcast i8** %datastart.i.i1442 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %699, i8 0, i64 24, i1 false) #16 + %700 = load i32*, i32** %p.i.i558, align 8, !tbaa !64 + store i32 0, i32* %700, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1437, align 8, !tbaa !62 + %701 = load i64*, i64** %p.i2.i560, align 8, !tbaa !72 + %cmp.i1447 = icmp eq i64* %701, %arraydecay.i.i559 + br i1 %cmp.i1447, label %ehcleanup410, label %if.then.i1449 + +if.then.i1449: ; preds = %invoke.cont.i1448 + %702 = bitcast i64* %701 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %702) + to label %ehcleanup410 unwind label %terminate.lpad.i1451 + +terminate.lpad.i1451: ; preds = %if.then.i1449, %if.then.i.i1441 + %703 = landingpad { i8*, i32 } + catch i8* null + %704 = extractvalue { i8*, i32 } %703, 0 + call void @__clang_call_terminate(i8* %704) #18 + unreachable + +ehcleanup410: ; preds = %if.then.i1449, %invoke.cont.i1448 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %39) #16 + %refcount.i.i1453 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 5 + %705 = load i32*, i32** %refcount.i.i1453, align 8, !tbaa !62 + %tobool.i.i1454 = icmp eq i32* %705, null + br i1 %tobool.i.i1454, label %invoke.cont.i1464, label %land.lhs.true.i.i1456 + +land.lhs.true.i.i1456: ; preds = %ehcleanup410 + %706 = atomicrmw add i32* %705, i32 -1 seq_cst + %cmp.i.i1455 = icmp eq i32 %706, 1 + br i1 %cmp.i.i1455, label %if.then.i.i1457, label %invoke.cont.i1464 + +if.then.i.i1457: ; preds = %land.lhs.true.i.i1456 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %L) + to label %invoke.cont.i1464 unwind label %terminate.lpad.i1467 + +invoke.cont.i1464: ; preds = %if.then.i.i1457, %land.lhs.true.i.i1456, %ehcleanup410 + %datastart.i.i1458 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 6 + %data.i.i1459 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %L, i64 0, i32 4 + store i8* null, i8** %data.i.i1459, align 8, !tbaa !63 + %707 = bitcast i8** %datastart.i.i1458 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %707, i8 0, i64 24, i1 false) #16 + %708 = load i32*, i32** %p.i.i552, align 8, !tbaa !64 + store i32 0, i32* %708, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1453, align 8, !tbaa !62 + %709 = load i64*, i64** %p.i2.i554, align 8, !tbaa !72 + %cmp.i1463 = icmp eq i64* %709, %arraydecay.i.i553 + br i1 %cmp.i1463, label %ehcleanup412, label %if.then.i1465 + +if.then.i1465: ; preds = %invoke.cont.i1464 + %710 = bitcast i64* %709 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %710) + to label %ehcleanup412 unwind label %terminate.lpad.i1467 + +terminate.lpad.i1467: ; preds = %if.then.i1465, %if.then.i.i1457 + %711 = landingpad { i8*, i32 } + catch i8* null + %712 = extractvalue { i8*, i32 } %711, 0 + call void @__clang_call_terminate(i8* %712) #18 + unreachable + +ehcleanup412: ; preds = %if.then.i1465, %invoke.cont.i1464 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %36) #16 + %refcount.i.i1469 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 5 + %713 = load i32*, i32** %refcount.i.i1469, align 8, !tbaa !62 + %tobool.i.i1470 = icmp eq i32* %713, null + br i1 %tobool.i.i1470, label %invoke.cont.i1480, label %land.lhs.true.i.i1472 + +land.lhs.true.i.i1472: ; preds = %ehcleanup412 + %714 = atomicrmw add i32* %713, i32 -1 seq_cst + %cmp.i.i1471 = icmp eq i32 %714, 1 + br i1 %cmp.i.i1471, label %if.then.i.i1473, label %invoke.cont.i1480 + +if.then.i.i1473: ; preds = %land.lhs.true.i.i1472 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %Is) + to label %invoke.cont.i1480 unwind label %terminate.lpad.i1483 + +invoke.cont.i1480: ; preds = %if.then.i.i1473, %land.lhs.true.i.i1472, %ehcleanup412 + %datastart.i.i1474 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 6 + %data.i.i1475 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %Is, i64 0, i32 4 + store i8* null, i8** %data.i.i1475, align 8, !tbaa !63 + %715 = bitcast i8** %datastart.i.i1474 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %715, i8 0, i64 24, i1 false) #16 + %716 = load i32*, i32** %p.i.i546, align 8, !tbaa !64 + store i32 0, i32* %716, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1469, align 8, !tbaa !62 + %717 = load i64*, i64** %p.i2.i548, align 8, !tbaa !72 + %cmp.i1479 = icmp eq i64* %717, %arraydecay.i.i547 + br i1 %cmp.i1479, label %ehcleanup414, label %if.then.i1481 + +if.then.i1481: ; preds = %invoke.cont.i1480 + %718 = bitcast i64* %717 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %718) + to label %ehcleanup414 unwind label %terminate.lpad.i1483 + +terminate.lpad.i1483: ; preds = %if.then.i1481, %if.then.i.i1473 + %719 = landingpad { i8*, i32 } + catch i8* null + %720 = extractvalue { i8*, i32 } %719, 0 + call void @__clang_call_terminate(i8* %720) #18 + unreachable + +ehcleanup414: ; preds = %if.then.i1481, %invoke.cont.i1480 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %33) #16 + %refcount.i.i1485 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 5 + %721 = load i32*, i32** %refcount.i.i1485, align 8, !tbaa !62 + %tobool.i.i1486 = icmp eq i32* %721, null + br i1 %tobool.i.i1486, label %invoke.cont.i1496, label %land.lhs.true.i.i1488 + +land.lhs.true.i.i1488: ; preds = %ehcleanup414 + %722 = atomicrmw add i32* %721, i32 -1 seq_cst + %cmp.i.i1487 = icmp eq i32 %722, 1 + br i1 %cmp.i.i1487, label %if.then.i.i1489, label %invoke.cont.i1496 + +if.then.i.i1489: ; preds = %land.lhs.true.i.i1488 + invoke void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"* nonnull %src) + to label %invoke.cont.i1496 unwind label %terminate.lpad.i1499 + +invoke.cont.i1496: ; preds = %if.then.i.i1489, %land.lhs.true.i.i1488, %ehcleanup414 + %datastart.i.i1490 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 6 + %data.i.i1491 = getelementptr inbounds %"class.cv::Mat", %"class.cv::Mat"* %src, i64 0, i32 4 + store i8* null, i8** %data.i.i1491, align 8, !tbaa !63 + %723 = bitcast i8** %datastart.i.i1490 to i8* + call void @llvm.memset.p0i8.i64(i8* nonnull align 8 %723, i8 0, i64 24, i1 false) #16 + %724 = load i32*, i32** %p.i.i, align 8, !tbaa !64 + store i32 0, i32* %724, align 4, !tbaa !61 + store i32* null, i32** %refcount.i.i1485, align 8, !tbaa !62 + %725 = load i64*, i64** %p.i2.i, align 8, !tbaa !72 + %cmp.i1495 = icmp eq i64* %725, %arraydecay.i.i + br i1 %cmp.i1495, label %ehcleanup416, label %if.then.i1497 + +if.then.i1497: ; preds = %invoke.cont.i1496 + %726 = bitcast i64* %725 to i8* + invoke void @_ZN2cv8fastFreeEPv(i8* %726) + to label %ehcleanup416 unwind label %terminate.lpad.i1499 + +terminate.lpad.i1499: ; preds = %if.then.i1497, %if.then.i.i1489 + %727 = landingpad { i8*, i32 } + catch i8* null + %728 = extractvalue { i8*, i32 } %727, 0 + call void @__clang_call_terminate(i8* %728) #18 + unreachable + +ehcleanup416: ; preds = %if.then.i1497, %invoke.cont.i1496 + call void @llvm.lifetime.end.p0i8(i64 96, i8* nonnull %30) #16 + br label %ehcleanup418 + +cleanup: ; preds = %invoke.cont17, %_ZN2cv3MatD2Ev.exit1372 + %retval.0 = phi i32 [ 0, %_ZN2cv3MatD2Ev.exit1372 ], [ -1, %invoke.cont17 ] + call void @_ZN2cv12VideoCaptureD1Ev(%"class.cv::VideoCapture"* nonnull %cap) #16 + call void @llvm.lifetime.end.p0i8(i64 24, i8* nonnull %8) #16 + ret i32 %retval.0 + +ehcleanup418: ; preds = %lpad22, %ehcleanup416, %lpad13 + %ehselector.slot.31 = phi i32 [ %29, %lpad13 ], [ %ehselector.slot.23, %ehcleanup416 ], [ %61, %lpad22 ] + %exn.slot.31 = phi i8* [ %28, %lpad13 ], [ %exn.slot.23, %ehcleanup416 ], [ %60, %lpad22 ] + call void @_ZN2cv12VideoCaptureD1Ev(%"class.cv::VideoCapture"* nonnull %cap) #16 + br label %ehcleanup420 + +ehcleanup420: ; preds = %ehcleanup418, %ehcleanup + %ehselector.slot.32 = phi i32 [ %ehselector.slot.31, %ehcleanup418 ], [ %ehselector.slot.0, %ehcleanup ] + %exn.slot.32 = phi i8* [ %exn.slot.31, %ehcleanup418 ], [ %exn.slot.0, %ehcleanup ] + call void @llvm.lifetime.end.p0i8(i64 24, i8* nonnull %8) #16 + %lpad.val = insertvalue { i8*, i32 } undef, i8* %exn.slot.32, 0 + %lpad.val429 = insertvalue { i8*, i32 } %lpad.val, i32 %ehselector.slot.32, 1 + resume { i8*, i32 } %lpad.val429 +} + +; Function Attrs: nofree nounwind +declare dso_local i32 @fprintf(%struct._IO_FILE* nocapture, i8* nocapture readonly, ...) local_unnamed_addr #8 + +; Function Attrs: noreturn nounwind +declare dso_local void @exit(i32) local_unnamed_addr #9 + +; Function Attrs: inlinehint uwtable +declare dso_local dereferenceable(272) %"class.std::basic_ostream"* @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(%"class.std::basic_ostream"* dereferenceable(272), i8*) local_unnamed_addr #10 + +declare dso_local void @_ZN2cv12VideoCaptureC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(%"class.cv::VideoCapture"*, %"class.std::__cxx11::basic_string"* dereferenceable(32)) unnamed_addr #0 + +declare dso_local zeroext i1 @_ZNK2cv12VideoCapture8isOpenedEv(%"class.cv::VideoCapture"*) unnamed_addr #0 + +declare dso_local double @_ZN2cv12VideoCapture3getEi(%"class.cv::VideoCapture"*, i32) unnamed_addr #0 + +declare dso_local dereferenceable(272) %"class.std::basic_ostream"* @_ZNSolsEi(%"class.std::basic_ostream"*, i32) local_unnamed_addr #0 + +declare dso_local void @_ZN2cv11namedWindowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi(%"class.std::__cxx11::basic_string"* dereferenceable(32), i32) local_unnamed_addr #0 + +declare dso_local void @_ZN2cv10moveWindowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(%"class.std::__cxx11::basic_string"* dereferenceable(32), i32, i32) local_unnamed_addr #0 + +; Function Attrs: noreturn nounwind +declare dso_local void @__assert_fail(i8*, i8*, i32, i8*) local_unnamed_addr #9 + +declare dso_local void @__visc__init() local_unnamed_addr #0 + +; Function Attrs: nofree nounwind +declare dso_local noalias i8* @malloc(i64) local_unnamed_addr #8 + +; Function Attrs: argmemonly nounwind +declare void @llvm.memcpy.p0i8.p0i8.i64(i8* nocapture writeonly, i8* nocapture readonly, i64, i1 immarg) #3 + +; Function Attrs: argmemonly nounwind +declare void @llvm.memset.p0i8.i64(i8* nocapture writeonly, i8, i64, i1 immarg) #3 + +declare dso_local void @_ZN2cv6resizeERKNS_11_InputArrayERKNS_12_OutputArrayENS_5Size_IiEEddi(%"class.cv::_InputArray"* dereferenceable(32), %"class.cv::_OutputArray"* dereferenceable(32), %"class.cv::Size_"*, double, double, i32) local_unnamed_addr #0 + +declare dso_local void @_ZN2cv6imshowERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS_11_InputArrayE(%"class.std::__cxx11::basic_string"* dereferenceable(32), %"class.cv::_InputArray"* dereferenceable(32)) local_unnamed_addr #0 + +declare dso_local i32 @_ZN2cv7waitKeyEi(i32) local_unnamed_addr #0 + +declare dso_local i8* @__visc__launch(i32, ...) local_unnamed_addr #0 + +; Function Attrs: nounwind +declare dso_local void @_ZN2cv12VideoCaptureD1Ev(%"class.cv::VideoCapture"*) unnamed_addr #1 + +declare dso_local void @llvm_visc_track_mem(i8*, i64) local_unnamed_addr #0 + +declare dso_local void @__visc__push(i8*, i8*) local_unnamed_addr #0 + +declare dso_local i8* @__visc__pop(i8*) local_unnamed_addr #0 + +declare dso_local void @llvm_visc_request_mem(i8*, i64) local_unnamed_addr #0 + +declare dso_local void @llvm_visc_untrack_mem(i8*) local_unnamed_addr #0 + +declare dso_local void @__visc__wait(i8*) local_unnamed_addr #0 + +declare dso_local void @__visc__cleanup() local_unnamed_addr #0 + +; Function Attrs: nounwind readnone speculatable +declare float @llvm.sqrt.f32(float) #11 + +declare dso_local void @_ZN2cv3Mat6createEiPKii(%"class.cv::Mat"*, i32, i32*, i32) local_unnamed_addr #0 + +declare dso_local void @_ZN2cv3Mat8copySizeERKS0_(%"class.cv::Mat"*, %"class.cv::Mat"* dereferenceable(96)) local_unnamed_addr #0 + +declare dso_local void @_ZN2cv3Mat10deallocateEv(%"class.cv::Mat"*) local_unnamed_addr #0 + +; Function Attrs: noinline noreturn nounwind +define linkonce_odr hidden void @__clang_call_terminate(i8*) local_unnamed_addr #12 comdat { + %2 = tail call i8* @__cxa_begin_catch(i8* %0) #16 + tail call void @_ZSt9terminatev() #18 + unreachable +} + +declare dso_local i8* @__cxa_begin_catch(i8*) local_unnamed_addr + +declare dso_local void @_ZSt9terminatev() local_unnamed_addr + +declare dso_local void @_ZN2cv8fastFreeEPv(i8*) local_unnamed_addr #0 + +declare dso_local void @_ZN2cv3PtrI9CvCaptureE10delete_objEv(%"class.cv::Ptr"*) local_unnamed_addr #0 + +; Function Attrs: nobuiltin nounwind +declare dso_local void @_ZdlPv(i8*) local_unnamed_addr #13 + +; Function Attrs: noreturn +declare dso_local void @_ZSt19__throw_logic_errorPKc(i8*) local_unnamed_addr #14 + +declare dso_local i8* @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_createERmm(%"class.std::__cxx11::basic_string"*, i64* dereferenceable(8), i64) local_unnamed_addr #0 + +; Function Attrs: argmemonly nofree nounwind readonly +declare dso_local i64 @strlen(i8* nocapture) local_unnamed_addr #15 + +declare dso_local dereferenceable(272) %"class.std::basic_ostream"* @_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l(%"class.std::basic_ostream"* dereferenceable(272), i8*, i64) local_unnamed_addr #0 + +declare dso_local void @_ZNSt9basic_iosIcSt11char_traitsIcEE5clearESt12_Ios_Iostate(%"class.std::basic_ios"*, i32) local_unnamed_addr #0 + +declare dso_local dereferenceable(272) %"class.std::basic_ostream"* @_ZNSo9_M_insertImEERSoT_(%"class.std::basic_ostream"*, i64) local_unnamed_addr #0 + +; Function Attrs: uwtable +define internal void @_GLOBAL__sub_I_main.cc() #6 section ".text.startup" personality i32 (...)* @__gxx_personality_v0 { +entry: + %__dnew.i.i.i.i.i1 = alloca i64, align 8 + %__dnew.i.i.i.i.i = alloca i64, align 8 + tail call void @_ZNSt8ios_base4InitC1Ev(%"class.std::ios_base::Init"* nonnull @_ZStL8__ioinit) + %0 = tail call i32 @__cxa_atexit(void (i8*)* bitcast (void (%"class.std::ios_base::Init"*)* @_ZNSt8ios_base4InitD1Ev to void (i8*)*), i8* getelementptr inbounds (%"class.std::ios_base::Init", %"class.std::ios_base::Init"* @_ZStL8__ioinit, i64 0, i32 0), i8* nonnull @__dso_handle) #16 + store %union.anon* getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z12input_windowB5cxx11, i64 0, i32 2), %union.anon** bitcast (%"class.std::__cxx11::basic_string"* @_Z12input_windowB5cxx11 to %union.anon**), align 8, !tbaa !49 + %1 = bitcast i64* %__dnew.i.i.i.i.i to i8* + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %1) #16 + store i64 26, i64* %__dnew.i.i.i.i.i, align 8, !tbaa !51 + %call5.i.i.i9.i2.i = call i8* @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_createERmm(%"class.std::__cxx11::basic_string"* nonnull @_Z12input_windowB5cxx11, i64* nonnull dereferenceable(8) %__dnew.i.i.i.i.i, i64 0) + store i8* %call5.i.i.i9.i2.i, i8** getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z12input_windowB5cxx11, i64 0, i32 0, i32 0), align 8, !tbaa !52 + %2 = load i64, i64* %__dnew.i.i.i.i.i, align 8, !tbaa !51 + store i64 %2, i64* getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z12input_windowB5cxx11, i64 0, i32 2, i32 0), align 8, !tbaa !54 + call void @llvm.memcpy.p0i8.p0i8.i64(i8* align 1 %call5.i.i.i9.i2.i, i8* nonnull align 1 getelementptr inbounds ([27 x i8], [27 x i8]* @.str, i64 0, i64 0), i64 26, i1 false) #16 + store i64 %2, i64* getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z12input_windowB5cxx11, i64 0, i32 1), align 8, !tbaa !55 + %3 = load i8*, i8** getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z12input_windowB5cxx11, i64 0, i32 0, i32 0), align 8, !tbaa !52 + %arrayidx.i.i.i.i.i.i = getelementptr inbounds i8, i8* %3, i64 %2 + store i8 0, i8* %arrayidx.i.i.i.i.i.i, align 1, !tbaa !54 + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %1) #16 + %4 = call i32 @__cxa_atexit(void (i8*)* bitcast (void (%"class.std::__cxx11::basic_string"*)* @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev to void (i8*)*), i8* bitcast (%"class.std::__cxx11::basic_string"* @_Z12input_windowB5cxx11 to i8*), i8* nonnull @__dso_handle) #16 + store %union.anon* getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z13output_windowB5cxx11, i64 0, i32 2), %union.anon** bitcast (%"class.std::__cxx11::basic_string"* @_Z13output_windowB5cxx11 to %union.anon**), align 8, !tbaa !49 + %5 = bitcast i64* %__dnew.i.i.i.i.i1 to i8* + call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %5) #16 + store i64 27, i64* %__dnew.i.i.i.i.i1, align 8, !tbaa !51 + %call5.i.i.i9.i2.i2 = call i8* @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_createERmm(%"class.std::__cxx11::basic_string"* nonnull @_Z13output_windowB5cxx11, i64* nonnull dereferenceable(8) %__dnew.i.i.i.i.i1, i64 0) + store i8* %call5.i.i.i9.i2.i2, i8** getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z13output_windowB5cxx11, i64 0, i32 0, i32 0), align 8, !tbaa !52 + %6 = load i64, i64* %__dnew.i.i.i.i.i1, align 8, !tbaa !51 + store i64 %6, i64* getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z13output_windowB5cxx11, i64 0, i32 2, i32 0), align 8, !tbaa !54 + call void @llvm.memcpy.p0i8.p0i8.i64(i8* align 1 %call5.i.i.i9.i2.i2, i8* nonnull align 1 getelementptr inbounds ([28 x i8], [28 x i8]* @.str.3, i64 0, i64 0), i64 27, i1 false) #16 + store i64 %6, i64* getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z13output_windowB5cxx11, i64 0, i32 1), align 8, !tbaa !55 + %7 = load i8*, i8** getelementptr inbounds (%"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string"* @_Z13output_windowB5cxx11, i64 0, i32 0, i32 0), align 8, !tbaa !52 + %arrayidx.i.i.i.i.i.i3 = getelementptr inbounds i8, i8* %7, i64 %6 + store i8 0, i8* %arrayidx.i.i.i.i.i.i3, align 1, !tbaa !54 + call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %5) #16 + %8 = call i32 @__cxa_atexit(void (i8*)* bitcast (void (%"class.std::__cxx11::basic_string"*)* @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev to void (i8*)*), i8* bitcast (%"class.std::__cxx11::basic_string"* @_Z13output_windowB5cxx11 to i8*), i8* nonnull @__dso_handle) #16 + ret void +} + +; Function Attrs: nofree nounwind +declare i64 @fwrite(i8* nocapture, i64, i64, %struct._IO_FILE* nocapture) local_unnamed_addr #2 + +attributes #0 = { "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #1 = { nounwind "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #2 = { nofree nounwind } +attributes #3 = { argmemonly nounwind } +attributes #4 = { nounwind uwtable "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "min-legal-vector-width"="0" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-jump-tables"="false" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #5 = { nofree norecurse nounwind uwtable writeonly "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "min-legal-vector-width"="0" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-jump-tables"="false" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #6 = { uwtable "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "min-legal-vector-width"="0" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-jump-tables"="false" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #7 = { norecurse uwtable "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "min-legal-vector-width"="0" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-jump-tables"="false" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #8 = { nofree nounwind "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #9 = { noreturn nounwind "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #10 = { inlinehint uwtable "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "min-legal-vector-width"="0" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-jump-tables"="false" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #11 = { nounwind readnone speculatable } +attributes #12 = { noinline noreturn nounwind } +attributes #13 = { nobuiltin nounwind "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #14 = { noreturn "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #15 = { argmemonly nofree nounwind readonly "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="true" "no-nans-fp-math"="true" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="true" "use-soft-float"="false" } +attributes #16 = { nounwind } +attributes #17 = { cold } +attributes #18 = { noreturn nounwind } +attributes #19 = { noreturn } + +!llvm.module.flags = !{!0} +!llvm.ident = !{!1} + +!0 = !{i32 1, !"wchar_size", i32 4} +!1 = !{!"clang version 9.0.0 (https://gitlab.engr.illinois.edu/llvm/hpvm.git bfb1678276b5f7bc0a418da46c9b751d9f12e4e9)"} +!2 = !{!3, !4, i64 0} +!3 = !{!"_ZTS8InStruct", !4, i64 0, !7, i64 8, !4, i64 16, !7, i64 24, !4, i64 32, !7, i64 40, !4, i64 48, !7, i64 56, !4, i64 64, !7, i64 72, !4, i64 80, !7, i64 88, !4, i64 96, !7, i64 104, !4, i64 112, !7, i64 120, !4, i64 128, !7, i64 136, !4, i64 144, !7, i64 152, !4, i64 160, !7, i64 168, !7, i64 176, !7, i64 184, !7, i64 192, !7, i64 200} +!4 = !{!"any pointer", !5, i64 0} +!5 = !{!"omnipotent char", !6, i64 0} +!6 = !{!"Simple C++ TBAA"} +!7 = !{!"long", !5, i64 0} +!8 = !{!3, !7, i64 8} +!9 = !{!3, !4, i64 16} +!10 = !{!3, !7, i64 24} +!11 = !{!3, !4, i64 32} +!12 = !{!3, !7, i64 40} +!13 = !{!3, !4, i64 48} +!14 = !{!3, !7, i64 56} +!15 = !{!3, !4, i64 64} +!16 = !{!3, !7, i64 72} +!17 = !{!3, !4, i64 80} +!18 = !{!3, !7, i64 88} +!19 = !{!3, !4, i64 96} +!20 = !{!3, !7, i64 104} +!21 = !{!3, !4, i64 112} +!22 = !{!3, !7, i64 120} +!23 = !{!3, !4, i64 128} +!24 = !{!3, !7, i64 136} +!25 = !{!3, !4, i64 144} +!26 = !{!3, !7, i64 152} +!27 = !{!3, !4, i64 160} +!28 = !{!3, !7, i64 168} +!29 = !{!3, !7, i64 176} +!30 = !{!3, !7, i64 184} +!31 = !{!3, !7, i64 192} +!32 = !{!3, !7, i64 200} +!33 = !{!34, !34, i64 0} +!34 = !{!"float", !5, i64 0} +!35 = !{!36, !36, i64 0} +!36 = !{!"vtable pointer", !6, i64 0} +!37 = !{!38, !39, i64 0} +!38 = !{!"_ZTSN2cv3MatE", !39, i64 0, !39, i64 4, !39, i64 8, !39, i64 12, !4, i64 16, !4, i64 24, !4, i64 32, !4, i64 40, !4, i64 48, !4, i64 56, !40, i64 64, !41, i64 72} +!39 = !{!"int", !5, i64 0} +!40 = !{!"_ZTSN2cv3Mat5MSizeE", !4, i64 0} +!41 = !{!"_ZTSN2cv3Mat5MStepE", !4, i64 0, !5, i64 8} +!42 = !{!4, !4, i64 0} +!43 = !{!44, !46, i64 32} +!44 = !{!"_ZTSSt8ios_base", !7, i64 8, !7, i64 16, !45, i64 24, !46, i64 28, !46, i64 32, !4, i64 40, !47, i64 48, !5, i64 64, !39, i64 192, !4, i64 200, !48, i64 208} +!45 = !{!"_ZTSSt13_Ios_Fmtflags", !5, i64 0} +!46 = !{!"_ZTSSt12_Ios_Iostate", !5, i64 0} +!47 = !{!"_ZTSNSt8ios_base6_WordsE", !4, i64 0, !7, i64 8} +!48 = !{!"_ZTSSt6locale", !4, i64 0} +!49 = !{!50, !4, i64 0} +!50 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !4, i64 0} +!51 = !{!7, !7, i64 0} +!52 = !{!53, !4, i64 0} +!53 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !50, i64 0, !7, i64 8, !5, i64 16} +!54 = !{!5, !5, i64 0} +!55 = !{!53, !7, i64 8} +!56 = !{!40, !4, i64 0} +!57 = !{!41, !4, i64 0} +!58 = !{!59} +!59 = distinct !{!59, !60, !"_ZNK2cv3Mat5MSizeclEv: %agg.result"} +!60 = distinct !{!60, !"_ZNK2cv3Mat5MSizeclEv"} +!61 = !{!39, !39, i64 0} +!62 = !{!38, !4, i64 24} +!63 = !{!38, !4, i64 16} +!64 = !{!38, !4, i64 64} +!65 = !{!38, !39, i64 4} +!66 = !{!38, !39, i64 8} +!67 = !{!38, !39, i64 12} +!68 = !{!38, !4, i64 32} +!69 = !{!38, !4, i64 40} +!70 = !{!38, !4, i64 48} +!71 = !{!38, !4, i64 56} +!72 = !{!38, !4, i64 72} +!73 = !{!74, !39, i64 0} +!74 = !{!"_ZTSN2cv5Size_IiEE", !39, i64 0, !39, i64 4} +!75 = !{!74, !39, i64 4} +!76 = !{!77, !4, i64 8} +!77 = !{!"_ZTSN2cv3PtrI9CvCaptureEE", !4, i64 0, !4, i64 8} +!78 = !{!77, !4, i64 0} diff --git a/hpvm/test/parboil/benchmarks/pipeline/copyToVersions.sh b/hpvm/test/pipeline/copyToVersions.sh similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/copyToVersions.sh rename to hpvm/test/pipeline/copyToVersions.sh diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame1.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame1.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame1.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame1.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame10.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame10.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame10.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame10.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame100.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame100.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame100.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame100.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame101.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame101.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame101.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame101.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame102.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame102.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame102.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame102.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame103.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame103.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame103.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame103.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame104.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame104.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame104.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame104.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame105.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame105.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame105.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame105.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame106.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame106.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame106.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame106.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame107.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame107.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame107.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame107.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame108.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame108.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame108.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame108.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame109.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame109.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame109.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame109.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame11.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame11.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame11.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame11.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame110.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame110.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame110.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame110.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame111.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame111.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame111.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame111.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame112.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame112.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame112.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame112.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame113.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame113.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame113.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame113.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame114.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame114.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame114.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame114.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame115.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame115.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame115.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame115.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame116.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame116.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame116.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame116.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame117.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame117.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame117.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame117.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame118.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame118.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame118.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame118.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame119.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame119.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame119.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame119.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame12.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame12.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame12.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame12.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame120.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame120.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame120.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame120.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame121.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame121.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame121.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame121.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame122.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame122.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame122.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame122.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame123.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame123.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame123.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame123.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame124.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame124.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame124.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame124.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame125.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame125.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame125.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame125.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame126.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame126.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame126.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame126.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame127.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame127.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame127.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame127.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame128.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame128.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame128.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame128.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame129.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame129.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame129.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame129.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame13.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame13.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame13.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame13.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame130.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame130.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame130.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame130.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame131.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame131.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame131.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame131.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame132.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame132.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame132.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame132.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame133.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame133.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame133.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame133.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame134.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame134.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame134.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame134.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame135.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame135.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame135.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame135.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame136.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame136.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame136.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame136.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame137.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame137.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame137.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame137.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame138.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame138.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame138.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame138.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame139.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame139.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame139.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame139.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame14.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame14.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame14.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame14.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame140.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame140.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame140.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame140.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame141.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame141.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame141.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame141.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame142.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame142.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame142.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame142.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame143.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame143.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame143.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame143.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame144.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame144.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame144.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame144.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame145.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame145.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame145.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame145.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame146.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame146.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame146.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame146.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame147.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame147.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame147.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame147.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame148.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame148.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame148.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame148.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame149.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame149.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame149.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame149.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame15.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame15.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame15.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame15.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame150.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame150.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame150.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame150.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame151.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame151.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame151.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame151.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame152.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame152.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame152.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame152.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame153.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame153.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame153.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame153.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame154.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame154.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame154.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame154.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame155.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame155.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame155.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame155.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame156.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame156.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame156.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame156.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame157.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame157.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame157.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame157.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame158.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame158.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame158.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame158.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame159.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame159.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame159.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame159.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame16.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame16.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame16.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame16.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame160.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame160.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame160.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame160.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame161.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame161.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame161.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame161.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame162.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame162.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame162.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame162.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame163.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame163.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame163.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame163.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame164.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame164.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame164.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame164.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame165.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame165.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame165.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame165.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame166.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame166.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame166.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame166.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame167.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame167.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame167.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame167.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame168.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame168.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame168.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame168.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame169.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame169.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame169.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame169.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame17.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame17.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame17.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame17.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame170.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame170.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame170.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame170.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame171.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame171.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame171.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame171.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame172.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame172.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame172.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame172.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame173.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame173.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame173.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame173.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame174.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame174.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame174.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame174.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame175.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame175.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame175.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame175.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame176.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame176.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame176.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame176.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame177.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame177.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame177.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame177.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame178.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame178.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame178.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame178.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame179.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame179.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame179.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame179.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame18.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame18.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame18.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame18.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame180.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame180.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame180.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame180.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame181.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame181.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame181.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame181.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame182.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame182.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame182.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame182.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame183.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame183.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame183.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame183.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame184.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame184.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame184.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame184.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame185.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame185.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame185.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame185.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame186.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame186.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame186.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame186.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame187.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame187.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame187.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame187.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame188.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame188.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame188.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame188.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame189.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame189.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame189.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame189.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame19.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame19.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame19.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame19.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame190.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame190.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame190.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame190.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame191.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame191.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame191.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame191.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame192.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame192.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame192.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame192.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame193.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame193.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame193.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame193.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame194.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame194.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame194.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame194.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame195.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame195.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame195.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame195.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame196.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame196.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame196.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame196.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame197.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame197.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame197.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame197.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame198.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame198.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame198.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame198.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame199.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame199.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame199.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame199.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame2.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame2.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame2.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame2.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame20.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame20.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame20.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame20.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame200.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame200.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame200.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame200.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame201.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame201.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame201.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame201.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame202.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame202.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame202.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame202.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame203.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame203.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame203.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame203.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame204.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame204.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame204.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame204.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame205.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame205.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame205.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame205.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame206.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame206.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame206.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame206.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame207.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame207.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame207.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame207.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame208.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame208.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame208.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame208.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame209.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame209.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame209.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame209.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame21.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame21.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame21.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame21.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame210.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame210.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame210.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame210.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame211.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame211.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame211.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame211.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame212.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame212.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame212.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame212.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame213.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame213.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame213.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame213.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame214.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame214.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame214.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame214.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame215.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame215.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame215.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame215.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame216.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame216.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame216.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame216.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame217.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame217.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame217.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame217.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame218.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame218.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame218.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame218.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame219.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame219.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame219.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame219.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame22.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame22.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame22.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame22.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame220.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame220.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame220.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame220.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame221.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame221.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame221.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame221.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame222.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame222.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame222.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame222.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame223.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame223.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame223.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame223.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame224.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame224.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame224.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame224.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame225.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame225.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame225.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame225.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame226.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame226.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame226.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame226.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame227.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame227.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame227.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame227.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame228.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame228.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame228.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame228.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame229.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame229.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame229.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame229.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame23.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame23.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame23.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame23.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame230.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame230.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame230.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame230.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame231.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame231.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame231.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame231.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame232.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame232.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame232.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame232.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame233.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame233.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame233.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame233.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame234.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame234.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame234.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame234.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame235.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame235.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame235.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame235.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame236.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame236.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame236.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame236.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame237.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame237.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame237.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame237.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame238.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame238.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame238.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame238.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame239.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame239.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame239.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame239.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame24.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame24.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame24.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame24.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame240.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame240.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame240.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame240.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame241.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame241.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame241.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame241.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame242.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame242.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame242.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame242.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame243.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame243.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame243.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame243.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame244.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame244.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame244.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame244.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame245.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame245.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame245.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame245.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame246.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame246.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame246.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame246.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame247.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame247.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame247.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame247.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame248.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame248.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame248.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame248.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame249.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame249.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame249.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame249.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame25.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame25.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame25.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame25.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame250.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame250.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame250.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame250.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame251.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame251.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame251.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame251.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame252.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame252.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame252.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame252.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame253.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame253.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame253.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame253.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame254.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame254.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame254.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame254.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame255.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame255.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame255.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame255.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame256.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame256.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame256.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame256.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame257.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame257.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame257.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame257.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame258.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame258.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame258.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame258.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame259.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame259.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame259.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame259.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame26.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame26.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame26.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame26.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame260.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame260.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame260.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame260.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame261.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame261.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame261.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame261.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame262.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame262.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame262.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame262.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame263.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame263.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame263.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame263.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame264.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame264.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame264.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame264.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame265.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame265.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame265.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame265.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame266.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame266.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame266.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame266.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame267.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame267.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame267.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame267.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame268.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame268.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame268.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame268.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame269.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame269.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame269.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame269.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame27.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame27.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame27.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame27.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame270.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame270.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame270.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame270.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame271.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame271.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame271.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame271.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame272.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame272.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame272.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame272.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame273.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame273.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame273.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame273.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame274.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame274.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame274.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame274.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame275.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame275.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame275.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame275.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame276.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame276.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame276.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame276.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame277.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame277.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame277.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame277.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame278.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame278.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame278.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame278.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame279.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame279.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame279.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame279.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame28.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame28.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame28.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame28.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame280.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame280.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame280.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame280.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame281.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame281.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame281.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame281.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame282.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame282.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame282.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame282.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame283.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame283.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame283.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame283.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame284.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame284.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame284.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame284.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame285.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame285.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame285.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame285.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame286.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame286.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame286.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame286.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame287.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame287.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame287.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame287.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame288.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame288.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame288.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame288.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame289.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame289.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame289.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame289.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame29.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame29.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame29.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame29.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame290.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame290.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame290.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame290.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame291.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame291.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame291.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame291.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame292.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame292.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame292.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame292.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame293.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame293.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame293.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame293.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame294.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame294.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame294.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame294.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame295.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame295.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame295.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame295.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame296.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame296.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame296.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame296.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame297.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame297.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame297.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame297.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame298.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame298.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame298.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame298.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame299.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame299.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame299.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame299.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame3.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame3.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame3.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame3.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame30.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame30.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame30.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame30.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame300.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame300.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame300.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame300.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame301.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame301.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame301.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame301.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame302.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame302.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame302.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame302.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame303.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame303.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame303.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame303.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame304.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame304.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame304.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame304.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame305.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame305.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame305.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame305.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame306.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame306.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame306.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame306.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame307.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame307.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame307.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame307.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame308.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame308.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame308.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame308.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame309.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame309.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame309.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame309.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame31.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame31.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame31.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame31.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame310.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame310.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame310.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame310.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame311.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame311.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame311.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame311.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame312.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame312.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame312.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame312.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame313.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame313.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame313.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame313.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame314.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame314.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame314.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame314.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame315.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame315.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame315.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame315.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame316.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame316.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame316.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame316.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame317.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame317.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame317.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame317.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame318.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame318.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame318.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame318.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame319.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame319.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame319.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame319.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame32.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame32.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame32.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame32.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame320.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame320.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame320.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame320.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame321.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame321.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame321.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame321.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame322.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame322.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame322.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame322.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame323.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame323.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame323.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame323.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame324.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame324.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame324.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame324.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame325.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame325.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame325.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame325.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame326.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame326.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame326.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame326.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame327.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame327.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame327.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame327.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame328.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame328.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame328.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame328.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame329.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame329.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame329.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame329.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame33.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame33.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame33.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame33.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame330.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame330.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame330.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame330.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame331.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame331.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame331.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame331.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame332.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame332.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame332.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame332.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame333.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame333.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame333.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame333.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame334.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame334.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame334.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame334.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame335.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame335.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame335.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame335.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame336.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame336.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame336.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame336.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame337.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame337.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame337.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame337.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame338.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame338.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame338.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame338.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame339.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame339.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame339.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame339.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame34.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame34.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame34.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame34.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame340.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame340.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame340.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame340.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame341.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame341.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame341.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame341.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame342.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame342.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame342.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame342.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame343.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame343.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame343.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame343.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame344.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame344.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame344.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame344.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame345.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame345.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame345.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame345.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame346.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame346.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame346.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame346.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame347.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame347.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame347.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame347.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame348.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame348.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame348.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame348.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame349.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame349.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame349.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame349.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame35.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame35.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame35.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame35.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame350.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame350.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame350.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame350.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame351.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame351.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame351.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame351.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame352.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame352.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame352.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame352.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame353.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame353.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame353.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame353.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame354.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame354.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame354.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame354.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame355.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame355.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame355.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame355.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame356.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame356.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame356.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame356.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame357.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame357.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame357.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame357.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame358.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame358.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame358.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame358.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame359.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame359.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame359.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame359.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame36.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame36.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame36.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame36.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame360.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame360.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame360.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame360.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame361.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame361.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame361.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame361.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame362.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame362.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame362.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame362.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame363.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame363.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame363.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame363.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame364.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame364.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame364.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame364.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame365.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame365.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame365.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame365.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame366.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame366.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame366.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame366.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame367.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame367.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame367.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame367.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame368.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame368.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame368.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame368.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame369.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame369.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame369.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame369.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame37.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame37.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame37.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame37.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame370.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame370.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame370.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame370.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame371.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame371.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame371.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame371.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame372.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame372.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame372.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame372.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame373.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame373.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame373.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame373.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame374.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame374.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame374.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame374.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame375.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame375.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame375.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame375.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame376.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame376.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame376.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame376.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame377.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame377.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame377.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame377.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame378.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame378.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame378.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame378.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame379.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame379.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame379.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame379.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame38.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame38.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame38.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame38.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame380.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame380.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame380.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame380.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame381.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame381.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame381.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame381.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame382.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame382.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame382.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame382.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame383.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame383.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame383.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame383.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame384.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame384.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame384.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame384.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame385.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame385.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame385.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame385.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame386.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame386.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame386.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame386.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame387.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame387.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame387.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame387.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame388.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame388.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame388.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame388.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame389.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame389.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame389.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame389.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame39.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame39.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame39.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame39.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame390.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame390.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame390.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame390.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame391.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame391.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame391.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame391.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame392.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame392.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame392.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame392.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame393.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame393.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame393.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame393.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame394.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame394.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame394.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame394.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame395.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame395.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame395.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame395.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame396.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame396.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame396.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame396.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame397.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame397.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame397.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame397.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame398.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame398.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame398.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame398.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame399.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame399.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame399.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame399.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame4.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame4.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame4.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame4.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame40.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame40.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame40.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame40.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame400.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame400.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame400.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame400.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame401.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame401.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame401.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame401.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame402.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame402.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame402.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame402.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame403.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame403.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame403.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame403.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame404.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame404.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame404.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame404.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame405.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame405.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame405.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame405.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame406.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame406.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame406.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame406.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame407.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame407.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame407.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame407.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame408.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame408.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame408.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame408.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame409.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame409.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame409.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame409.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame41.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame41.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame41.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame41.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame410.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame410.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame410.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame410.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame411.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame411.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame411.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame411.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame412.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame412.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame412.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame412.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame413.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame413.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame413.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame413.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame414.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame414.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame414.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame414.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame415.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame415.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame415.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame415.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame416.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame416.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame416.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame416.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame417.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame417.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame417.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame417.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame418.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame418.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame418.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame418.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame419.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame419.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame419.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame419.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame42.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame42.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame42.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame42.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame420.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame420.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame420.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame420.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame421.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame421.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame421.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame421.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame422.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame422.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame422.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame422.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame423.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame423.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame423.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame423.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame424.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame424.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame424.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame424.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame425.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame425.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame425.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame425.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame426.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame426.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame426.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame426.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame427.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame427.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame427.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame427.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame428.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame428.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame428.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame428.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame429.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame429.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame429.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame429.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame43.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame43.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame43.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame43.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame430.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame430.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame430.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame430.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame431.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame431.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame431.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame431.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame432.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame432.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame432.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame432.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame433.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame433.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame433.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame433.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame434.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame434.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame434.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame434.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame435.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame435.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame435.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame435.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame436.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame436.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame436.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame436.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame437.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame437.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame437.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame437.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame438.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame438.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame438.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame438.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame439.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame439.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame439.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame439.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame44.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame44.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame44.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame44.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame440.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame440.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame440.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame440.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame441.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame441.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame441.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame441.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame442.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame442.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame442.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame442.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame443.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame443.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame443.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame443.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame444.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame444.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame444.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame444.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame445.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame445.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame445.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame445.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame446.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame446.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame446.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame446.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame447.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame447.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame447.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame447.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame448.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame448.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame448.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame448.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame449.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame449.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame449.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame449.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame45.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame45.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame45.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame45.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame450.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame450.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame450.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame450.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame451.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame451.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame451.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame451.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame452.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame452.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame452.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame452.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame453.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame453.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame453.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame453.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame454.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame454.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame454.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame454.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame455.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame455.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame455.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame455.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame456.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame456.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame456.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame456.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame457.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame457.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame457.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame457.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame458.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame458.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame458.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame458.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame459.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame459.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame459.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame459.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame46.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame46.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame46.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame46.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame460.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame460.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame460.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame460.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame461.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame461.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame461.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame461.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame462.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame462.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame462.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame462.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame463.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame463.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame463.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame463.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame464.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame464.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame464.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame464.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame465.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame465.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame465.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame465.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame466.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame466.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame466.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame466.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame467.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame467.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame467.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame467.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame468.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame468.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame468.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame468.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame469.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame469.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame469.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame469.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame47.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame47.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame47.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame47.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame470.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame470.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame470.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame470.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame471.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame471.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame471.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame471.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame472.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame472.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame472.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame472.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame473.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame473.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame473.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame473.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame474.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame474.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame474.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame474.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame475.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame475.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame475.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame475.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame476.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame476.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame476.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame476.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame477.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame477.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame477.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame477.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame478.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame478.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame478.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame478.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame479.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame479.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame479.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame479.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame48.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame48.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame48.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame48.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame480.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame480.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame480.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame480.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame481.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame481.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame481.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame481.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame482.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame482.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame482.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame482.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame483.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame483.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame483.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame483.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame484.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame484.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame484.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame484.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame485.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame485.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame485.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame485.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame486.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame486.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame486.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame486.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame487.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame487.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame487.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame487.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame488.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame488.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame488.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame488.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame489.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame489.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame489.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame489.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame49.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame49.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame49.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame49.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame490.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame490.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame490.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame490.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame491.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame491.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame491.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame491.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame492.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame492.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame492.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame492.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame493.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame493.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame493.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame493.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame494.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame494.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame494.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame494.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame495.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame495.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame495.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame495.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame496.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame496.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame496.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame496.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame497.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame497.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame497.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame497.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame498.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame498.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame498.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame498.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame499.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame499.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame499.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame499.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame5.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame5.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame5.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame5.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame50.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame50.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame50.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame50.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame500.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame500.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame500.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame500.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame501.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame501.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame501.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame501.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame502.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame502.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame502.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame502.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame503.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame503.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame503.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame503.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame504.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame504.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame504.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame504.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame505.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame505.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame505.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame505.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame506.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame506.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame506.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame506.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame507.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame507.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame507.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame507.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame508.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame508.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame508.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame508.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame509.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame509.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame509.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame509.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame51.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame51.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame51.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame51.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame510.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame510.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame510.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame510.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame511.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame511.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame511.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame511.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame512.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame512.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame512.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame512.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame513.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame513.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame513.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame513.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame514.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame514.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame514.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame514.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame515.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame515.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame515.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame515.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame516.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame516.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame516.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame516.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame517.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame517.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame517.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame517.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame518.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame518.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame518.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame518.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame519.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame519.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame519.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame519.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame52.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame52.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame52.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame52.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame520.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame520.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame520.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame520.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame521.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame521.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame521.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame521.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame522.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame522.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame522.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame522.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame523.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame523.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame523.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame523.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame524.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame524.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame524.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame524.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame525.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame525.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame525.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame525.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame526.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame526.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame526.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame526.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame527.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame527.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame527.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame527.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame528.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame528.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame528.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame528.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame529.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame529.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame529.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame529.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame53.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame53.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame53.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame53.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame530.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame530.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame530.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame530.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame531.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame531.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame531.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame531.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame532.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame532.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame532.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame532.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame533.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame533.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame533.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame533.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame534.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame534.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame534.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame534.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame535.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame535.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame535.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame535.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame536.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame536.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame536.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame536.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame537.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame537.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame537.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame537.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame538.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame538.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame538.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame538.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame539.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame539.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame539.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame539.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame54.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame54.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame54.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame54.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame540.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame540.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame540.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame540.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame541.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame541.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame541.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame541.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame542.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame542.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame542.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame542.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame543.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame543.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame543.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame543.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame544.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame544.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame544.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame544.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame545.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame545.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame545.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame545.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame546.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame546.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame546.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame546.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame547.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame547.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame547.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame547.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame548.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame548.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame548.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame548.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame549.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame549.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame549.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame549.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame55.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame55.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame55.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame55.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame550.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame550.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame550.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame550.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame551.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame551.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame551.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame551.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame552.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame552.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame552.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame552.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame553.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame553.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame553.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame553.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame554.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame554.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame554.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame554.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame555.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame555.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame555.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame555.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame556.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame556.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame556.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame556.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame557.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame557.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame557.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame557.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame558.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame558.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame558.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame558.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame559.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame559.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame559.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame559.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame56.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame56.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame56.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame56.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame560.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame560.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame560.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame560.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame561.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame561.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame561.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame561.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame562.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame562.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame562.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame562.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame563.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame563.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame563.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame563.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame564.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame564.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame564.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame564.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame565.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame565.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame565.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame565.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame566.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame566.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame566.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame566.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame567.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame567.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame567.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame567.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame568.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame568.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame568.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame568.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame569.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame569.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame569.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame569.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame57.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame57.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame57.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame57.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame570.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame570.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame570.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame570.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame571.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame571.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame571.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame571.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame572.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame572.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame572.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame572.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame573.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame573.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame573.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame573.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame574.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame574.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame574.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame574.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame575.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame575.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame575.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame575.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame576.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame576.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame576.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame576.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame577.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame577.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame577.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame577.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame578.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame578.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame578.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame578.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame579.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame579.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame579.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame579.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame58.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame58.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame58.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame58.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame580.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame580.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame580.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame580.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame581.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame581.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame581.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame581.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame582.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame582.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame582.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame582.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame583.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame583.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame583.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame583.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame584.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame584.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame584.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame584.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame585.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame585.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame585.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame585.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame586.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame586.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame586.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame586.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame587.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame587.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame587.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame587.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame588.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame588.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame588.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame588.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame589.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame589.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame589.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame589.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame59.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame59.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame59.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame59.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame590.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame590.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame590.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame590.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame591.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame591.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame591.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame591.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame592.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame592.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame592.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame592.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame593.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame593.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame593.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame593.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame594.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame594.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame594.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame594.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame595.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame595.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame595.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame595.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame596.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame596.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame596.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame596.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame597.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame597.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame597.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame597.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame598.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame598.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame598.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame598.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame599.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame599.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame599.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame599.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame6.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame6.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame6.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame6.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame60.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame60.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame60.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame60.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame600.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame600.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame600.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame600.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame61.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame61.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame61.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame61.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame62.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame62.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame62.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame62.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame63.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame63.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame63.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame63.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame64.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame64.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame64.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame64.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame65.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame65.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame65.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame65.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame66.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame66.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame66.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame66.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame67.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame67.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame67.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame67.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame68.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame68.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame68.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame68.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame69.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame69.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame69.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame69.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame7.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame7.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame7.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame7.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame70.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame70.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame70.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame70.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame71.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame71.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame71.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame71.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame72.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame72.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame72.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame72.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame73.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame73.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame73.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame73.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame74.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame74.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame74.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame74.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame75.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame75.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame75.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame75.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame76.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame76.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame76.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame76.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame77.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame77.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame77.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame77.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame78.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame78.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame78.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame78.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame79.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame79.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame79.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame79.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame8.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame8.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame8.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame8.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame80.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame80.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame80.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame80.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame81.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame81.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame81.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame81.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame82.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame82.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame82.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame82.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame83.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame83.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame83.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame83.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame84.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame84.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame84.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame84.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame85.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame85.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame85.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame85.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame86.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame86.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame86.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame86.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame87.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame87.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame87.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame87.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame88.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame88.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame88.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame88.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame89.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame89.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame89.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame89.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame9.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame9.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame9.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame9.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame90.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame90.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame90.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame90.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame91.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame91.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame91.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame91.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame92.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame92.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame92.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame92.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame93.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame93.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame93.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame93.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame94.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame94.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame94.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame94.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame95.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame95.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame95.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame95.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame96.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame96.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame96.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame96.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame97.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame97.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame97.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame97.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame98.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame98.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame98.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame98.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula/frame99.jpg b/hpvm/test/pipeline/datasets/big/input/formula/frame99.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula/frame99.jpg rename to hpvm/test/pipeline/datasets/big/input/formula/frame99.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/formula1_scaled.mp4 b/hpvm/test/pipeline/datasets/big/input/formula1_scaled.mp4 similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/formula1_scaled.mp4 rename to hpvm/test/pipeline/datasets/big/input/formula1_scaled.mp4 diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame1.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame1.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame1.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame1.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame10.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame10.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame10.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame10.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame100.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame100.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame100.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame100.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame101.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame101.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame101.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame101.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame102.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame102.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame102.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame102.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame103.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame103.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame103.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame103.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame104.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame104.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame104.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame104.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame105.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame105.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame105.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame105.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame106.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame106.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame106.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame106.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame107.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame107.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame107.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame107.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame108.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame108.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame108.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame108.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame109.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame109.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame109.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame109.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame11.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame11.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame11.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame11.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame110.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame110.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame110.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame110.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame111.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame111.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame111.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame111.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame112.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame112.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame112.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame112.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame113.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame113.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame113.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame113.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame114.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame114.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame114.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame114.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame115.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame115.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame115.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame115.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame116.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame116.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame116.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame116.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame117.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame117.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame117.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame117.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame118.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame118.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame118.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame118.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame119.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame119.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame119.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame119.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame12.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame12.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame12.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame12.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame120.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame120.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame120.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame120.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame121.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame121.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame121.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame121.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame122.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame122.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame122.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame122.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame123.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame123.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame123.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame123.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame124.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame124.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame124.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame124.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame125.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame125.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame125.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame125.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame126.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame126.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame126.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame126.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame127.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame127.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame127.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame127.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame128.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame128.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame128.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame128.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame129.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame129.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame129.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame129.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame13.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame13.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame13.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame13.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame130.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame130.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame130.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame130.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame131.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame131.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame131.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame131.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame132.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame132.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame132.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame132.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame133.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame133.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame133.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame133.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame134.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame134.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame134.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame134.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame135.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame135.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame135.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame135.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame136.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame136.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame136.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame136.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame137.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame137.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame137.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame137.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame138.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame138.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame138.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame138.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame139.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame139.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame139.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame139.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame14.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame14.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame14.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame14.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame140.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame140.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame140.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame140.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame141.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame141.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame141.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame141.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame142.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame142.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame142.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame142.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame143.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame143.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame143.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame143.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame144.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame144.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame144.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame144.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame145.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame145.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame145.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame145.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame146.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame146.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame146.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame146.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame147.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame147.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame147.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame147.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame148.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame148.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame148.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame148.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame149.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame149.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame149.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame149.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame15.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame15.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame15.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame15.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame150.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame150.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame150.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame150.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame151.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame151.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame151.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame151.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame152.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame152.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame152.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame152.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame153.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame153.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame153.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame153.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame154.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame154.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame154.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame154.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame155.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame155.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame155.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame155.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame156.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame156.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame156.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame156.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame157.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame157.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame157.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame157.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame158.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame158.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame158.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame158.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame159.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame159.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame159.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame159.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame16.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame16.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame16.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame16.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame160.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame160.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame160.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame160.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame161.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame161.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame161.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame161.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame162.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame162.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame162.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame162.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame163.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame163.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame163.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame163.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame164.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame164.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame164.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame164.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame165.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame165.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame165.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame165.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame166.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame166.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame166.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame166.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame167.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame167.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame167.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame167.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame168.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame168.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame168.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame168.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame169.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame169.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame169.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame169.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame17.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame17.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame17.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame17.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame170.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame170.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame170.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame170.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame171.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame171.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame171.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame171.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame172.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame172.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame172.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame172.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame173.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame173.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame173.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame173.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame174.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame174.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame174.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame174.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame175.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame175.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame175.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame175.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame176.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame176.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame176.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame176.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame177.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame177.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame177.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame177.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame178.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame178.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame178.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame178.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame179.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame179.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame179.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame179.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame18.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame18.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame18.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame18.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame180.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame180.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame180.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame180.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame181.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame181.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame181.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame181.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame182.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame182.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame182.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame182.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame183.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame183.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame183.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame183.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame184.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame184.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame184.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame184.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame185.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame185.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame185.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame185.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame186.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame186.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame186.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame186.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame187.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame187.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame187.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame187.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame188.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame188.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame188.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame188.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame189.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame189.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame189.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame189.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame19.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame19.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame19.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame19.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame190.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame190.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame190.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame190.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame191.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame191.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame191.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame191.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame192.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame192.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame192.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame192.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame193.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame193.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame193.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame193.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame194.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame194.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame194.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame194.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame195.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame195.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame195.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame195.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame196.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame196.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame196.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame196.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame197.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame197.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame197.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame197.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame198.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame198.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame198.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame198.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame199.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame199.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame199.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame199.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame2.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame2.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame2.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame2.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame20.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame20.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame20.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame20.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame200.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame200.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame200.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame200.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame201.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame201.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame201.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame201.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame202.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame202.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame202.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame202.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame203.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame203.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame203.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame203.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame204.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame204.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame204.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame204.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame205.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame205.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame205.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame205.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame206.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame206.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame206.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame206.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame207.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame207.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame207.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame207.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame208.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame208.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame208.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame208.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame209.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame209.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame209.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame209.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame21.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame21.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame21.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame21.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame210.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame210.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame210.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame210.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame211.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame211.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame211.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame211.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame212.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame212.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame212.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame212.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame213.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame213.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame213.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame213.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame214.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame214.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame214.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame214.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame215.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame215.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame215.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame215.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame216.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame216.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame216.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame216.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame217.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame217.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame217.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame217.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame218.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame218.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame218.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame218.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame219.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame219.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame219.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame219.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame22.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame22.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame22.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame22.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame220.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame220.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame220.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame220.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame221.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame221.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame221.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame221.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame222.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame222.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame222.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame222.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame223.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame223.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame223.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame223.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame224.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame224.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame224.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame224.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame225.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame225.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame225.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame225.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame226.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame226.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame226.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame226.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame227.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame227.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame227.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame227.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame228.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame228.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame228.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame228.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame229.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame229.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame229.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame229.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame23.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame23.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame23.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame23.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame230.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame230.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame230.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame230.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame231.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame231.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame231.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame231.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame232.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame232.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame232.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame232.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame233.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame233.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame233.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame233.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame234.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame234.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame234.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame234.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame235.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame235.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame235.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame235.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame236.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame236.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame236.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame236.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame237.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame237.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame237.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame237.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame238.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame238.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame238.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame238.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame239.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame239.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame239.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame239.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame24.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame24.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame24.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame24.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame240.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame240.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame240.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame240.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame241.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame241.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame241.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame241.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame242.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame242.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame242.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame242.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame243.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame243.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame243.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame243.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame244.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame244.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame244.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame244.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame245.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame245.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame245.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame245.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame246.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame246.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame246.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame246.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame247.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame247.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame247.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame247.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame248.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame248.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame248.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame248.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame249.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame249.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame249.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame249.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame25.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame25.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame25.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame25.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame250.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame250.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame250.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame250.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame251.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame251.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame251.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame251.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame252.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame252.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame252.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame252.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame253.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame253.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame253.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame253.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame254.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame254.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame254.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame254.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame255.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame255.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame255.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame255.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame256.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame256.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame256.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame256.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame257.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame257.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame257.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame257.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame258.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame258.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame258.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame258.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame259.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame259.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame259.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame259.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame26.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame26.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame26.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame26.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame260.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame260.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame260.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame260.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame261.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame261.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame261.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame261.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame262.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame262.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame262.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame262.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame263.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame263.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame263.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame263.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame264.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame264.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame264.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame264.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame265.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame265.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame265.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame265.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame266.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame266.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame266.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame266.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame267.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame267.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame267.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame267.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame268.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame268.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame268.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame268.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame269.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame269.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame269.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame269.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame27.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame27.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame27.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame27.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame270.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame270.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame270.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame270.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame271.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame271.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame271.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame271.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame272.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame272.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame272.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame272.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame273.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame273.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame273.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame273.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame274.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame274.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame274.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame274.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame275.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame275.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame275.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame275.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame276.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame276.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame276.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame276.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame277.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame277.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame277.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame277.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame278.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame278.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame278.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame278.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame279.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame279.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame279.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame279.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame28.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame28.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame28.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame28.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame280.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame280.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame280.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame280.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame281.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame281.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame281.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame281.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame282.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame282.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame282.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame282.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame283.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame283.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame283.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame283.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame284.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame284.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame284.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame284.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame285.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame285.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame285.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame285.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame286.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame286.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame286.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame286.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame287.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame287.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame287.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame287.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame288.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame288.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame288.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame288.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame289.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame289.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame289.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame289.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame29.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame29.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame29.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame29.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame290.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame290.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame290.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame290.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame291.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame291.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame291.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame291.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame292.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame292.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame292.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame292.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame293.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame293.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame293.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame293.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame294.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame294.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame294.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame294.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame295.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame295.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame295.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame295.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame296.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame296.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame296.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame296.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame297.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame297.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame297.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame297.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame298.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame298.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame298.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame298.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame299.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame299.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame299.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame299.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame3.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame3.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame3.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame3.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame30.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame30.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame30.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame30.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame300.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame300.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame300.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame300.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame301.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame301.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame301.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame301.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame302.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame302.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame302.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame302.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame303.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame303.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame303.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame303.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame304.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame304.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame304.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame304.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame305.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame305.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame305.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame305.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame306.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame306.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame306.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame306.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame307.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame307.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame307.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame307.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame308.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame308.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame308.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame308.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame309.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame309.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame309.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame309.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame31.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame31.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame31.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame31.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame310.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame310.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame310.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame310.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame311.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame311.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame311.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame311.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame312.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame312.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame312.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame312.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame313.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame313.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame313.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame313.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame314.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame314.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame314.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame314.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame315.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame315.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame315.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame315.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame316.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame316.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame316.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame316.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame317.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame317.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame317.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame317.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame318.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame318.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame318.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame318.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame319.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame319.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame319.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame319.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame32.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame32.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame32.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame32.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame320.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame320.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame320.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame320.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame321.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame321.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame321.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame321.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame322.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame322.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame322.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame322.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame323.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame323.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame323.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame323.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame324.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame324.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame324.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame324.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame325.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame325.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame325.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame325.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame326.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame326.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame326.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame326.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame327.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame327.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame327.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame327.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame328.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame328.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame328.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame328.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame329.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame329.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame329.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame329.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame33.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame33.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame33.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame33.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame330.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame330.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame330.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame330.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame331.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame331.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame331.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame331.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame332.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame332.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame332.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame332.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame333.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame333.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame333.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame333.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame334.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame334.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame334.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame334.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame335.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame335.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame335.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame335.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame336.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame336.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame336.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame336.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame337.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame337.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame337.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame337.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame338.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame338.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame338.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame338.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame339.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame339.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame339.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame339.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame34.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame34.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame34.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame34.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame340.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame340.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame340.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame340.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame341.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame341.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame341.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame341.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame342.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame342.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame342.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame342.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame343.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame343.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame343.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame343.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame344.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame344.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame344.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame344.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame345.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame345.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame345.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame345.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame346.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame346.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame346.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame346.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame347.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame347.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame347.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame347.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame348.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame348.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame348.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame348.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame349.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame349.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame349.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame349.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame35.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame35.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame35.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame35.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame350.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame350.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame350.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame350.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame351.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame351.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame351.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame351.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame352.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame352.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame352.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame352.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame353.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame353.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame353.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame353.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame354.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame354.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame354.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame354.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame355.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame355.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame355.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame355.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame356.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame356.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame356.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame356.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame357.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame357.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame357.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame357.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame358.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame358.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame358.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame358.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame359.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame359.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame359.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame359.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame36.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame36.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame36.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame36.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame360.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame360.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame360.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame360.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame361.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame361.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame361.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame361.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame362.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame362.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame362.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame362.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame363.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame363.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame363.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame363.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame364.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame364.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame364.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame364.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame365.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame365.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame365.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame365.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame366.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame366.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame366.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame366.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame367.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame367.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame367.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame367.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame368.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame368.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame368.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame368.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame369.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame369.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame369.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame369.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame37.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame37.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame37.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame37.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame370.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame370.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame370.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame370.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame371.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame371.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame371.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame371.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame372.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame372.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame372.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame372.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame373.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame373.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame373.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame373.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame374.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame374.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame374.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame374.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame375.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame375.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame375.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame375.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame376.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame376.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame376.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame376.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame377.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame377.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame377.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame377.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame378.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame378.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame378.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame378.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame379.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame379.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame379.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame379.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame38.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame38.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame38.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame38.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame380.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame380.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame380.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame380.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame381.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame381.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame381.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame381.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame382.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame382.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame382.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame382.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame383.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame383.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame383.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame383.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame384.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame384.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame384.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame384.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame385.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame385.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame385.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame385.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame386.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame386.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame386.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame386.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame387.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame387.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame387.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame387.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame388.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame388.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame388.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame388.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame389.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame389.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame389.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame389.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame39.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame39.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame39.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame39.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame390.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame390.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame390.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame390.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame391.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame391.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame391.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame391.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame392.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame392.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame392.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame392.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame393.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame393.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame393.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame393.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame394.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame394.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame394.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame394.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame395.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame395.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame395.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame395.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame396.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame396.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame396.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame396.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame397.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame397.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame397.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame397.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame398.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame398.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame398.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame398.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame399.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame399.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame399.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame399.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame4.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame4.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame4.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame4.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame40.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame40.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame40.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame40.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame400.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame400.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame400.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame400.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame401.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame401.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame401.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame401.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame402.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame402.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame402.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame402.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame403.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame403.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame403.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame403.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame404.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame404.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame404.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame404.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame405.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame405.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame405.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame405.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame406.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame406.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame406.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame406.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame407.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame407.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame407.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame407.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame408.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame408.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame408.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame408.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame409.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame409.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame409.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame409.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame41.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame41.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame41.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame41.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame410.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame410.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame410.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame410.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame411.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame411.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame411.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame411.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame412.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame412.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame412.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame412.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame413.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame413.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame413.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame413.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame414.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame414.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame414.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame414.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame415.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame415.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame415.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame415.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame416.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame416.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame416.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame416.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame417.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame417.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame417.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame417.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame418.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame418.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame418.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame418.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame419.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame419.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame419.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame419.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame42.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame42.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame42.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame42.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame420.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame420.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame420.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame420.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame421.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame421.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame421.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame421.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame422.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame422.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame422.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame422.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame423.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame423.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame423.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame423.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame424.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame424.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame424.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame424.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame425.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame425.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame425.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame425.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame426.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame426.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame426.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame426.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame427.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame427.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame427.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame427.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame428.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame428.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame428.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame428.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame429.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame429.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame429.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame429.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame43.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame43.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame43.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame43.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame430.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame430.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame430.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame430.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame431.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame431.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame431.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame431.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame432.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame432.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame432.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame432.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame433.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame433.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame433.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame433.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame434.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame434.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame434.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame434.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame435.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame435.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame435.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame435.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame436.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame436.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame436.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame436.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame437.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame437.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame437.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame437.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame438.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame438.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame438.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame438.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame439.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame439.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame439.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame439.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame44.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame44.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame44.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame44.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame440.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame440.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame440.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame440.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame441.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame441.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame441.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame441.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame442.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame442.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame442.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame442.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame443.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame443.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame443.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame443.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame444.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame444.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame444.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame444.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame445.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame445.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame445.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame445.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame446.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame446.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame446.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame446.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame447.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame447.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame447.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame447.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame448.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame448.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame448.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame448.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame449.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame449.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame449.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame449.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame45.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame45.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame45.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame45.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame450.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame450.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame450.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame450.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame451.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame451.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame451.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame451.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame452.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame452.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame452.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame452.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame453.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame453.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame453.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame453.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame454.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame454.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame454.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame454.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame455.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame455.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame455.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame455.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame456.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame456.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame456.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame456.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame457.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame457.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame457.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame457.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame458.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame458.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame458.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame458.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame459.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame459.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame459.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame459.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame46.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame46.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame46.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame46.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame460.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame460.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame460.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame460.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame461.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame461.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame461.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame461.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame462.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame462.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame462.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame462.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame463.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame463.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame463.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame463.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame464.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame464.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame464.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame464.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame465.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame465.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame465.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame465.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame466.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame466.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame466.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame466.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame467.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame467.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame467.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame467.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame468.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame468.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame468.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame468.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame469.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame469.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame469.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame469.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame47.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame47.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame47.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame47.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame470.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame470.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame470.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame470.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame471.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame471.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame471.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame471.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame472.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame472.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame472.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame472.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame473.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame473.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame473.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame473.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame474.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame474.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame474.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame474.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame475.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame475.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame475.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame475.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame476.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame476.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame476.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame476.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame477.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame477.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame477.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame477.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame478.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame478.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame478.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame478.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame479.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame479.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame479.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame479.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame48.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame48.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame48.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame48.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame480.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame480.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame480.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame480.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame481.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame481.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame481.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame481.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame482.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame482.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame482.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame482.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame483.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame483.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame483.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame483.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame484.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame484.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame484.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame484.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame485.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame485.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame485.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame485.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame486.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame486.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame486.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame486.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame487.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame487.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame487.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame487.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame488.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame488.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame488.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame488.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame489.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame489.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame489.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame489.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame49.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame49.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame49.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame49.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame490.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame490.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame490.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame490.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame491.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame491.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame491.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame491.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame492.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame492.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame492.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame492.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame493.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame493.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame493.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame493.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame494.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame494.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame494.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame494.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame495.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame495.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame495.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame495.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame496.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame496.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame496.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame496.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame497.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame497.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame497.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame497.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame498.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame498.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame498.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame498.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame499.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame499.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame499.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame499.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame5.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame5.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame5.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame5.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame50.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame50.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame50.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame50.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame500.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame500.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame500.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame500.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame501.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame501.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame501.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame501.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame502.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame502.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame502.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame502.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame503.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame503.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame503.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame503.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame504.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame504.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame504.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame504.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame505.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame505.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame505.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame505.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame506.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame506.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame506.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame506.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame507.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame507.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame507.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame507.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame508.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame508.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame508.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame508.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame509.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame509.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame509.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame509.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame51.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame51.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame51.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame51.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame510.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame510.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame510.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame510.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame511.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame511.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame511.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame511.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame512.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame512.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame512.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame512.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame513.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame513.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame513.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame513.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame514.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame514.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame514.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame514.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame515.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame515.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame515.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame515.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame516.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame516.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame516.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame516.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame517.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame517.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame517.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame517.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame518.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame518.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame518.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame518.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame519.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame519.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame519.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame519.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame52.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame52.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame52.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame52.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame520.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame520.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame520.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame520.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame521.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame521.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame521.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame521.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame522.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame522.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame522.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame522.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame523.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame523.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame523.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame523.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame524.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame524.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame524.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame524.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame525.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame525.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame525.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame525.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame526.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame526.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame526.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame526.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame527.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame527.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame527.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame527.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame528.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame528.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame528.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame528.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame529.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame529.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame529.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame529.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame53.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame53.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame53.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame53.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame530.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame530.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame530.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame530.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame531.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame531.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame531.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame531.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame532.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame532.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame532.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame532.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame533.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame533.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame533.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame533.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame534.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame534.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame534.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame534.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame535.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame535.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame535.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame535.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame536.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame536.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame536.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame536.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame537.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame537.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame537.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame537.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame538.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame538.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame538.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame538.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame539.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame539.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame539.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame539.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame54.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame54.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame54.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame54.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame540.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame540.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame540.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame540.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame541.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame541.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame541.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame541.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame542.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame542.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame542.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame542.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame543.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame543.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame543.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame543.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame544.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame544.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame544.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame544.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame545.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame545.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame545.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame545.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame546.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame546.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame546.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame546.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame547.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame547.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame547.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame547.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame548.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame548.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame548.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame548.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame549.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame549.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame549.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame549.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame55.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame55.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame55.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame55.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame550.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame550.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame550.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame550.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame551.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame551.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame551.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame551.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame552.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame552.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame552.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame552.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame553.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame553.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame553.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame553.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame554.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame554.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame554.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame554.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame555.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame555.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame555.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame555.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame556.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame556.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame556.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame556.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame557.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame557.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame557.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame557.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame558.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame558.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame558.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame558.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame559.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame559.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame559.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame559.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame56.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame56.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame56.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame56.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame560.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame560.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame560.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame560.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame561.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame561.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame561.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame561.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame562.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame562.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame562.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame562.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame563.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame563.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame563.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame563.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame564.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame564.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame564.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame564.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame565.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame565.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame565.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame565.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame566.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame566.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame566.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame566.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame567.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame567.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame567.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame567.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame568.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame568.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame568.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame568.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame569.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame569.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame569.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame569.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame57.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame57.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame57.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame57.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame570.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame570.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame570.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame570.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame571.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame571.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame571.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame571.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame572.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame572.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame572.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame572.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame573.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame573.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame573.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame573.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame574.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame574.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame574.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame574.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame575.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame575.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame575.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame575.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame576.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame576.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame576.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame576.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame577.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame577.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame577.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame577.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame578.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame578.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame578.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame578.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame579.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame579.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame579.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame579.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame58.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame58.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame58.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame58.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame580.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame580.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame580.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame580.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame581.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame581.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame581.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame581.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame582.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame582.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame582.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame582.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame583.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame583.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame583.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame583.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame584.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame584.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame584.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame584.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame585.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame585.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame585.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame585.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame586.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame586.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame586.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame586.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame587.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame587.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame587.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame587.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame588.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame588.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame588.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame588.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame589.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame589.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame589.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame589.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame59.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame59.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame59.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame59.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame590.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame590.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame590.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame590.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame591.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame591.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame591.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame591.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame592.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame592.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame592.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame592.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame593.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame593.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame593.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame593.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame594.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame594.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame594.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame594.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame595.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame595.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame595.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame595.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame596.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame596.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame596.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame596.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame597.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame597.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame597.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame597.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame598.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame598.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame598.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame598.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame599.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame599.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame599.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame599.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame6.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame6.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame6.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame6.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame60.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame60.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame60.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame60.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame600.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame600.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame600.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame600.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame601.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame601.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame601.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame601.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame602.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame602.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame602.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame602.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame603.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame603.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame603.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame603.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame604.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame604.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame604.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame604.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame605.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame605.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame605.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame605.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame606.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame606.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame606.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame606.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame607.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame607.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame607.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame607.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame608.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame608.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame608.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame608.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame609.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame609.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame609.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame609.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame61.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame61.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame61.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame61.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame610.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame610.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame610.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame610.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame611.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame611.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame611.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame611.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame612.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame612.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame612.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame612.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame613.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame613.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame613.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame613.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame614.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame614.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame614.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame614.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame615.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame615.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame615.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame615.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame616.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame616.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame616.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame616.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame617.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame617.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame617.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame617.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame618.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame618.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame618.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame618.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame619.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame619.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame619.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame619.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame62.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame62.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame62.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame62.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame620.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame620.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame620.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame620.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame621.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame621.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame621.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame621.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame622.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame622.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame622.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame622.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame623.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame623.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame623.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame623.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame624.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame624.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame624.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame624.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame625.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame625.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame625.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame625.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame626.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame626.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame626.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame626.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame627.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame627.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame627.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame627.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame628.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame628.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame628.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame628.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame629.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame629.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame629.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame629.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame63.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame63.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame63.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame63.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame630.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame630.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame630.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame630.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame631.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame631.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame631.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame631.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame632.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame632.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame632.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame632.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame633.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame633.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame633.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame633.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame634.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame634.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame634.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame634.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame635.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame635.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame635.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame635.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame636.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame636.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame636.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame636.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame637.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame637.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame637.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame637.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame638.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame638.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame638.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame638.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame639.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame639.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame639.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame639.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame64.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame64.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame64.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame64.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame640.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame640.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame640.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame640.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame641.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame641.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame641.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame641.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame642.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame642.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame642.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame642.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame643.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame643.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame643.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame643.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame644.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame644.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame644.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame644.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame645.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame645.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame645.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame645.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame646.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame646.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame646.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame646.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame647.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame647.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame647.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame647.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame648.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame648.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame648.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame648.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame649.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame649.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame649.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame649.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame65.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame65.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame65.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame65.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame650.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame650.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame650.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame650.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame651.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame651.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame651.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame651.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame652.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame652.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame652.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame652.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame653.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame653.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame653.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame653.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame654.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame654.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame654.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame654.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame655.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame655.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame655.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame655.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame656.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame656.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame656.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame656.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame657.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame657.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame657.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame657.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame658.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame658.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame658.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame658.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame659.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame659.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame659.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame659.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame66.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame66.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame66.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame66.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame660.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame660.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame660.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame660.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame661.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame661.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame661.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame661.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame662.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame662.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame662.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame662.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame663.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame663.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame663.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame663.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame664.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame664.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame664.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame664.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame665.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame665.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame665.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame665.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame666.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame666.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame666.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame666.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame667.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame667.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame667.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame667.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame668.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame668.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame668.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame668.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame669.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame669.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame669.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame669.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame67.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame67.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame67.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame67.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame670.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame670.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame670.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame670.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame671.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame671.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame671.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame671.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame672.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame672.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame672.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame672.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame673.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame673.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame673.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame673.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame674.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame674.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame674.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame674.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame675.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame675.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame675.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame675.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame676.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame676.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame676.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame676.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame677.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame677.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame677.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame677.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame678.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame678.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame678.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame678.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame679.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame679.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame679.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame679.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame68.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame68.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame68.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame68.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame680.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame680.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame680.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame680.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame681.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame681.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame681.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame681.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame682.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame682.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame682.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame682.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame683.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame683.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame683.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame683.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame684.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame684.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame684.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame684.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame685.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame685.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame685.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame685.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame686.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame686.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame686.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame686.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame687.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame687.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame687.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame687.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame688.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame688.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame688.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame688.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame689.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame689.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame689.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame689.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame69.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame69.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame69.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame69.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame690.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame690.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame690.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame690.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame691.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame691.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame691.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame691.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame692.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame692.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame692.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame692.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame693.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame693.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame693.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame693.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame694.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame694.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame694.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame694.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame695.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame695.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame695.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame695.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame696.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame696.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame696.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame696.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame697.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame697.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame697.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame697.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame698.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame698.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame698.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame698.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame699.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame699.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame699.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame699.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame7.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame7.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame7.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame7.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame70.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame70.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame70.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame70.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame700.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame700.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame700.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame700.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame701.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame701.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame701.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame701.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame702.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame702.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame702.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame702.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame703.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame703.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame703.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame703.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame704.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame704.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame704.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame704.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame705.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame705.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame705.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame705.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame706.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame706.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame706.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame706.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame707.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame707.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame707.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame707.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame708.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame708.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame708.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame708.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame709.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame709.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame709.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame709.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame71.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame71.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame71.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame71.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame710.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame710.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame710.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame710.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame711.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame711.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame711.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame711.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame712.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame712.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame712.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame712.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame713.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame713.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame713.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame713.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame714.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame714.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame714.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame714.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame715.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame715.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame715.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame715.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame716.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame716.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame716.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame716.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame717.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame717.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame717.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame717.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame718.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame718.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame718.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame718.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame719.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame719.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame719.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame719.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame72.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame72.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame72.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame72.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame720.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame720.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame720.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame720.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame73.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame73.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame73.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame73.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame74.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame74.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame74.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame74.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame75.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame75.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame75.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame75.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame76.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame76.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame76.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame76.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame77.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame77.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame77.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame77.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame78.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame78.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame78.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame78.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame79.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame79.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame79.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame79.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame8.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame8.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame8.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame8.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame80.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame80.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame80.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame80.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame81.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame81.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame81.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame81.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame82.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame82.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame82.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame82.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame83.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame83.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame83.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame83.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame84.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame84.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame84.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame84.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame85.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame85.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame85.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame85.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame86.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame86.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame86.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame86.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame87.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame87.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame87.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame87.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame88.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame88.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame88.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame88.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame89.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame89.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame89.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame89.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame9.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame9.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame9.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame9.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame90.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame90.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame90.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame90.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame91.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame91.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame91.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame91.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame92.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame92.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame92.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame92.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame93.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame93.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame93.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame93.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame94.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame94.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame94.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame94.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame95.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame95.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame95.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame95.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame96.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame96.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame96.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame96.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame97.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame97.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame97.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame97.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame98.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame98.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame98.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame98.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/big/input/ski/frame99.jpg b/hpvm/test/pipeline/datasets/big/input/ski/frame99.jpg similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/big/input/ski/frame99.jpg rename to hpvm/test/pipeline/datasets/big/input/ski/frame99.jpg diff --git a/hpvm/test/parboil/datasets/pipeline/medium/input/DESCRIPTION b/hpvm/test/pipeline/datasets/medium/input/DESCRIPTION similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/medium/input/DESCRIPTION rename to hpvm/test/pipeline/datasets/medium/input/DESCRIPTION diff --git a/hpvm/test/parboil/datasets/pipeline/medium/input/matrix1.txt b/hpvm/test/pipeline/datasets/medium/input/matrix1.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/medium/input/matrix1.txt rename to hpvm/test/pipeline/datasets/medium/input/matrix1.txt diff --git a/hpvm/test/parboil/datasets/pipeline/medium/input/matrix1t.txt b/hpvm/test/pipeline/datasets/medium/input/matrix1t.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/medium/input/matrix1t.txt rename to hpvm/test/pipeline/datasets/medium/input/matrix1t.txt diff --git a/hpvm/test/parboil/datasets/pipeline/medium/input/matrix2.txt b/hpvm/test/pipeline/datasets/medium/input/matrix2.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/medium/input/matrix2.txt rename to hpvm/test/pipeline/datasets/medium/input/matrix2.txt diff --git a/hpvm/test/parboil/datasets/pipeline/medium/input/matrix2t.txt b/hpvm/test/pipeline/datasets/medium/input/matrix2t.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/medium/input/matrix2t.txt rename to hpvm/test/pipeline/datasets/medium/input/matrix2t.txt diff --git a/hpvm/test/parboil/datasets/pipeline/medium/output/matrix3.txt b/hpvm/test/pipeline/datasets/medium/output/matrix3.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/medium/output/matrix3.txt rename to hpvm/test/pipeline/datasets/medium/output/matrix3.txt diff --git a/hpvm/test/parboil/datasets/pipeline/small/input/DESCRIPTION b/hpvm/test/pipeline/datasets/small/input/DESCRIPTION similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/small/input/DESCRIPTION rename to hpvm/test/pipeline/datasets/small/input/DESCRIPTION diff --git a/hpvm/test/parboil/datasets/pipeline/small/input/edgetest_10.png b/hpvm/test/pipeline/datasets/small/input/edgetest_10.png similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/small/input/edgetest_10.png rename to hpvm/test/pipeline/datasets/small/input/edgetest_10.png diff --git a/hpvm/test/parboil/datasets/pipeline/small/input/matrix1.txt b/hpvm/test/pipeline/datasets/small/input/matrix1.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/small/input/matrix1.txt rename to hpvm/test/pipeline/datasets/small/input/matrix1.txt diff --git a/hpvm/test/parboil/datasets/pipeline/small/input/matrix2.txt b/hpvm/test/pipeline/datasets/small/input/matrix2.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/small/input/matrix2.txt rename to hpvm/test/pipeline/datasets/small/input/matrix2.txt diff --git a/hpvm/test/parboil/datasets/pipeline/small/input/matrix2t.txt b/hpvm/test/pipeline/datasets/small/input/matrix2t.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/small/input/matrix2t.txt rename to hpvm/test/pipeline/datasets/small/input/matrix2t.txt diff --git a/hpvm/test/parboil/datasets/pipeline/small/output/matrix3.txt b/hpvm/test/pipeline/datasets/small/output/matrix3.txt similarity index 100% rename from hpvm/test/parboil/datasets/pipeline/small/output/matrix3.txt rename to hpvm/test/pipeline/datasets/small/output/matrix3.txt diff --git a/hpvm/test/parboil/benchmarks/pipeline/gradient.visc.merged.experiments.notimer.ll b/hpvm/test/pipeline/gradient.visc.merged.experiments.notimer.ll similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/gradient.visc.merged.experiments.notimer.ll rename to hpvm/test/pipeline/gradient.visc.merged.experiments.notimer.ll diff --git a/hpvm/test/parboil/benchmarks/pipeline/laplacian.visc.merged.experiments.notimer.ll b/hpvm/test/pipeline/laplacian.visc.merged.experiments.notimer.ll similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/laplacian.visc.merged.experiments.notimer.ll rename to hpvm/test/pipeline/laplacian.visc.merged.experiments.notimer.ll diff --git a/hpvm/test/parboil/benchmarks/pipeline/run.sh b/hpvm/test/pipeline/run.sh similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/run.sh rename to hpvm/test/pipeline/run.sh diff --git a/hpvm/test/parboil/benchmarks/pipeline/runscript.sh b/hpvm/test/pipeline/runscript.sh similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/runscript.sh rename to hpvm/test/pipeline/runscript.sh diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc_parallel/Makefile b/hpvm/test/pipeline/src/Makefile similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/src/visc_parallel/Makefile rename to hpvm/test/pipeline/src/Makefile diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/Gradient/io.cc b/hpvm/test/pipeline/src/io.cc similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/src/Gradient/io.cc rename to hpvm/test/pipeline/src/io.cc diff --git a/hpvm/test/parboil/benchmarks/pipeline/src/visc_parallel/main.cc b/hpvm/test/pipeline/src/main.cc similarity index 97% rename from hpvm/test/parboil/benchmarks/pipeline/src/visc_parallel/main.cc rename to hpvm/test/pipeline/src/main.cc index b516f860a8c6b8317b11860127b8dc210c66b246..0d2582d41be135645155676b988e44538c472273 100644 --- a/hpvm/test/parboil/benchmarks/pipeline/src/visc_parallel/main.cc +++ b/hpvm/test/pipeline/src/main.cc @@ -11,7 +11,7 @@ */ #include "opencv2/opencv.hpp" -#include "opencv2/core/ocl.hpp" +#include "opencv2/ocl/ocl.hpp" #include <stdio.h> #include <math.h> #include <stdlib.h> @@ -20,7 +20,6 @@ #include <malloc.h> #include <iostream> #include <cassert> -#include <parboil.h> #include <visc.h> @@ -765,27 +764,21 @@ void getNextFrame(VideoCapture& VC, Mat& F) { int main (int argc, char *argv[]) { - struct pb_Parameters *params; - struct pb_TimerSet timers; + if (argc<2) { + fprintf(stderr, "Expecting input image filename\n"); + exit(-1); + } + char* inFile = argv[1]; + fprintf(stderr, "Running pipeline on %s\n", inFile); size_t I_sz; long block_x, grid_x; std::cout << "Using OpenCV" << CV_VERSION << "\n"; - /* Read command line. Expect 3 inputs: A, B and B^T - in column-major layout*/ - params = pb_ReadParameters(&argc, argv); - if ((params->inpFiles[0] == NULL) - || (params->inpFiles[1] != NULL)) - { - fprintf(stderr, "Expecting input image filename\n"); - exit(-1); - } - /* Read in data */ - std::cout << "Reading video file: " << params->inpFiles[0] << "\n"; - VideoCapture cap(params->inpFiles[0]); + std::cout << "Reading video file: " << inFile << "\n"; + VideoCapture cap(inFile); if(!cap.isOpened()) { std::cout << "Could not open video file" << "\n"; return -1; @@ -819,7 +812,6 @@ int main (int argc, char *argv[]) { // All these matrices need to have their data array contiguous in memory assert(src.isContinuous() && Is.isContinuous() && L.isContinuous() && S.isContinuous() && G.isContinuous() && E.isContinuous()); - pb_InitializeTimerSet(&timers); __visc__init(); // copy A to device memory @@ -862,7 +854,6 @@ int main (int argc, char *argv[]) { imshow(output_window, out); waitKey(0); - pb_SwitchToTimer( &timers, visc_TimerID_COMPUTATION ); struct InStruct* args = (struct InStruct*)malloc (sizeof(InStruct)); packData(args, (float*)src.data, I_sz, (float*)Is.data, I_sz, @@ -885,7 +876,7 @@ int main (int argc, char *argv[]) { std::cout << "Run: " << j << "\n"; void* DFG = __visc__launch(1, edgeDetection, (void*)args); - cap = VideoCapture(params->inpFiles[0]); + cap = VideoCapture(inFile); getNextFrame(cap, src); if(NUM_FRAMES >=2) { @@ -943,9 +934,6 @@ int main (int argc, char *argv[]) { } __visc__wait(DFG); } - pb_SwitchToTimer(&timers, pb_TimerID_NONE); - pb_PrintTimerSet(&timers); __visc__cleanup(); - pb_FreeParameters(params); return 0; } diff --git a/hpvm/test/pipeline/src/visc.h b/hpvm/test/pipeline/src/visc.h new file mode 100644 index 0000000000000000000000000000000000000000..3a05f49e299a0a63a2251db65762561c25ed3981 --- /dev/null +++ b/hpvm/test/pipeline/src/visc.h @@ -0,0 +1,110 @@ +/*************************************************************************** + *cr + *cr (C) Copyright 2010 The Board of Trustees of the + *cr University of Illinois + *cr All Rights Reserved + *cr + ***************************************************************************/ + +#ifndef DEVICE +#define DEVICE GPU_TARGET +#endif + +#include "../../../../../include/SupportVISC/VISCHint.h" + +#ifdef __cplusplus +extern "C" { +void __visc__hint(visc::Target); +//void __visc__wait(void*); +#else +void __visc__hint(enum Target); +//void __visc__wait(unsigned); +#endif + +#ifdef __cplusplus +//void* __visc__node(...); +//void* __visc__createNode(...); +//void* __visc__createNode1D(...); +//void* __visc__createNode2D(...); +//void* __visc__createNode3D(...); +//void __visc__return(...); +#endif + +void* __visc__createNodeND(unsigned,...); +void __visc__return(unsigned, ...); + +void __visc__attributes(unsigned, ...); +void __visc__init(); +void __visc__cleanup(); + +void __visc__bindIn(void*, unsigned, unsigned, unsigned); +void __visc__bindOut(void*, unsigned, unsigned, unsigned); +void* __visc__edge(void*, void*, unsigned, unsigned, unsigned, unsigned); +void __visc__push(void*, void*); +void* __visc__pop(void*); +void* __visc__launch(unsigned, ...); +void __visc__wait(void*); + +void* __visc__getNode(); +void* __visc__getParentNode(void*); +void __visc__barrier(); +void* __visc__malloc(long); +long __visc__getNodeInstanceID_x(void*); +long __visc__getNodeInstanceID_y(void*); +long __visc__getNodeInstanceID_z(void*); +long __visc__getNumNodeInstances_x(void*); +long __visc__getNumNodeInstances_y(void*); +long __visc__getNumNodeInstances_z(void*); + +// Atomic +// signed int +int __visc__atomic_cmpxchg(int*, int, int); +int __visc__atomic_add(int*, int); +int __visc__atomic_sub(int*, int); +int __visc__atomic_xchg(int*, int); +int __visc__atomic_inc(int*); +int __visc__atomic_dec(int*); +int __visc__atomic_min(int*, int); +int __visc__atomic_max(int*, int); +int __visc__atomic_umax(int*, int); +int __visc__atomic_umin(int*, int); +int __visc__atomic_and(int*, int); +int __visc__atomic_or(int*, int); +int __visc__atomic_xor(int*, int); + +// Special Func +float __visc__floor(float); +float __visc__rsqrt(float); +float __visc__sqrt(float); +float __visc__sin(float); +float __visc__cos(float); +// unsigned int +//unsigned __visc__atomic_cmpxchg(unsigned*, unsigned, unsigned); +//unsigned __visc__atomic_add(unsigned*, unsigned); +//unsigned __visc__atomic_sub(unsigned*, unsigned); +//unsigned __visc__atomic_xchg(unsigned*, unsigned); +//unsigned __visc__atomic_inc(unsigned*); +//unsigned __visc__atomic_dec(unsigned*); +//unsigned __visc__atomic_min(unsigned*, unsigned); +//unsigned __visc__atomic_max(unsigned*, unsigned); +//unsigned __visc__atomic_and(unsigned*, unsigned); +//unsigned __visc__atomic_or(unsigned*, unsigned); +//unsigned __visc__atomic_xor(unsigned*, unsigned); + + +#include <unistd.h> + +long get_global_id(int); +long get_group_id(int); +long get_local_id(int); +long get_local_size(int); + + +void llvm_visc_track_mem(void*, size_t); +void llvm_visc_untrack_mem(void*); +void llvm_visc_request_mem(void*, size_t); + +#ifdef __cplusplus +} +#endif + diff --git a/hpvm/test/parboil/benchmarks/pipeline/tools/compare-output b/hpvm/test/pipeline/tools/compare-output similarity index 100% rename from hpvm/test/parboil/benchmarks/pipeline/tools/compare-output rename to hpvm/test/pipeline/tools/compare-output