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 translator/11528] New: Pass string values by reference where possible


For string variables that aren't modified after assignment, like most function
parameters, we could pass them as a "const char*" reference rather than a
char[MAXSTRINGLEN] copy.  With script functions it's easy to tell if a parameter
is modified; for embedded-C functions we could perhaps have a new /* foo */
annotation.

Return values could get similar treatment -- __retvalue could be a char* which
is pointed to the desired destination.  We just need to make sure that even with
an unused return value, we still give __retvalue somewhere to go.

-- 
           Summary: Pass string values by reference where possible
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: translator
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: jistone at redhat dot com


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

------- 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]