Codegen: Copy and restore the ValueMap and ClastVars explicitly
authorTobias Grosser <grosser@fim.uni-passau.de>
Thu, 1 Nov 2012 05:34:35 +0000 (05:34 +0000)
committerTobias Grosser <grosser@fim.uni-passau.de>
Thu, 1 Nov 2012 05:34:35 +0000 (05:34 +0000)
commita17f666f99b189f1d53dcf913420ff1edf9e91d5
treefed4ec70ed18c8b00e52108975d5c71dea6c3415
parentbd55daf2eea7e87c83522393b91572ca1f2eaa47
Codegen: Copy and restore the ValueMap and ClastVars explicitly

When generating OpenMP or GPGPU code the original ValueMap and ClastVars must be
kept. We already recovered the original ClastVars by reverting the changes, but
we did not keep the content of the ValueMap. This patch keeps now an explicit
copy of both maps and restores them after generating OpenMP or GPGPU code.

This is an adapted version of a patch contributed by:
Armin Groesslinger  <armin.groesslinger@uni-passau.de>

llvm-svn: 167213
polly/lib/CodeGen/CodeGeneration.cpp
polly/test/CodeGen/OpenMP/clastvar_after_parallel_loop.ll [new file with mode: 0644]