[parsec-users] multithread vs single thread

Mahmood Naderan nt_mahmood at yahoo.com
Tue Apr 19 11:27:49 EDT 2011


>Perhaps the 7.5B cycles includes the cycles outside the ROI (region of
>interest).
 
No. Please find the attached log.

What I want to know is: How the program elapsed cycles changes when the number 
of threads are increased?
I mean, Do we expect a reduction in cycles count? What I observed, is that with 
a given input size (64k in blackscholes), running the benchmark with 4 
threads has a less cycle counts (850M total cycles) compare to single thread 
(7.5B cycles).

How one can exaplain that reduction?
Thanks, 
// Naderan *Mahmood;



----- Original Message ----
From: Jim Dempsey <jim at quickthreadprogramming.com>
To: PARSEC Users <parsec-users at lists.cs.princeton.edu>
Sent: Tue, April 19, 2011 6:59:17 PM
Subject: Re: [parsec-users] multithread vs single thread

Perhaps the 7.5B cycles includes the cycles outside the ROI (region of
interest).

Try using RDTSC to be called from each thread to read the simulated clock
counter. Place this at the start and end of the do work function that all
threads pass through. Each thread can compute there own number of clock
ticks, then issue an interlocked add to produce a summation. This will give
you the simulated clock ticks but not the instruction counts. If you want
the instruction counts, then you will have to use the performance counters
via RDPMC (you will have to do some googling to find an example).

SIMICS may have C function call that you can insert into your code that
controls collection of counter data. If it does, then this may be the way
for you to go.

Jim Dempsey

-----Original Message-----
From: parsec-users-bounces at lists.cs.princeton.edu
[mailto:parsec-users-bounces at lists.cs.princeton.edu] On Behalf Of Mahmood
Naderan
Sent: Tuesday, April 19, 2011 12:49 AM
To: PARSEC
Subject: [parsec-users] multithread vs single thread

Hi,
When I run blackscholes with one thread the total cycles reported by simics
are about 7.5B cycles. However when I run it with 4 threads, each core runs
for 850M cycles (totally 3.3B cycles). Is that normal? Does this
multithreading represents parallel execution?

thanks, 

// Naderan *Mahmood;

_______________________________________________
parsec-users mailing list
parsec-users at lists.cs.princeton.edu
https://lists.cs.princeton.edu/mailman/listinfo/parsec-users

_______________________________________________
parsec-users mailing list
parsec-users at lists.cs.princeton.edu
https://lists.cs.princeton.edu/mailman/listinfo/parsec-users



More information about the parsec-users mailing list