From 31a4cfae4cd55b37c3fbb316dde21b3c062340dd Mon Sep 17 00:00:00 2001 From: stansmith Date: Fri, 12 Dec 2008 00:42:33 +0000 Subject: [PATCH] [WinVerbs] added .rc files to perftests; fixed missing hostname of '-h hostname' parsing. git-svn-id: svn://openib.tc.cornell.edu/gen1@1783 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86 --- trunk/tests/perftest/rdma_bw/SOURCES | 1 + trunk/tests/perftest/rdma_bw/rdma_bw.c | 6 ++- trunk/tests/perftest/rdma_bw/rdma_bw.rc | 47 +++++++++++++++++++ trunk/tests/perftest/rdma_lat/SOURCES | 1 + trunk/tests/perftest/rdma_lat/rdma_lat.c | 9 +++- trunk/tests/perftest/rdma_lat/rdma_lat.rc | 47 +++++++++++++++++++ trunk/tests/perftest/read_bw/SOURCES | 3 +- trunk/tests/perftest/read_bw/read_bw.c | 6 ++- trunk/tests/perftest/read_bw/read_bw.rc | 47 +++++++++++++++++++ trunk/tests/perftest/read_lat/SOURCES | 1 + trunk/tests/perftest/read_lat/read_lat.c | 6 ++- trunk/tests/perftest/read_lat/read_lat.rc | 47 +++++++++++++++++++ trunk/tests/perftest/send_bw/SOURCES | 1 + trunk/tests/perftest/send_bw/send_bw.c | 6 ++- trunk/tests/perftest/send_bw/send_bw.rc | 47 +++++++++++++++++++ trunk/tests/perftest/send_lat/SOURCES | 1 + trunk/tests/perftest/send_lat/send_lat.c | 6 ++- trunk/tests/perftest/send_lat/send_lat.rc | 47 +++++++++++++++++++ trunk/tests/perftest/write_bw/SOURCES | 1 + trunk/tests/perftest/write_bw/write_bw.c | 6 ++- trunk/tests/perftest/write_bw/write_bw.rc | 47 +++++++++++++++++++ .../tests/perftest/write_bw_postlist/SOURCES | 3 +- .../write_bw_postlist/write_bw_postlist.c | 7 ++- .../write_bw_postlist/write_bw_postlist.rc | 47 +++++++++++++++++++ trunk/tests/perftest/write_lat/SOURCES | 1 + trunk/tests/perftest/write_lat/write_lat.c | 6 ++- trunk/tests/perftest/write_lat/write_lat.rc | 47 +++++++++++++++++++ 27 files changed, 475 insertions(+), 19 deletions(-) create mode 100644 trunk/tests/perftest/rdma_bw/rdma_bw.rc create mode 100644 trunk/tests/perftest/rdma_lat/rdma_lat.rc create mode 100644 trunk/tests/perftest/read_bw/read_bw.rc create mode 100644 trunk/tests/perftest/read_lat/read_lat.rc create mode 100644 trunk/tests/perftest/send_bw/send_bw.rc create mode 100644 trunk/tests/perftest/send_lat/send_lat.rc create mode 100644 trunk/tests/perftest/write_bw/write_bw.rc create mode 100644 trunk/tests/perftest/write_bw_postlist/write_bw_postlist.rc create mode 100644 trunk/tests/perftest/write_lat/write_lat.rc diff --git a/trunk/tests/perftest/rdma_bw/SOURCES b/trunk/tests/perftest/rdma_bw/SOURCES index 3cf87d1b..d8f5ffcb 100644 --- a/trunk/tests/perftest/rdma_bw/SOURCES +++ b/trunk/tests/perftest/rdma_bw/SOURCES @@ -11,6 +11,7 @@ USE_NATIVE_EH = 1 USE_IOSTREAM = 1 SOURCES = \ + rdma_bw.rc \ rdma_bw.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/rdma_bw/rdma_bw.c b/trunk/tests/perftest/rdma_bw/rdma_bw.c index f657b8b7..b43d1610 100644 --- a/trunk/tests/perftest/rdma_bw/rdma_bw.c +++ b/trunk/tests/perftest/rdma_bw/rdma_bw.c @@ -957,8 +957,10 @@ int __cdecl main(int argc, char *argv[]) break; case 'h': - data.servername = _strdup(optarg); - break; + if (optarg) { + data.servername = _strdup(optarg); + break; + } default: usage(argv[0]); diff --git a/trunk/tests/perftest/rdma_bw/rdma_bw.rc b/trunk/tests/perftest/rdma_bw/rdma_bw.rc new file mode 100644 index 00000000..70745e7a --- /dev/null +++ b/trunk/tests/perftest/rdma_bw/rdma_bw.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: write_lat.rc 474 2006-08-31 08:57:19Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef DBG +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA Bandwidth Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA Bandwidth Test " +#endif + +#define VER_INTERNALNAME_STR "ibv_rdma_bw.exe" +#define VER_ORIGINALFILENAME_STR "ibv_rdma_bw.exe" + +#include diff --git a/trunk/tests/perftest/rdma_lat/SOURCES b/trunk/tests/perftest/rdma_lat/SOURCES index 25da021c..1e09419b 100644 --- a/trunk/tests/perftest/rdma_lat/SOURCES +++ b/trunk/tests/perftest/rdma_lat/SOURCES @@ -11,6 +11,7 @@ USE_NATIVE_EH = 1 USE_IOSTREAM = 1 SOURCES = \ + rdma_lat.rc \ rdma_lat.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/rdma_lat/rdma_lat.c b/trunk/tests/perftest/rdma_lat/rdma_lat.c index 6ade2b7e..15c0ed03 100644 --- a/trunk/tests/perftest/rdma_lat/rdma_lat.c +++ b/trunk/tests/perftest/rdma_lat/rdma_lat.c @@ -1120,11 +1120,16 @@ int main(int argc, char *argv[]) } } - if (optind == argc - 1) + if (optind == argc - 1) { + if (!argv[optind]) { + usage(argv[0]); + return 6; + } data.servername = strdupa(argv[optind]); + } else if (optind < argc) { usage(argv[0]); - return 6; + return 7; } /* diff --git a/trunk/tests/perftest/rdma_lat/rdma_lat.rc b/trunk/tests/perftest/rdma_lat/rdma_lat.rc new file mode 100644 index 00000000..96b19557 --- /dev/null +++ b/trunk/tests/perftest/rdma_lat/rdma_lat.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: write_lat.rc 474 2006-08-31 08:57:19Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef DBG +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA Latency Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA Latency Test " +#endif + +#define VER_INTERNALNAME_STR "ibv_rdma_lat.exe" +#define VER_ORIGINALFILENAME_STR "ibv_rdma_lat.exe" + +#include diff --git a/trunk/tests/perftest/read_bw/SOURCES b/trunk/tests/perftest/read_bw/SOURCES index 49938d74..63e25c28 100644 --- a/trunk/tests/perftest/read_bw/SOURCES +++ b/trunk/tests/perftest/read_bw/SOURCES @@ -10,7 +10,8 @@ USE_STL = 1 USE_NATIVE_EH = 1 USE_IOSTREAM = 1 -SOURCES = \ +SOURCES = \ + read_bw.rc \ read_bw.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/read_bw/read_bw.c b/trunk/tests/perftest/read_bw/read_bw.c index c0479477..9ca73bd5 100644 --- a/trunk/tests/perftest/read_bw/read_bw.c +++ b/trunk/tests/perftest/read_bw/read_bw.c @@ -694,8 +694,10 @@ int __cdecl main(int argc, char *argv[]) break; case 'h': - user_param.servername = _strdup(optarg); - break; + if (optarg) { + user_param.servername = _strdup(optarg); + break; + } default: usage(argv[0]); diff --git a/trunk/tests/perftest/read_bw/read_bw.rc b/trunk/tests/perftest/read_bw/read_bw.rc new file mode 100644 index 00000000..2f131528 --- /dev/null +++ b/trunk/tests/perftest/read_bw/read_bw.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: write_bw.rc 1611 2006-08-20 14:48:55Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef DBG +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA read Bandwidth Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA read Bandwidth Test " +#endif + +#define VER_INTERNALNAME_STR "ibv_read_bw.exe" +#define VER_ORIGINALFILENAME_STR "ibv_read_bw.exe" + +#include diff --git a/trunk/tests/perftest/read_lat/SOURCES b/trunk/tests/perftest/read_lat/SOURCES index 584b6cd5..f87fc2bf 100644 --- a/trunk/tests/perftest/read_lat/SOURCES +++ b/trunk/tests/perftest/read_lat/SOURCES @@ -11,6 +11,7 @@ USE_NATIVE_EH = 1 USE_IOSTREAM = 1 SOURCES = \ + read_lat.rc \ read_lat.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/read_lat/read_lat.c b/trunk/tests/perftest/read_lat/read_lat.c index 936bac98..f99e13c5 100644 --- a/trunk/tests/perftest/read_lat/read_lat.c +++ b/trunk/tests/perftest/read_lat/read_lat.c @@ -838,8 +838,10 @@ int __cdecl main(int argc, char *argv[]) break; case 'h': - user_param.servername = _strdup(optarg); - break; + if (optarg) { + user_param.servername = _strdup(optarg); + break; + } default: usage(argv[0]); diff --git a/trunk/tests/perftest/read_lat/read_lat.rc b/trunk/tests/perftest/read_lat/read_lat.rc new file mode 100644 index 00000000..b35d8321 --- /dev/null +++ b/trunk/tests/perftest/read_lat/read_lat.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: write_bw.rc 1611 2006-08-20 14:48:55Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef _DEBUG_ +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA read Latency Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA read Latency Test " +#endif + +#define VER_INTERNALNAME_STR "ibv_read_lat.exe" +#define VER_ORIGINALFILENAME_STR "ibv_read_lat.exe" + +#include diff --git a/trunk/tests/perftest/send_bw/SOURCES b/trunk/tests/perftest/send_bw/SOURCES index 86bbd123..9c6eb61b 100644 --- a/trunk/tests/perftest/send_bw/SOURCES +++ b/trunk/tests/perftest/send_bw/SOURCES @@ -11,6 +11,7 @@ USE_NATIVE_EH = 1 USE_IOSTREAM = 1 SOURCES = \ + send_bw.rc \ send_bw.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/send_bw/send_bw.c b/trunk/tests/perftest/send_bw/send_bw.c index 82353cbf..c128b886 100644 --- a/trunk/tests/perftest/send_bw/send_bw.c +++ b/trunk/tests/perftest/send_bw/send_bw.c @@ -1059,8 +1059,10 @@ int __cdecl main(int argc, char *argv[]) break; case 'h': - user_param.servername = _strdup(optarg); - break; + if (optarg) { + user_param.servername = _strdup(optarg); + break; + } default: usage(argv[0]); diff --git a/trunk/tests/perftest/send_bw/send_bw.rc b/trunk/tests/perftest/send_bw/send_bw.rc new file mode 100644 index 00000000..192ed112 --- /dev/null +++ b/trunk/tests/perftest/send_bw/send_bw.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: send_bw.rc 474 2006-08-31 08:57:19Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef DBG +#define VER_FILEDESCRIPTION_STR "winverbs - Send/Recv Bandwidth Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - Send/Recv Bandwidth Test " +#endif + +#define VER_INTERNALNAME_STR "ibv_send_bw.exe" +#define VER_ORIGINALFILENAME_STR "ibv_send_bw.exe" + +#include diff --git a/trunk/tests/perftest/send_lat/SOURCES b/trunk/tests/perftest/send_lat/SOURCES index 2db1b9da..a3fc9857 100644 --- a/trunk/tests/perftest/send_lat/SOURCES +++ b/trunk/tests/perftest/send_lat/SOURCES @@ -11,6 +11,7 @@ USE_NATIVE_EH = 1 USE_IOSTREAM = 1 SOURCES = \ + send_lat.rc \ send_lat.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/send_lat/send_lat.c b/trunk/tests/perftest/send_lat/send_lat.c index a24f053c..9fb38999 100644 --- a/trunk/tests/perftest/send_lat/send_lat.c +++ b/trunk/tests/perftest/send_lat/send_lat.c @@ -1105,8 +1105,10 @@ int __cdecl main(int argc, char *argv[]) break; case 'h': - user_param.servername = _strdup(optarg); - break; + if (optarg) { + user_param.servername = _strdup(optarg); + break; + } default: usage(argv[0]); diff --git a/trunk/tests/perftest/send_lat/send_lat.rc b/trunk/tests/perftest/send_lat/send_lat.rc new file mode 100644 index 00000000..f70c64da --- /dev/null +++ b/trunk/tests/perftest/send_lat/send_lat.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: send_lat.rc 474 2006-08-31 08:57:19Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef DBG +#define VER_FILEDESCRIPTION_STR "winverbs - Send/Recv Latency Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - Send/Recv Latency Test " +#endif + +#define VER_INTERNALNAME_STR "ibv_send_lat.exe" +#define VER_ORIGINALFILENAME_STR "ibv_send_lat.exe" + +#include diff --git a/trunk/tests/perftest/write_bw/SOURCES b/trunk/tests/perftest/write_bw/SOURCES index d674026c..c0e15cda 100644 --- a/trunk/tests/perftest/write_bw/SOURCES +++ b/trunk/tests/perftest/write_bw/SOURCES @@ -11,6 +11,7 @@ USE_NATIVE_EH = 1 USE_IOSTREAM = 1 SOURCES = \ + write_bw.rc \ write_bw.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/write_bw/write_bw.c b/trunk/tests/perftest/write_bw/write_bw.c index 9ed3e286..eb9a5a28 100644 --- a/trunk/tests/perftest/write_bw/write_bw.c +++ b/trunk/tests/perftest/write_bw/write_bw.c @@ -787,8 +787,10 @@ int __cdecl main(int argc, char *argv[]) break; case 'h': - user_param.servername = _strdup(optarg); - break; + if (optarg) { + user_param.servername = _strdup(optarg); + break; + } default: usage(argv[0]); diff --git a/trunk/tests/perftest/write_bw/write_bw.rc b/trunk/tests/perftest/write_bw/write_bw.rc new file mode 100644 index 00000000..fc997c6a --- /dev/null +++ b/trunk/tests/perftest/write_bw/write_bw.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: write_bw.rc 474 2006-08-31 08:57:19Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef DBG +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA write Bandwidth Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA write Bandwidth Test " +#endif + +#define VER_INTERNALNAME_STR "ibv_write_bw.exe" +#define VER_ORIGINALFILENAME_STR "ibv_write_bw.exe" + +#include diff --git a/trunk/tests/perftest/write_bw_postlist/SOURCES b/trunk/tests/perftest/write_bw_postlist/SOURCES index 61fcbc93..c31e7564 100644 --- a/trunk/tests/perftest/write_bw_postlist/SOURCES +++ b/trunk/tests/perftest/write_bw_postlist/SOURCES @@ -10,7 +10,8 @@ USE_STL = 1 USE_NATIVE_EH = 1 USE_IOSTREAM = 1 -SOURCES = \ +SOURCES = \ + write_bw_postlist.rc \ write_bw_postlist.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/write_bw_postlist/write_bw_postlist.c b/trunk/tests/perftest/write_bw_postlist/write_bw_postlist.c index 87903c0a..d80a7a5b 100644 --- a/trunk/tests/perftest/write_bw_postlist/write_bw_postlist.c +++ b/trunk/tests/perftest/write_bw_postlist/write_bw_postlist.c @@ -797,8 +797,13 @@ int main(int argc, char *argv[]) } } - if (optind == argc - 1) + if (optind == argc - 1) { + if (!argv[optind]) { + usage(argv[0]); + return 1; + } user_param.servername = strdupa(argv[optind]); + } else if (optind < argc) { usage(argv[0]); return 1; diff --git a/trunk/tests/perftest/write_bw_postlist/write_bw_postlist.rc b/trunk/tests/perftest/write_bw_postlist/write_bw_postlist.rc new file mode 100644 index 00000000..0f144d37 --- /dev/null +++ b/trunk/tests/perftest/write_bw_postlist/write_bw_postlist.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: write_lat.rc 474 2006-08-31 08:57:19Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef DBG +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA_Write Post List BW Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA_Write Post List BW Test" +#endif + +#define VER_INTERNALNAME_STR "ibv_write_lat.exe" +#define VER_ORIGINALFILENAME_STR "ibv_write_lat.exe" + +#include diff --git a/trunk/tests/perftest/write_lat/SOURCES b/trunk/tests/perftest/write_lat/SOURCES index 2da200e9..316a625a 100644 --- a/trunk/tests/perftest/write_lat/SOURCES +++ b/trunk/tests/perftest/write_lat/SOURCES @@ -11,6 +11,7 @@ USE_NATIVE_EH = 1 USE_IOSTREAM = 1 SOURCES = \ + write_lat.rc \ write_lat.c INCLUDES = ..\..\..\ulp\libibverbs\include;..\..\..\inc;..\..\..\inc\user; diff --git a/trunk/tests/perftest/write_lat/write_lat.c b/trunk/tests/perftest/write_lat/write_lat.c index 3e04e831..95748aa6 100644 --- a/trunk/tests/perftest/write_lat/write_lat.c +++ b/trunk/tests/perftest/write_lat/write_lat.c @@ -863,8 +863,10 @@ int __cdecl main(int argc, char *argv[]) break; case 'h': - user_param.servername = _strdup(optarg); - break; + if (optarg) { + user_param.servername = _strdup(optarg); + break; + } default: usage(argv[0]); diff --git a/trunk/tests/perftest/write_lat/write_lat.rc b/trunk/tests/perftest/write_lat/write_lat.rc new file mode 100644 index 00000000..4d028fd0 --- /dev/null +++ b/trunk/tests/perftest/write_lat/write_lat.rc @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2005 Mellanox Technologies. All rights reserved. + * + * This software is available to you under the OpenIB.org BSD license + * below: + * + * Redistribution and use in source and binary forms, with or + * without modification, are permitted provided that the following + * conditions are met: + * + * - Redistributions of source code must retain the above + * copyright notice, this list of conditions and the following + * disclaimer. + * + * - Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * $Id: write_lat.rc 474 2006-08-31 08:57:19Z sleybo $ + */ + + +#include + +#define VER_FILETYPE VFT_APP +#define VER_FILESUBTYPE VFT2_UNKNOWN + +#ifdef DBG +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA write Latency Test (Debug)" +#else +#define VER_FILEDESCRIPTION_STR "winverbs - RDMA write Latency Test " +#endif + +#define VER_INTERNALNAME_STR "ibv_write_lat.exe" +#define VER_ORIGINALFILENAME_STR "ibv_write_lat.exe" + +#include -- 2.46.0