> For the complete documentation index, see [llms.txt](https://mariadb.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mariadb.com/docs/server/reference/system-tables/performance-schema/performance-schema-tables/performance-schema-rwlock_instances-table.md).

# Performance Schema rwlock\_instances Table

The `rwlock_instances` table lists all read write lock (rwlock) instances that the Performance Schema sees while the server is executing. A read write is a mechanism for ensuring threads can either share access to common resources, or have exclusive access.

The [performance\_schema\_max\_rwlock\_instances](/docs/server/reference/system-tables/performance-schema/performance-schema-system-variables.md#performance_schema_max_rwlock_instances) system variable specifies the maximum number of instrumented rwlock objects.

The `rwlock_instances` table contains the following columns:

| Column                        | Description                                                                           |
| ----------------------------- | ------------------------------------------------------------------------------------- |
| NAME                          | Instrument name associated with the read write lock                                   |
| OBJECT\_INSTANCE\_BEGIN       | Address in memory of the instrumented lock                                            |
| WRITE\_LOCKED\_BY\_THREAD\_ID | THREAD\_ID of the locking thread if locked in write (exclusive) mode, otherwise NULL. |
| READ\_LOCKED\_BY\_COUNT       | Count of current read locks held                                                      |

<sub>*This page is licensed: CC BY-SA / Gnu FDL*</sub>

{% @marketo/form formId="4316" %}
