running multiple application on gem5-gpu

1,187 views
Skip to first unread message

Zhou Da

unread,
Mar 13, 2014, 9:23:53 PM3/13/14
to gem5-g...@googlegroups.com
Hi,

I'm from University of British Columbia working a cache related project in CPU-GPU heterogeneous system. I wondered if gem5-gpu is able to run two distinct applications, one on CPU and one on GPU, at the same time in syscall emulation.
If so, how should I do it? I went through the configuration and help files, did not find a clear way of doing this. It looks like the rodinia benchmarks uses CPU to launch work in the GPU core, the CPU core is pretty much idle while GPU is executing. 

Another side question here, 
Does the rodinia provide such benchmarks? or any other known benchmark would be able to do so, or I need to write my own benchmarks? 

Thanks
Da

Hsien Chu

unread,
Mar 13, 2014, 10:02:14 PM3/13/14
to Zhou Da, gem5-g...@googlegroups.com
Hi Zhou,

I just checked the CUDA model. I think CPU will not be blocked after launching a kernel.

Best,

Zhou Da

unread,
Mar 13, 2014, 10:50:45 PM3/13/14
to gem5-g...@googlegroups.com, Zhou Da
Hi Chu,

I understand that CPU is not blocked after the launching kernel. However I don't think it's doing anything in most of the benchmark packages. 
Does that mean we need to modify the benchmark to force CPU to execute some code? 

It would be best if there are existing benchmark packages that will do this. I am not sure if you are aware of any? 
This would give a more realistic result, since I might be bias in certain way to have cpu executing code according to my preference.

Thanks
Da

Hsien Chu

unread,
Mar 13, 2014, 11:09:02 PM3/13/14
to Zhou Da, gem5-g...@googlegroups.com
I'm not very familiar with benchmark applications. But it's reasonable that most workloads of Rodinia were assigned to GPU since Rodinia is a GPU benchmark. If you want to move some workload from GPU to CPU, you need to reprogram these applications. 

Zhou Da

unread,
Mar 14, 2014, 1:00:47 AM3/14/14
to Hsien Chu, gem5-g...@googlegroups.com
Thanks Chu, this really helps. 

Zhou Da

unread,
Mar 14, 2014, 3:59:22 AM3/14/14
to Hsien Chu, gem5-g...@googlegroups.com
Hi

What about if I want to run two different benchmarks on gem5-gpu at the same time, how should I do it? Does the SE mode support this?
I read on two different powerpoint, one saying SE mode support multiple applications, the other saying that FS mode support multiple applications. 
Sorry for my lack of knowledge here.I am very new to this simulator.

Thanks
Da


On Thu, Mar 13, 2014 at 8:09 PM, Hsien Chu <zhuxi...@gmail.com> wrote:

Joel Hestness

unread,
Mar 14, 2014, 12:54:12 PM3/14/14
to Zhou Da, Hsien Chu, gem5-gpu developers
Hi Da,
  gem5 allows you to run multiple benchmarks concurrently in SE mode, though currently, the configuration script for gem5-gpu (./gem5-gpu/configs/se_fusion.py) doesn't yet contain the bits that would be required to run multiple applications in a heterogeneous processor.  If you would like to port this functionality to use in gem5-gpu, I'd recommend looking into the gem5 SE config script (./gem5/configs/example/se.py around line 65, the get_processes() function), and see how it sets up multiple processes.

  The other option is to setup a disk image with your binaries for full-system simulation, and set up checkpoints to be used .  If you'd like to head this route, we recommend referring to the relevant bits of the PARSEC on M5 tech report (http://www.cs.utexas.edu/~parsec_m5).  That site also contains a Linux kernel that we recommend.

  It should be noted that if you try either SE or FS mode for multiprocess workloads, if you try running two benchmarks that both issue GPU kernels, the simulator's behavior is currently undefined, because gem5-gpu does not yet implement handling multiple GPU contexts.

  Hope this helps,
  Joel

--
  Joel Hestness
  PhD Student, Computer Architecture
  Dept. of Computer Science, University of Wisconsin - Madison
  http://pages.cs.wisc.edu/~hestness/

Zhou Da

unread,
Mar 15, 2014, 4:07:24 PM3/15/14
to Joel Hestness, Hsien Chu, gem5-gpu developers
Hi Joel,

Thanks for the info. What I am trying to do is to have both GPU and CPU code to execute some kinds of application (benchmarks) at the same time. I would like to study the behavior of the last level cache when both GPU and CPU are making cache requests. 

Are any of the existing benchmarks able to do so already?

Thanks
Da

Joel Hestness

unread,
Mar 15, 2014, 4:17:37 PM3/15/14
to Zhou Da, Hsien Chu, gem5-gpu developers
Hi Da,
  The only benchmark in Rodinia that does significant concurrent work on both core types is heartwall (available in gem5-gpu benchmarks).  I think there is potential to modify a few of the Rodinia-nocopy benchmarks to better overlap computation (e.g. backprop), but I've only recently started looking at this myself.  Multiprocess workloads running in full-system mode will likely be the easiest way to get concurrent CPU and GPU computation.

  Joel

Zhou Da

unread,
Mar 15, 2014, 8:47:29 PM3/15/14
to Joel Hestness, Hsien Chu, gem5-gpu developers
Hi Joel, 

It seems to me that the benchmark from the PARSEC are targeted specific to multiple CPU cores case, I don't think they actually evaluate the heterogeneous workloads as I would like. 
Do you have any suggestions of which benchmarks might be suitable? 

Thanks
Da

Joel Hestness

unread,
Mar 15, 2014, 10:02:54 PM3/15/14
to Zhou Da, Hsien Chu, gem5-gpu developers
I was just suggesting that the tech report has info on how to set up gem5 full-system benchmarks on a disk image.

Regarding heterogeneous system benchmarks, there aren't any suites that show concurrent CPU-GPU computation.  We're starting to explore existing GPU benchmark suites (e.g. Rodinia, Parboil, MEVBench) to look at the potential for CPU-GPU concurrent computation with a unified address space (i.e. when no longer requiring memory copies).

  Joel
Reply all
Reply to author
Forward
Message has been deleted
Message has been deleted
Message has been deleted
0 new messages