From Fedora Project Wiki

< Features

Revision as of 22:05, 23 January 2013 by Law (talk | contribs) (Created page with "<!-- All fields on this form are required to be accepted by FESCo. We also request that you maintain the same order of sections so that all of the feature pages are uniform. ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.


MEMSTOMP

Summary

Include the MEMSTOMP DSOs in Fedora 19

Owner

  • Name: Jeff Law
  • Email: law@redhat.com

Current status

  • Targeted release: Releases/19
  • Last updated: 2013-01-22
  • Percentage of completion: 50%

Detailed Description

MEMSTOMP is a DSO which can be preloaded by an application to detect calls to library routines with overlapping memory arguments. Specifically MEMSTOMP will detect calls to the following routines with overalapping memory arguments:

[w]memcpy, str[n]cat, wcs[n]cat, str[n]cpy, wcs[n]cpy, [w]mempcpy, memccpy, stp[n]cpy

While valgrind can detect these cases, using a DSO such as MEMSTOMP can be significantly faster.

The MEMSTOMP code utilizes GPLV2+ and LGPL3 code. The GPLV2+ code is limited to the backtrace code which is not thread safe and may need to be disabled/rewritten.

Benefit to Fedora

MEMSTOMP benefits Fedora by providing additional tools to help developers identify code with undefined behaviour and at a lower runtime cost than tools such as valgrind.


Scope

How To Test

MEMSTOMP does not currently have a testsuite. I propose adding a simple testsuite to MEMSTOMP which verifies that a call to each of the listed functions with overlapping arguments is detected and that a call to each without overlapping arguments results in proper copying.


User Experience

No user visible changes unless the user explicitly used the MEMSTOP DSO. For those who use the MEMSTOP DSO they would get a segfault or backtrace when running their application if the application has a call to one of the affected functions with overalapping memory arguments.

Dependencies

None.

Contingency Plan

Given the system runs fine without this DSO, worst case is we just remove the DSO.


Documentation

None available yet. Usage, list of functions/arguments checked would be added if package is approved.

Release Notes

Fedora 19 comes MEMSTOMP a DSO which can be preloaded into an application to discover overlapping memory arguments to certain functions at a lower runtime cost than valgrind.


Comments and Discussion