This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug runtime/11140] SystemTap userspace marker in shared libraries cause probed program crash


------- Additional Comments From wcohen at redhat dot com  2010-01-12 01:16 -------
The old implementation of userspace probing used __access_process_vm() in the
runtime access_process_vm.h. This function used copy_to_user_page().

On x86 machine cache consistency is hardware enforced. The resulting
copy_to_user_page() ends up be just a memcpy().

However, On the ia64 (and powerpc) the code needs to take some additional steps
to make sure the cache and memory are consistent. This results in the ia64 (and
powerpc) copy_to_user_page including a flush_icache_user_range():

#define copy_to_user_page(vma, page, vaddr, dst, src, len) \
do { memcpy(dst, src, len); \
     flush_icache_user_range(vma, page, vaddr, len); \
} while (0)

There is some discussion about the copy_to_user_page() and cache coherence at:

http://rhkernel.org/RHEL5+2.6.18-8.el5/Documentation/cachetlb.txt#L352



-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11140

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]