diff options
| author | Duncan Sands <baldrick@free.fr> | 2010-01-06 08:45:52 +0000 |
|---|---|---|
| committer | Duncan Sands <baldrick@free.fr> | 2010-01-06 08:45:52 +0000 |
| commit | 78376ad7e15740eab9bed7efefca354c05d3d2e2 (patch) | |
| tree | 882bcbdbddcdd85694fc7ffcae1010d4f1195068 /llvm/lib/Target | |
| parent | a671c2a9fe496d8694ad7f6daa84f5b5d7f193a4 (diff) | |
| download | bcm5719-llvm-78376ad7e15740eab9bed7efefca354c05d3d2e2.tar.gz bcm5719-llvm-78376ad7e15740eab9bed7efefca354c05d3d2e2.zip | |
Partially address a README by having functionattrs consider calls to
memcpy, memset and other intrinsics that only access their arguments
to be readnone if the intrinsic's arguments all point to local memory.
This improves the testcase in the README to readonly, but it could in
theory be made readnone, however this would involve more sophisticated
analysis that looks through the memcpy.
llvm-svn: 92829
Diffstat (limited to 'llvm/lib/Target')
| -rw-r--r-- | llvm/lib/Target/README.txt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Target/README.txt b/llvm/lib/Target/README.txt index 22dadfeb3dd..38c3daa9383 100644 --- a/llvm/lib/Target/README.txt +++ b/llvm/lib/Target/README.txt @@ -1678,8 +1678,8 @@ And functionattrs doesn't realize that the p.0 load points to function local memory. Also, functionattrs doesn't know about memcpy/memset. This function should be -marked readnone, since it only twiddles local memory, but functionattrs doesn't -handle memset/memcpy/memmove aggressively: +marked readnone rather than readonly, since it only twiddles local memory, but +functionattrs doesn't handle memset/memcpy/memmove aggressively: struct X { int *p; int *q; }; int foo() { |

