当前位置:网站首页>Thread, thread stack, method stack, the difference of creating thread
Thread, thread stack, method stack, the difference of creating thread
2022-07-03 20:19:00 【Chen4852010】
1. A thread is actually a stack , Each thread has a name , For example, the main thread is called main Threads , But the name of the thread has nothing to do with the method stack in the thread
2. How to create threads ( Take the main thread as an example )
First allocate a stack space , And then press the stack ( Each thread is created , There will be a main method stack , That is, speaking of code, there must be a method stack ), This method stack is actually the same as our ordinary calling methods , They all come from the methods of classes and objects
With main Thread as an example ,jvm Distribute Main thread space , call Object's main Method ,main Method stack …, and main Resources available by methods , Now only main The object of the method attribute
Again , We create threads , First of all, there must be a class , object ( Realized runnable Interface ), Then call the api , here jvm Allocate a stack space , Push the , Of this object run Method stack , And this run Methods also come from objects , At the moment run Method You can only get Of this object attribute
To make a long story short , Everything is class and , object , Threads are stack space , In stack space Stack frame is method stack , These stack pressing processes , It's all called Class , So in the method stack Properties and methods that can be called , Can also be applied to Of classes and objects The rules
边栏推荐
- Microsoft: the 12th generation core processor needs to be upgraded to win11 to give full play to its maximum performance
- Global and Chinese market of cyanuric acid 2022-2028: Research Report on technology, participants, trends, market size and share
- What is the difference between a kill process and a close process- What are the differences between kill process and close process?
- Sword finger offer 30 Stack containing min function
- Instructions for common methods of regular expressions
- Sightseeing - statistics of the number of shortest paths + state transfer + secondary small paths
- Cap and base theory
- 强基计划 数学相关书籍 推荐
- Wargames study notes -- Leviathan
- BOC protected alanine zinc porphyrin Zn · TAPP ala BOC / alanine zinc porphyrin Zn · TAPP ala BOC / alanine zinc porphyrin Zn · TAPP ala BOC / alanine zinc porphyrin Zn · TAPP ala BOC supplied by Qiyu
猜你喜欢
![How to read the source code [debug and observe the source code]](/img/0d/6495c5da40ed1282803b25746a3f29.jpg)
How to read the source code [debug and observe the source code]

Research Report on the overall scale, major manufacturers, major regions, products and application segmentation of rotary tablet presses in the global market in 2022

Example of peanut shell inner net penetration

MPLS configuration
![Meso tetra [P - (p-n-carbazole benzylidene imino)] phenylporphyrin (tcipp) /eu (tcipp) [pc( α- 2-oc8h17) 4] and euh (tcipp) [pc (a-2-oc8h17) 4] supplied by Qiyue](/img/5b/fc776a1982e24b82984d82be6a016f.jpg)
Meso tetra [P - (p-n-carbazole benzylidene imino)] phenylporphyrin (tcipp) /eu (tcipp) [pc( α- 2-oc8h17) 4] and euh (tcipp) [pc (a-2-oc8h17) 4] supplied by Qiyue
![[effective Objective-C] - block and grand central distribution](/img/09/22b979b97ea13d649b4b904637b79f.jpg)
[effective Objective-C] - block and grand central distribution

Don't be afraid of no foundation. Zero foundation doesn't need any technology to reinstall the computer system

原生表格-滚动-合并功能

Professional interpretation | how to become an SQL developer

Explore the internal mechanism of modern browsers (I) (original translation)
随机推荐
Research Report on the overall scale, major manufacturers, major regions, products and application segmentation of rotary tablet presses in the global market in 2022
[effective Objective-C] - block and grand central distribution
2.5 conversion of different data types (2)
3. Data binding
4. Data binding
Professional interpretation | how to become an SQL developer
你真的知道自己多大了吗?
2. Template syntax
jvm jni 及 pvm pybind11 大批量数据传输及优化
Virtual machine installation deepin system
The 15 year old interviewer will teach you four unique skills that you must pass the interview
Change deepin to Alibaba image source
Ruby replaces gem Alibaba image
Global and Chinese market of high purity copper foil 2022-2028: Research Report on technology, participants, trends, market size and share
MPLS configuration
7. Data broker presentation
Wechat applet quick start (including NPM package use and mobx status management)
Part 28 supplement (XXVIII) busyindicator (waiting for elements)
Get log4net log file in C - get log4net log file in C
2.6 formula calculation