diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-07-16 22:00:33 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-07-16 22:00:33 +0000 |
commit | 8d5114910200a053421af05e82a38f53745c9120 (patch) | |
tree | 0e838b6451af9063931a75f4ca8ec45bc6dbe1c6 /llvm/lib/Target | |
parent | c9c22862d49788524f2636bda285544580fd6223 (diff) | |
download | bcm5719-llvm-8d5114910200a053421af05e82a38f53745c9120.tar.gz bcm5719-llvm-8d5114910200a053421af05e82a38f53745c9120.zip |
Keep valgrind quiet.
The isLive() method can read uninitialized memory, but it still gives correct
results.
llvm-svn: 108561
Diffstat (limited to 'llvm/lib/Target')
-rw-r--r-- | llvm/lib/Target/X86/X86FloatingPoint.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/llvm/lib/Target/X86/X86FloatingPoint.cpp b/llvm/lib/Target/X86/X86FloatingPoint.cpp index 627510d87d3..742dfbcaf56 100644 --- a/llvm/lib/Target/X86/X86FloatingPoint.cpp +++ b/llvm/lib/Target/X86/X86FloatingPoint.cpp @@ -50,7 +50,12 @@ STATISTIC(NumFP , "Number of floating point instructions"); namespace { struct FPS : public MachineFunctionPass { static char ID; - FPS() : MachineFunctionPass(&ID) {} + FPS() : MachineFunctionPass(&ID) { + // This is really only to keep valgrind quiet. + // The logic in isLive() is too much for it. + memset(Stack, 0, sizeof(Stack)); + memset(RegMap, 0, sizeof(RegMap)); + } virtual void getAnalysisUsage(AnalysisUsage &AU) const { AU.setPreservesCFG(); |