Skip to contentSkip to conversation

Recent changes (master)

PATCH Jens Axboe 1 participant 1 message Jul 27, 2020 Kbuild

lore
Share & tools
lore

Jens Axboe

author
#0 lore raw

The following changes since commit e235e74dfd0627b17690194f957da509b8ace808:

Merge branch 'test-cleanup' of https://github.com/vincentkfu/fio (2020-07-25 13:55:16 -0600)

are available in the Git repository at:

git://git.kernel.dk/fio.git master

for you to fetch changes up to 11b280c158db01744effde3863bfe9c65f7af090:

t/jobs/t001[1-2].fio: run for 10 seconds instead of 3 (2020-07-26 22:19:47 -0600)

----------------------------------------------------------------
Jens Axboe (4):
Merge branch 'travis_cleanup' of https://github.com/sitsofe/fio
Merge branch 'enable_or_exit' of https://github.com/sitsofe/fio
Merge branch 'fix_travis_libiscsi' of https://github.com/sitsofe/fio
t/jobs/t001[1-2].fio: run for 10 seconds instead of 3

Sitsofe Wheeler (12):
travis: simplify yml file
travis: improve installation dependencies
configure: check for Debian/Ubuntu tcmalloc_minimal
travis: use install section instead of before_install section
travis: add dependency for cuda ioengine
travis: enable libiscsi and cuda ioengines
travis: make CI install script bail out on first error
memory: fix incorrect pointer comparison when freeing cuda memory
Makefile: fix incorrectly set libiscsi cflags
configure: fail when explicit enabling doesn't succeed
travis: remove unneeded dependency
travis: fix x86 libiscsi detection

 .travis.yml               | 18 ++++----------
 Makefile                  |  2 +-
 ci/travis-build.sh        | 23 ++++++++++++++----
 ci/travis-install.sh      | 30 ++++++++++++++++-------
 configure                 | 62 +++++++++++++++++++++++++++++------------------
 memory.c                  |  2 +-
 t/jobs/t0011-5d2788d5.fio |  2 +-
 t/jobs/t0012.fio          |  2 +-
 8 files changed, 87 insertions(+), 54 deletions(-)

---

Diff of recent changes:

.travis.yml +5 -13
index b64f0a95..e35aff39 100644
@@ -9,36 +9,28 @@ arch:
   - amd64
   - arm64
 env:
-  matrix:
-    - BUILD_ARCH="x86"
-    - BUILD_ARCH="x86_64"
   global:
     - MAKEFLAGS="-j 2"
 matrix:
   include:
+    - os: linux
+      compiler: gcc
+      arch: amd64
+      env: BUILD_ARCH="x86" # Only do the gcc x86 build to reduce clutter
     # Default xcode image
     - os: osx
       compiler: clang # Workaround travis setting CC=["clang", "gcc"]
-      env: BUILD_ARCH="x86_64"
       arch: amd64
     # Latest xcode image (needs periodic updating)
     - os: osx
       compiler: clang
       osx_image: xcode11.2
-      env: BUILD_ARCH="x86_64"
       arch: amd64
   exclude:
     - os: osx
       compiler: gcc
-    - os: linux
-      compiler: clang
-      arch: amd64
-      env: BUILD_ARCH="x86" # Only do the gcc x86 build to reduce clutter
-    - os: linux
-      env: BUILD_ARCH="x86"
-      arch: arm64
 
-before_install:
+install:
   - ci/travis-install.sh
 
 script:
Makefile +1 -1
index f374ac84..8e1ebc90 100644
@@ -62,7 +62,7 @@ endif
 ifdef CONFIG_LIBISCSI
   iscsi_SRCS = engines/libiscsi.c
   iscsi_LIBS = $(LIBISCSI_LIBS)
-  iscsi_CFLAGS = $(LIBISCSI_LIBS)
+  iscsi_CFLAGS = $(LIBISCSI_CFLAGS)
   ENGINES += iscsi
 endif
 
ci/travis-build.sh +18 -5
index 06012e89..231417e2 100755
@@ -1,16 +1,29 @@
 #!/bin/bash
 
+CI_TARGET_ARCH="${BUILD_ARCH:-$TRAVIS_CPU_ARCH}"
 EXTRA_CFLAGS="-Werror"
 PYTHONUNBUFFERED=TRUE
+CONFIGURE_FLAGS=()
 
-if [[ "$BUILD_ARCH" == "x86" ]]; then
-    EXTRA_CFLAGS="${EXTRA_CFLAGS} -m32"
-fi
+case "$TRAVIS_OS_NAME" in
+    "linux")
+        CONFIGURE_FLAGS+=(--enable-libiscsi)
+        case "$CI_TARGET_ARCH" in
+            "x86")
+                EXTRA_CFLAGS="${EXTRA_CFLAGS} -m32"
+                ;;
+            "amd64")
+                CONFIGURE_FLAGS+=(--enable-cuda)
+                ;;
+        esac
+    ;;
+esac
+CONFIGURE_FLAGS+=(--extra-cflags="${EXTRA_CFLAGS}")
 
-./configure --extra-cflags="${EXTRA_CFLAGS}" &&
+./configure "${CONFIGURE_FLAGS[@]}" &&
     make &&
     make test &&
-    if [[ "$TRAVIS_CPU_ARCH" == "arm64" ]]; then
+    if [[ "$CI_TARGET_ARCH" == "arm64" ]]; then
 	sudo python3 t/run-fio-tests.py --skip 6 1007 1008 --debug -p 1010:"--skip 15 16 17 18 19 20"
     else
 	sudo python3 t/run-fio-tests.py --skip 6 1007 1008 --debug
ci/travis-install.sh +21 -9
index 232ab6b1..b6895e82 100755
@@ -1,13 +1,15 @@
 #!/bin/bash
+set -e
 
+CI_TARGET_ARCH="${BUILD_ARCH:-$TRAVIS_CPU_ARCH}"
 case "$TRAVIS_OS_NAME" in
     "linux")
 	# Architecture-dependent packages.
 	pkgs=(
 	    libaio-dev
-	    libcunit1
 	    libcunit1-dev
-	    libgoogle-perftools4
+	    libfl-dev
+	    libgoogle-perftools-dev
 	    libibverbs-dev
 	    libiscsi-dev
 	    libnuma-dev
@@ -15,15 +17,26 @@ case "$TRAVIS_OS_NAME" in
 	    librdmacm-dev
 	    libz-dev
 	)
-	if [[ "$BUILD_ARCH" == "x86" ]]; then
-	    pkgs=("${pkgs[@]/%/:i386}")
-	    pkgs+=(gcc-multilib)
-	else
-	    pkgs+=(glusterfs-common)
+	case "$CI_TARGET_ARCH" in
+	    "x86")
+		pkgs=("${pkgs[@]/%/:i386}")
+		pkgs+=(
+		    gcc-multilib
+		    pkg-config:i386
+	        )
+		;;
+	    "amd64")
+		pkgs+=(nvidia-cuda-dev)
+		;;
+	esac
+	if [[ $CI_TARGET_ARCH != "x86" ]]; then
+		pkgs+=(glusterfs-common)
 	fi
 	# Architecture-independent packages and packages for which we don't
 	# care about the architecture.
 	pkgs+=(
+	    bison
+	    flex
 	    python3
 	    python3-scipy
 	    python3-six
@@ -34,8 +47,7 @@ case "$TRAVIS_OS_NAME" in
     "osx")
 	brew update >/dev/null 2>&1
 	brew install cunit
-	pip3 install scipy
-	pip3 install six
+	pip3 install scipy six
 	;;
 esac
 
configure +39 -23

127 lines not on this page · raw message

memory.c +1 -1
index 5f0225f7..6cf73333 100644
@@ -274,7 +274,7 @@ static int alloc_mem_cudamalloc(struct thread_data *td, size_t total_mem)
 static void free_mem_cudamalloc(struct thread_data *td)
 {
 #ifdef CONFIG_CUDA
-	if (td->dev_mem_ptr != NULL)
+	if (td->dev_mem_ptr)
 		cuMemFree(td->dev_mem_ptr);
 
 	if (cuCtxDestroy(td->cu_ctx) != CUDA_SUCCESS)
t/jobs/t0011-5d2788d5.fio +1 -1
index 50daf612..f90cee90 100644
@@ -7,7 +7,7 @@
 bs=4k
 ioengine=null
 size=100g
-runtime=3
+runtime=10
 flow_id=1
 
 [flow1]
t/jobs/t0012.fio +1 -1
index 985eb16b..03fea627 100644
@@ -8,7 +8,7 @@
 bs=4k
 ioengine=null
 size=100g
-runtime=3
+runtime=10
 flow_id=1
 gtod_cpu=1