1. ADR pseudo-instruction --- small range address reading
The ADR pseudo-instruction reads the address value based on the PC relative offset or the address value based on the register relative offset into the register. When the assembler compiler compiles the source program, the ADR pseudo-instruction is replaced by a suitable instruction by the compiler. Usually, the compiler uses an ADD instruction or a SUB instruction to implement the function of the ADR pseudo-instruction. If it cannot be implemented with one instruction, an error will be generated and the compilation will fail.
ADR pseudo-instruction format: ADR{cond} register, expr
The value range of the address expression expr is:
When the address value is byte aligned, its fetch range is: +255 ~ 255B;
When the address value is word-aligned, the range of its fetch is: -1020 ~ 1020B;
2. ADRL pseudo-instruction ---- medium range address reading
The ADRL pseudo-instruction reads the address value based on the PC relative offset or the address value based on the register relative offset into the register. It can read a wider range of addresses than the ADR pseudo-instruction. When the assembler compiler compiles the source program, the ADRL pseudo-instruction is replaced by two appropriate instructions by the compiler. If it cannot be implemented with two instructions, an error will occur and the compilation will fail.
ADRL pseudo-instruction format: ADRL{cond} register, expr
The value range of the address expression expr is:
When the address value is byte aligned, the range of its fetch is: -64K~64K;
When the address value is word-aligned, the range of its fetch is: -256K~256K;
3. LDR pseudo-instruction-----large range of address reading
The LDR pseudo-instruction is used to load a 32-bit immediate value or an address value into a specified register. When assembling a source program, the LDR pseudo-instruction is replaced by a suitable instruction by the compiler. If the loaded constant does not exceed the range of MOV or MVN, the MOV or MVN instruction is used to replace the LDR pseudo-instruction. Otherwise, the assembler puts the constant into a literal pool and uses a program-relative offset LDR instruction to read the constant from the literal pool.
Previous article:Solution of ECG Defibrillation Simulation Generation System Based on ARM9
Next article:Select an operating system for ARM CPU
Recommended ReadingLatest update time:2024-11-16 22:50
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- Unboxing
- Tmall Genie controls ESP8266 to light up LED lights
- Recommended high voltage mosfet models
- CC3200 PWM and ADC issues
- Cheap_flash_fs (FAT high-end version) -- embedded FAT16/32 file system free source code download
- Single-cell lithium battery fuel gauge
- CS5090 5V USB input charges 2 lithium batteries, with path management application, which can realize the function of "charging and discharging at the same time".
- Free review: National Technology low power series, N32L43x is now available for testing
- DSP interrupt system and its application
- MSP430G2553 interrupt processing function