[llvm-commits] CVS: llvm/lib/Analysis/DataStructure/Local.cpp
Chris Lattner
lattner at cs.uiuc.edu
Mon Feb 16 12:38:02 PST 2004
Changes in directory llvm/lib/Analysis/DataStructure:
Local.cpp updated: 1.82 -> 1.83
---
Log message:
memset and bcopy and now unified by the llvm.memset intrinsic
---
Diffs of the changes: (+5 -14)
Index: llvm/lib/Analysis/DataStructure/Local.cpp
diff -u llvm/lib/Analysis/DataStructure/Local.cpp:1.82 llvm/lib/Analysis/DataStructure/Local.cpp:1.83
--- llvm/lib/Analysis/DataStructure/Local.cpp:1.82 Sat Feb 14 23:53:42 2004
+++ llvm/lib/Analysis/DataStructure/Local.cpp Mon Feb 16 12:37:40 2004
@@ -468,6 +468,11 @@
N->setModifiedMarker()->setReadMarker();
return;
}
+ case Intrinsic::memset:
+ // Mark the memory modified.
+ if (DSNode *N = getValueDest(**CS.arg_begin()).getNode())
+ N->setModifiedMarker();
+ return;
default:
if (F->getName() == "calloc") {
setDestTo(*CS.getInstruction(),
@@ -478,20 +483,6 @@
RetNH.mergeWith(getValueDest(**CS.arg_begin()));
if (DSNode *N = RetNH.getNode())
N->setHeapNodeMarker()->setModifiedMarker()->setReadMarker();
- return;
- } else if (F->getName() == "memset") {
- // Merge the first argument with the return value, and mark the memory
- // modified.
- DSNodeHandle RetNH = getValueDest(*CS.getInstruction());
- RetNH.mergeWith(getValueDest(**CS.arg_begin()));
- if (DSNode *N = RetNH.getNode())
- N->setModifiedMarker();
- return;
- } else if (F->getName() == "bzero") {
- // Mark the memory modified.
- DSNodeHandle H = getValueDest(**CS.arg_begin());
- if (DSNode *N = H.getNode())
- N->setModifiedMarker();
return;
} else if (F->getName() == "fopen" && CS.arg_end()-CS.arg_begin() == 2){
// fopen reads the mode argument strings.
More information about the llvm-commits
mailing list