472,353 Members | 1,505 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,353 software developers and data experts.

VC++ 2005 beta1 fails with pthreads benchmark tests

um
When the POSIX pthreads library for w32 release 2-2-0
(http://sources.redhat.com/pthreads-win32/) is compiled with VC++6
then it compiles and passes all the benchmark tests in the subdirectory "tests".
Also, VC++ 2005 beta 1 compiles the tests fine, but here the following
tests fail in execution:

# semaphore1.pass \
# condvar2.pass \
# condvar2_1.pass \
# mutex8.pass \
# mutex8n.pass \
# mutex8e.pass \
# mutex8r.pass \
# condvar3.pass \
# condvar3_1.pass \
# condvar3_2.pass \
# condvar3_3.pass \
# condvar4.pass \
# condvar5.pass \
# condvar6.pass \
# condvar7.pass \
# condvar8.pass \
# condvar9.pass \
# rwlock7.pass \
# rwlock8.pass \
# rwlock2_t.pass \
# rwlock3_t.pass \
# rwlock4_t.pass \
# rwlock5_t.pass \
# rwlock6_t.pass \
# rwlock6_t2.pass \
# spin4.pass \

Why are there such differences in execution of the generated code
between VC++6 and VC++2005 ? Is this due to bugs in the beta1,
or is this the result of general differences between the two products?
Are there any compiler/linker switches for backwards "compatibility" to VC++6?
Nov 17 '05 #1
2 2167
um wrote:
When the POSIX pthreads library for w32 release 2-2-0
(http://sources.redhat.com/pthreads-win32/) is compiled with VC++6
then it compiles and passes all the benchmark tests in the
subdirectory "tests". Also, VC++ 2005 beta 1 compiles the tests fine,
but here the following
tests fail in execution:

# semaphore1.pass \
# condvar2.pass \
# condvar2_1.pass \
# mutex8.pass \
# mutex8n.pass \
# mutex8e.pass \
# mutex8r.pass \
# condvar3.pass \
# condvar3_1.pass \
# condvar3_2.pass \
# condvar3_3.pass \
# condvar4.pass \
# condvar5.pass \
# condvar6.pass \
# condvar7.pass \
# condvar8.pass \
# condvar9.pass \
# rwlock7.pass \
# rwlock8.pass \
# rwlock2_t.pass \
# rwlock3_t.pass \
# rwlock4_t.pass \
# rwlock5_t.pass \
# rwlock6_t.pass \
# rwlock6_t2.pass \
# spin4.pass \

Why are there such differences in execution of the generated code
between VC++6 and VC++2005 ? Is this due to bugs in the beta1,
or is this the result of general differences between the two products?
Are there any compiler/linker switches for backwards "compatibility"
to VC++6?


You're going to need to post a lot more details to get a satisfying answer,
unless a pthreads-win32 expert happens to read this newsgroup.

I'd suggest examining a single failure in depth with the goal of producing a
simple small program that behaves differently on VC6 versus VC8 beta 1 (also
note that beta 2 was released lasts Friday).

-cd
Nov 17 '05 #2
um
"Carl Daniel [VC++ MVP]" wrote
um wrote:
When the POSIX pthreads library for w32 release 2-2-0
(http://sources.redhat.com/pthreads-win32/) is compiled with VC++6
then it compiles and passes all the benchmark tests in the
subdirectory "tests". Also, VC++ 2005 beta 1 compiles the tests fine,
but here the following
tests fail in execution:

# semaphore1.pass \
# condvar2.pass \
# condvar2_1.pass \
# mutex8.pass \
# mutex8n.pass \
# mutex8e.pass \
# mutex8r.pass \
# condvar3.pass \
# condvar3_1.pass \
# condvar3_2.pass \
# condvar3_3.pass \
# condvar4.pass \
# condvar5.pass \
# condvar6.pass \
# condvar7.pass \
# condvar8.pass \
# condvar9.pass \
# rwlock7.pass \
# rwlock8.pass \
# rwlock2_t.pass \
# rwlock3_t.pass \
# rwlock4_t.pass \
# rwlock5_t.pass \
# rwlock6_t.pass \
# rwlock6_t2.pass \
# spin4.pass \

Why are there such differences in execution of the generated code
between VC++6 and VC++2005 ? Is this due to bugs in the beta1,
or is this the result of general differences between the two products?
Are there any compiler/linker switches for backwards "compatibility"
to VC++6?


You're going to need to post a lot more details to get a satisfying answer,
unless a pthreads-win32 expert happens to read this newsgroup.

I'd suggest examining a single failure in depth with the goal of producing a
simple small program that behaves differently on VC6 versus VC8 beta 1 (also
note that beta 2 was released lasts Friday).


Here is the result of the compile and test execution process for VC++2005.
I have appended also the code location of the first failed test (semaphore1.c).
As said, VC++6 compiles and passes all tests, whereas VC++2005 fails
with many of the tests.

---
Setting environment for using Microsoft Visual Studio 2005 tools.
(If you have another version of Visual Studio or Visual C++ installed and wish
to use its tools from the command line, run vsvars32.bat for that version.)

E:\>cd F:\FILES\Thread_Programming\pthreads\MyTests\tests

E:\>f:

F:\FILES\Thread_Programming\pthreads\MyTests\tests >nmake clean VC

Microsoft (R) Program Maintenance Utility Version 8.00.40607.16
Copyright (C) Microsoft Corporation. All rights reserved.

erase *.dll
erase *.lib
erase pthread.h
erase semaphore.h
erase sched.h
erase *.e
Could Not Find F:\FILES\Thread_Programming\pthreads\MyTests\tests \*.e
erase *.i
Could Not Find F:\FILES\Thread_Programming\pthreads\MyTests\tests \*.i
erase *.obj
erase *.pdb
erase *.o
Could Not Find F:\FILES\Thread_Programming\pthreads\MyTests\tests \*.o
erase *.asm
Could Not Find F:\FILES\Thread_Programming\pthreads\MyTests\tests \*.asm
erase *.exe
erase *.pass
erase *.bench
Could Not Find F:\FILES\Thread_Programming\pthreads\MyTests\tests \*.bench
erase *.log
Could Not Find F:\FILES\Thread_Programming\pthreads\MyTests\tests \*.log

Microsoft (R) Program Maintenance Utility Version 8.00.40607.16
Copyright (C) Microsoft Corporation. All rights reserved.

Copying pthreadVC2.lib
1 file(s) copied.
Copying pthreadVC2.dll
1 file(s) copied.
Copying pthread.h
1 file(s) copied.
Copying semaphore.h
1 file(s) copied.
Copying sched.h
1 file(s) copied.
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. sizes.c /Fesizes.exe
/link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be
removed in a future release
sizes.c
NMAKE : warning U4004: too many rules for target 'sizes.pass'
.... Running VC2 test: sizes.exe
Sizes of pthreads-win32 structs
-------------------------------
pthread_t 8
ptw32_thread_t 136
pthread_attr_t_ 28
sem_t_ 12
pthread_mutex_t_ 24
pthread_mutexattr_t_ 8
pthread_spinlock_t_ 8
pthread_barrier_t_ 24
pthread_barrierattr_t_ 4
pthread_key_t_ 16
pthread_cond_t_ 32
pthread_condattr_t_ 4
pthread_rwlock_t_ 28
pthread_rwlockattr_t_ 4
pthread_once_t_ 16
ptw32_cleanup_t 12
sched_param 4
-------------------------------
....... Passed
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. loadfree.c
/Feloadfree.exe /link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be
removed in a future release
loadfree.c
1 file(s) copied.
1 file(s) copied.
.... Running VC test: loadfree.exe
....... Passed
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. self1.c /Feself1.exe
/link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be
removed in a future release
self1.c
.... Running VC test: self1.exe
....... Passed
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. mutex5.c /Femutex5.exe
/link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be
removed in a future release
mutex5.c
.... Running VC test: mutex5.exe
....... Passed
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. mutex1.c /Femutex1.exe
/link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be
removed in a future release
mutex1.c
.... Running VC test: mutex1.exe
....... Passed
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. mutex1n.c
/Femutex1n.exe /link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be rem
oved in a future release
mutex1n.c
.... Running VC test: mutex1n.exe
....... Passed
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. mutex1e.c
/Femutex1e.exe /link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be
removed in a future release
mutex1e.c
.... Running VC test: mutex1e.exe
....... Passed
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. mutex1r.c
/Femutex1r.exe /link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be
removed in a future release
mutex1r.c
.... Running VC test: mutex1r.exe
....... Passed
cl /D__CLEANUP_C /O2 /Ob0 /W3 /WX /MD /nologo /Yd /Zi -I. semaphore1.c
/Fesemaphore1.exe /link /INCREMENTAL:NO pthreadVC2.lib ws2_32.lib
cl : Command line warning D9035 : option 'Yd' has been deprecated and will be
removed in a future release
semaphore1.c
.... Running VC test: semaphore1.exe
thread: sem_trywait 1: expected error: No error
Assertion failed: (errno == EAGAIN), file semaphore1.c, line 89
NMAKE : fatal error U1077: '.\semaphore1.exe' : return code '0x1'
Stop.
NMAKE : fatal error U1077: 'nmake' : return code '0x2'
Stop.
--

The first error happens with semaphore1.exe (semaphore1.c line 89):

void *
thr(void * arg)
{
sem_t s;
int result;

assert(sem_init(&s, PTHREAD_PROCESS_PRIVATE, 0) == 0);

assert((result = sem_trywait(&s)) == -1);

if ( result == -1 )
{
perror("thread: sem_trywait 1: expected error"); // No error
assert(errno == EAGAIN);
It is the last assert which fails in the first of the failing test programs.
Nov 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
by: mysteron | last post by:
i have vc 2003 installed on my dev machine and was wondering if I can install 2005 beta 2 on the same machine and have both working perfectly and...
6
by: nick | last post by:
i haven't learnt c++ before ,if i want to learn vc++,do i need to buy a c++ book to learn before i learn vc++? or some vc++ books are suitable to...
2
by: Jack | last post by:
hi all I would find a parallel sorting algorithms written with pthread programs, as a benchmark to run. Any pointing will be of help ...
1
by: Joannes Vermorel | last post by:
Hi, I just give a try at VS2005 Beta1 (for C#). I have try to import a simple C# project (MathNet.Numerics, http://nmath.sourceforge.net). The...
7
by: Rachete | last post by:
Can any one give me a couple of good reasons (advantages) to use VC++ 2005 versus using VC# 2005 (especially for a middle tier component...
5
by: Adriano Coser | last post by:
Hello. I've just finished the compilation of my application with VC 2005 Beta 2 (Express edition) and I'm getting the following initialization...
42
by: Paul | last post by:
Anyone know where I can find some good resources to help us choose between SQL and Oracle ( Progress Openedge as well ) . Any comments on what you...
36
by: Alex Martelli | last post by:
So, I thought I'd tool up to let me build and test Python extensions on Windows (as well as Mac and Linux) -- I'm trying out Parallels Workstation...
7
by: Norman Diamond | last post by:
A project depends on VC runtime from Visual Studio 2005 SP1, and DotNet Framework 2. Options are set in the setup project properties, so if these...
1
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific...
0
by: Matthew3360 | last post by:
Hi, I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web...
0
by: Carina712 | last post by:
Setting background colors for Excel documents can help to improve the visual appeal of the document and make it easier to read and understand....
0
BLUEPANDA
by: BLUEPANDA | last post by:
At BluePanda Dev, we're passionate about building high-quality software and sharing our knowledge with the community. That's why we've created a SaaS...
0
by: Rahul1995seven | last post by:
Introduction: In the realm of programming languages, Python has emerged as a powerhouse. With its simplicity, versatility, and robustness, Python...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.