[Bug translator/25346] support enum context variables

fweimer at redhat dot com sourceware-bugzilla@sourceware.org
Fri Dec 18 12:29:48 GMT 2020


https://sourceware.org/bugzilla/show_bug.cgi?id=25346

Florian Weimer <fweimer at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |fweimer at redhat dot com

--- Comment #3 from Florian Weimer <fweimer at redhat dot com> ---
Maybe it would also be useful to add a way to compute a constant using a
userspace expression.  Basically, generate a C source file like this

int systemtap_expression_1 = <<insertion expression 1 here>>;
int systemtap_expression_2 = <<insertion expression 2 here>>;

Compile this to an object file, and extract the constant from there.

Or use inline asm and search for some marker string around the constants that
were spliced in using inline asm arguments.

This would work for arbitrary C expressions that evaluate to compile-time
constants, and it sidesteps the kernel vs userspace context issue.

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


More information about the Systemtap mailing list