mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
Merge branch 'docs/fix_typo_according_to_feedback' into 'master'
docs: Fix typo in get-started/index.rst and thread-local-storage.rst based on customer feedback Closes DOC-6534 and DOC-6578 See merge request espressif/esp-idf!26786
This commit is contained in:
commit
2a62932ef1
@ -27,7 +27,7 @@ In this case, the maximum number of variables that can be allocated is limited b
|
||||
|
||||
Using the APIs above, you can allocate thread local variables of an arbitrary size, and assign them to any number of tasks. Different tasks can have different sets of TLS variables.
|
||||
|
||||
If size of the variable is more then 4 bytes, then you need to allocate/deallocate memory for it. Variable's deallocation is initiated by FreeRTOS when task is deleted, but user must provide callback function to do proper cleanup.
|
||||
If size of the variable is more than 4 bytes, then you need to allocate/deallocate memory for it. Variable's deallocation is initiated by FreeRTOS when task is deleted, but user must provide callback function to do proper cleanup.
|
||||
|
||||
.. _pthread-api:
|
||||
|
||||
@ -41,7 +41,7 @@ The ESP-IDF provides the following :doc:`/api-reference/system/pthread` to manag
|
||||
- :cpp:func:`pthread_getspecific`
|
||||
- :cpp:func:`pthread_setspecific`
|
||||
|
||||
These APIs have all benefits of the ones above, but eliminates some their limits. The number of variables is limited only by size of available memory on the heap. Due to the dynamic nature, this APIs introduce additional performance overhead compared to the native one.
|
||||
These APIs have all benefits of the ones above, but eliminates some their limits. The number of variables is limited only by size of available memory on the heap. Due to the dynamic nature, this API introduces additional performance overhead compared to the native one.
|
||||
|
||||
.. _c11-std:
|
||||
|
||||
@ -52,4 +52,4 @@ The ESP-IDF FreeRTOS supports thread local variables according to C11 standard,
|
||||
|
||||
Storage for that kind of variables is allocated on the task stack. Note that area for all such variables in the program is allocated on the stack of every task in the system even if that task does not use such variables at all. For example, ESP-IDF system tasks (e.g., ``ipc``, ``timer`` tasks etc.) will also have that extra stack space allocated. Thus feature should be used with care.
|
||||
|
||||
Using C11 thread local variables comes at a trade-off. One one hand, they are quite handy to use in programming and can be accessed using minimal CPU instructions. However, this benefit comes at the cost of additional stack usage for all tasks in the system. Due to static nature of variables allocation, all tasks in the system have the same sets of C11 thread local variables.
|
||||
Using C11 thread local variables comes at a trade-off. On one hand, they are quite handy to use in programming and can be accessed using minimal CPU instructions. However, this benefit comes at the cost of additional stack usage for all tasks in the system. Due to static nature of variables allocation, all tasks in the system have the same sets of C11 thread local variables.
|
||||
|
@ -196,7 +196,7 @@ For the manual procedure, please select according to your operating system.
|
||||
Build Your First Project
|
||||
========================
|
||||
|
||||
If you already have the ESP-IDF installed and not using IDE, you can build your first project from the command line following the :ref:`Start a Project on Windows <get-started-windows-first-steps>` or :ref:`Start a Project on Linux and macOS <get-started-linux-macos-first-steps>`.
|
||||
If you already have the ESP-IDF installed and are not using an IDE, you can build your first project from the command line following the :ref:`Start a Project on Windows <get-started-windows-first-steps>` or :ref:`Start a Project on Linux and macOS <get-started-linux-macos-first-steps>`.
|
||||
|
||||
.. _Stable version: https://docs.espressif.com/projects/esp-idf/en/stable/
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user