当前位置:网站首页>The significance of XOR in embedded C language
The significance of XOR in embedded C language
2022-07-07 15:38:00 【sgmcy】
Bitwise operations are divided into : And , or , Not
But why is there an XOR ?
And : All two are 1, It's just 1, Otherwise 0.
or : As long as one is 1, Namely 1, All two are 0, Output is 0
Not :0 change 1,1 change 0
In the past, in class , The teacher told us
The role of and , To make someone bit Used to clear
The role of or , To make someone bit Set up 1
But there is no function of XOR
Exclusive or : Same as 0, Different for 1
The most classic application of XOR , It is the clearing of registers . The classic one x86 Architecture , Frequently used register zeroing
First , Read the value of this register , Then let the value and the register XOR , You can clear the entire register
Especially in X86 In assembly language programming , You often see this XOR clear operation , That's why XOR is introduced
边栏推荐
- 【OBS】RTMPSockBuf_Fill, remote host closed connection.
- STM32F103C8T6 PWM驱动舵机(SG90)
- 2. Heap sort "hard to understand sort"
- CTFshow,信息搜集:web9
- Ctfshow, information collection: web14
- [target detection] yolov5 Runtong voc2007 data set
- 【兰州大学】考研初试复试资料分享
- Basic knowledge sorting of mongodb database
- Pat grade a 1103 integer factorizatio
- [quickstart to Digital IC Validation] 20. Basic syntax for system verilog Learning 7 (Coverage Driven... Including practical exercises)
猜你喜欢
[quick start of Digital IC Verification] 20. Basic grammar of SystemVerilog learning 7 (coverage driven... Including practical exercises)
CTFshow,信息搜集:web6
[data mining] visual pattern mining: hog feature + cosine similarity /k-means clustering
Ctfshow, information collection: web10
CTFshow,信息搜集:web8
【數字IC驗證快速入門】20、SystemVerilog學習之基本語法7(覆蓋率驅動...內含實踐練習)
Niuke real problem programming - day20
Window环境下配置Mongodb数据库
HPDC smart base Talent Development Summit essay
Summer safety is very important! Emergency safety education enters kindergarten
随机推荐
Database exception resolution caused by large table delete data deletion
【服务器数据恢复】某品牌StorageWorks服务器raid数据恢复案例
Actually changed from 408 to self proposition! 211 North China Electric Power University (Beijing)
Jacobo code coverage
How to release NFT in batches in opensea (rinkeby test network)
Integer learning
2. Heap sort "hard to understand sort"
[server data recovery] a case of RAID data recovery of a brand StorageWorks server
Share the technical details of super signature system construction
CTFshow,信息搜集:web6
Pat grade a 1103 integer factorizatio
Use cpolar to build a business website (2)
Unity's ASE achieves full screen sand blowing effect
Typescript release 4.8 beta
【服务器数据恢复】戴尔某型号服务器raid故障的数据恢复案例
Ctfshow, information collection: web8
[quick start of Digital IC Verification] 22. Ahb-sramc of SystemVerilog project practice (2) (Introduction to AMBA bus)
Ctfshow, information collection: web13
[deep learning] semantic segmentation experiment: UNET network /msrc2 dataset
[original] all management without assessment is nonsense!