[parsec-users] Logical error in Blackscholes benchmark

Mattson, Timothy G timothy.g.mattson at intel.com
Sat Nov 29 12:11:20 EST 2008


I will check with the author of the Blackscholes program and get  back to you.  Being the holiday season, it may take a few days to get to the bottom on this.

--Tim

________________________________
From: parsec-users-bounces at lists.cs.princeton.edu [mailto:parsec-users-bounces at lists.cs.princeton.edu] On Behalf Of Nirav Shah
Sent: Saturday, November 29, 2008 9:06 AM
To: parsec-users at lists.cs.princeton.edu
Subject: [parsec-users] Logical error in Blackscholes benchmark

Hi,

I am working on Blackscholes benchmark and I have found a potential logical error in the code.

Following is the snippet of code from line 193 to 200 in blackscholes.c

193     xD1 = xD1 + xLogTerm;
194     xD2 = xD2 + xLogTerm;
195
196     xDen = xVolatility * xSqrtTime;
197     xD1 = xD1 / xDen;
198
199     xD2 = xD1 -  xDen;
200

It seems that the value of xD2 is overwritten without being used in line 199. It is assigned in line 194 and assigned again in line 199. Kindly clarify whether this is an anomaly or desired.

Regards,
Nirav Shah.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cs.princeton.edu/pipermail/parsec-users/attachments/20081129/2a41f745/attachment.htm>


More information about the parsec-users mailing list