Skip to content

Commit

Permalink
ci: Stabilize L0_pinned_memory flakiness (#7929)
Browse files Browse the repository at this point in the history
  • Loading branch information
rmccorm4 authored Jan 13, 2025
1 parent 6100d7f commit 2af0c22
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions qa/L0_pinned_memory/test.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash
# Copyright (c) 2019-2021, NVIDIA CORPORATION. All rights reserved.
# Copyright (c) 2019-2025, NVIDIA CORPORATION. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
Expand Down Expand Up @@ -38,6 +38,9 @@ if [ ! -z "$TEST_REPO_ARCH" ]; then
REPO_VERSION=${REPO_VERSION}_${TEST_REPO_ARCH}
fi

# Use "--request-count" throughout the test to PA stability criteria and
# reduce flaky failures from PA unstable measurements.
REQUEST_COUNT=10
CLIENT=../clients/perf_client
# Only use libtorch as it accepts GPU I/O and it can handle variable shape
BACKENDS=${BACKENDS:="libtorch"}
Expand Down Expand Up @@ -91,7 +94,7 @@ for BACKEND in $BACKENDS; do

# Sanity check that the server allocates pinned memory for large size
set +e
$CLIENT -m${ENSEMBLE_NAME} --shape INPUT0:16777216
$CLIENT -m${ENSEMBLE_NAME} --shape INPUT0:16777216 --request-count ${REQUEST_COUNT}
if (( $? != 0 )); then
RET=1
fi
Expand Down Expand Up @@ -128,6 +131,7 @@ for BACKEND in $BACKENDS; do
for TENSOR_SIZE in 16384 1048576 2097152 4194304 8388608 16777216; do
$CLIENT -i grpc -u localhost:8001 -m${ENSEMBLE_NAME} \
--shape INPUT0:${TENSOR_SIZE} \
--request-count ${REQUEST_COUNT} \
>> ${BACKEND}.${TENSOR_SIZE}.pinned.log 2>&1
if (( $? != 0 )); then
RET=1
Expand All @@ -150,7 +154,7 @@ for BACKEND in $BACKENDS; do

# Sanity check that the server allocates non-pinned memory
set +e
$CLIENT -m${ENSEMBLE_NAME} --shape INPUT0:1
$CLIENT -m${ENSEMBLE_NAME} --shape INPUT0:1 --request-count ${REQUEST_COUNT}
if (( $? != 0 )); then
RET=1
fi
Expand Down Expand Up @@ -180,6 +184,7 @@ for BACKEND in $BACKENDS; do
for TENSOR_SIZE in 16384 1048576 2097152 4194304 8388608 16777216; do
$CLIENT -i grpc -u localhost:8001 -m${ENSEMBLE_NAME} \
--shape INPUT0:${TENSOR_SIZE} \
--request-count ${REQUEST_COUNT} \
>> ${BACKEND}.${TENSOR_SIZE}.nonpinned.log 2>&1
if (( $? != 0 )); then
RET=1
Expand Down

0 comments on commit 2af0c22

Please sign in to comment.