当前位置:网站首页>静态链接和动态链接
静态链接和动态链接
2022-08-05 09:55:00 【江南无故人】
链接有动态链接和静态链接之分:
动态链接:
在链接阶段,将汇编生成的.o文件和所需要的库一起链接打包到可执行文件中,成为可执行程序的一部分。
优点:
运行速度快,可执行程序具备了程序运行的所有内容,对运行环境的依赖小,兼容性好。
缺点:
程序体积大,浪费空间,每个可执行程序都有静态库的副本,如果静态库更新就需要重新进行编译链接
动态链接:
在程序运行时载入动态库,不同可执行程序如果调用相同的的库,内存里只有一份动态库的实例
优点:
程序体积小,节省空间,更新方便
缺点:
在程序运行时链接,相比静态链接有一定的性能损失
边栏推荐
- 2022-08-01 Review the basic binary tree and operations
- express hot-reload
- Jenkins manual (2) - software configuration
- 欧盟 | 地平线 2020 ENSEMBLE:D2.13 SOTIF Safety Concept(下)
- PAT Grade B-B1020 Mooncake(25)
- 2.4G无线收发模块的应用
- Hundred lines of code launch red hearts, why programmers lose their girlfriends!
- 阿里顶级架构师多年总结的JVM宝典,哪里不会查哪里!
- 无题十四
- MySQL advanced (twenty-seven) database index principle
猜你喜欢
After Keil upgrades to AC6, what changes?
Analysis and practice of antjian webshell dynamic encrypted connection
欧盟 | 地平线 2020 ENSEMBLE:D2.13 SOTIF Safety Concept(上)
Pytorch深度学习快速入门教程 -- 土堆教程笔记(三)
Weekly Report 2022-8-4
Tanabata romantic date without overtime, RPA robot helps you get the job done
【AGC】增长服务1-远程配置示例
数据中台建设(十):数据安全管理
上海控安技术成果入选市经信委《2021年上海市网络安全产业创新攻关成果目录》
ECCV 2022 Oral Video Instance Segmentation New SOTA: SeqFormer & IDOL and CVPR 2022 Video Instance Segmentation Competition Champion Scheme...
随机推荐
egg框架使用(一)
Egg framework usage (2)
无题八
DFINITY 基金会创始人谈熊市沉浮,DeFi 项目该何去何从
After Keil upgrades to AC6, what changes?
Wei Dongshan Digital Photo Frame Project Learning (6) Transplantation of tslib
欧盟 | 地平线 2020 ENSEMBLE:D2.13 SOTIF Safety Concept(上)
无题七
Science bosses say | Hong Kong rhubarb KaiBin teacher take you unlock the relationship between the matrix and 6 g
leetcode refers to Offer 10- II. Frog jumping steps
Bias lock/light lock/heavy lock lock is healthier. How is locking and unlocking accomplished?
Example of Noise Calculation for Amplifier OPA855
Why do I recommend using smart async?
首次去中心化抢劫?近2亿美元损失:跨链桥Nomad 被攻击事件分析
uniapp 连接ibeacon
歌词整理
JS逆向入门学习之回收商网,手机号码简易加密解析
What is CRM Decision Analysis Management?
Weekly Report 2022-8-4
无题十二