Skip to content

Bug #79487: Provide non-Windows implementations for LF_BACKOFF #40

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

akopytov
Copy link

Add LF_BACKOFF implementations for GCC and Sun Studio + some minor code
unification with InnoDB.

This obviously needs further unification with InnoDB code (in particular, ut_delay()) and the contributed patch for http://bugs.mysql.com/bug.php?id=74832.

But I understand this patch will not be merged as is anyway, so I tried to make it as isolated as possible, but avoid code duplication with InnoDB at the same time.

@mysql-oca-bot
Copy link

Hi, thank you for your contribution. Please confirm this code is submitted under the terms of the OCA (Oracle's Contribution Agreement) you have previously signed by cutting and pasting the following text as a comment:
"I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it."
Thanks

@ghost
Copy link

ghost commented Dec 21, 2015

See also: http://bugs.mysql.com/bug.php?id=72755
and http://bugs.mysql.com/bug.php?id=72805 which was probably incorrectly closed - as everything got kind of messy around some things going in/out of InnoDB and generic mysys code.

My comment would be that perhaps the UT_LOW_PRIORITY_CPU() and UT_RESUME_PRIORITY_CPU() macros should be called in my_yield_processor() rather than trusting the caller to also call them. Without these, the code generated for POWER in lf_hash and lf_alloc-pin will not do exactly what is intended - it'll delay, but it won't relax the CPU thread to give more core resources to other threads executing in the core.

Then there's the issue of the rest of the code in lf_hash... which I'm not convinced is correct.

Add LF_BACKOFF implementations for GCC and Sun Studio + some minor code
unification with InnoDB.
@akopytov
Copy link
Author

Thanks, @stewart-ibm. I moved UT_LOW_PRIORITY_CPU() and UT_RESUME_PRIORITY_CPU() code from InnoDB to my_atomic.h and used it in my_yield_processor().

@akopytov
Copy link
Author

I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.

@mysql-oca-bot
Copy link

Hi, thank you for your contribution. Your code has been assigned to an internal queue. Please follow
bug http://bugs.mysql.com/bug.php?id=79487 for updates.
Thanks

vmg pushed a commit to planetscale/mysql-server that referenced this pull request Nov 21, 2023
…te-system-table-metrics

Setup explicit separate list for system table metrics
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants