List:Commits« Previous MessageNext Message »
From:Michael Widenius Date:April 13 2009 9:50pm
Subject:Re: Review of the performance schema instrumentation interface
View as plain text  
Hi!

>>>>> "Sergei" == Sergei Golubchik <serg@stripped> writes:

Sergei> Hi, Marc!
Sergei> On Mar 19, Marc Alff wrote:
>> 
>> Replying in English for the other readers
>> 
>> The problem:
>> 
>> In include/mysql/psi.h today, the proposed change is to use macros like
>> 
>> #ifdef HAVE_PERFORMANCE_SCHEMA
>> #define MYSQL_FILE_PREAD <one way>
>> #else
>> #define MYSQL_FILE_PREAD <another way>
>> #endif
>> 
>> (Let's call this solution [1])
>> 
>> and change the code from
>> 
>> my_pread(...)
>> 
>> to
>> 
>> MYSQL_FILE_PREAD(...)

Sergei> One comment about the style.
Sergei> I'd prefer the instrumentation to mostly as transparent as possible to
Sergei> the most of the code. And using UPPERCASE for commonly used functions
Sergei> (or macros pretending to be functions) is very annoying.

Sergei> Could this be mysql_file_pread() ? Pretty please ?
 
That would require us to change all code to use my_file_pread(),
which is a big change and hard to remember.

In this case it would be easier to just just change the mysys
functions to be called my_internal_pread() and have macro that modifies
how my_pread() is interpreted.  This way you have to do very little
changes in the main code.

It should also be possible to have any external function that is
calling my_internal_pread() to work independently how MySQL is
compiled.

With a little bit of work in this direction, you can achieve that an
external module compiled WITHOUT instrumentation would work with a
MySQL server compiled with or without instrumentation.

Regards,
Monty
Thread
[Fwd: Review of the performance schema instrumentation interface (was:moins de remplacements)]Marc Alff19 Mar
  • Re: [Fwd: Review of the performance schema instrumentation interface(was: moins de remplacements)]Guilhem Bichot23 Mar
    • Re: [Fwd: Review of the performance schema instrumentation interfaceMarc Alff23 Mar
      • Re: [Fwd: Review of the performance schema instrumentation interfaceGuilhem Bichot7 Apr
        • Re: [Fwd: Review of the performance schema instrumentation interfaceMarc Alff7 Apr
          • Re: [Fwd: Review of the performance schema instrumentation interfaceGuilhem Bichot7 Apr
            • Re: [Fwd: Review of the performance schema instrumentation interfaceMarc Alff7 Apr
              • Re: [Fwd: Review of the performance schema instrumentation interfaceGuilhem Bichot8 Apr
                • Re: [Fwd: Review of the performance schema instrumentation interfaceMarc Alff20 Jun
  • Instrumenting Maria system threads Re: [Fwd: Review of the performanceschema instrumentation interface (was: moins de remplacements)]Guilhem Bichot23 Mar
  • Re: Review of the performance schema instrumentation interfaceSergei Golubchik10 Apr
    • Re: Review of the performance schema instrumentation interfaceMichael Widenius13 Apr