CN102955713B - The disposal route that a kind of 802.11n wireless network card chip emulation firmware is optimized - Google Patents
The disposal route that a kind of 802.11n wireless network card chip emulation firmware is optimized Download PDFInfo
- Publication number
- CN102955713B CN102955713B CN201110255501.0A CN201110255501A CN102955713B CN 102955713 B CN102955713 B CN 102955713B CN 201110255501 A CN201110255501 A CN 201110255501A CN 102955713 B CN102955713 B CN 102955713B
- Authority
- CN
- China
- Prior art keywords
- firmware
- data structure
- interrupt
- data
- emulation
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 claims abstract description 26
- 238000004088 simulation Methods 0.000 claims abstract description 20
- 238000005457 optimization Methods 0.000 claims abstract description 7
- 238000012795 verification Methods 0.000 claims description 19
- 230000010354 integration Effects 0.000 claims description 6
- 238000007689 inspection Methods 0.000 claims description 3
- 230000005540 biological transmission Effects 0.000 claims 1
- 230000006870 function Effects 0.000 description 16
- 238000010586 diagram Methods 0.000 description 3
- 238000011144 upstream manufacturing Methods 0.000 description 2
- 238000006243 chemical reaction Methods 0.000 description 1
- 238000004891 communication Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 239000002699 waste material Substances 0.000 description 1
Landscapes
- Stored Programmes (AREA)
- Debugging And Monitoring (AREA)
Abstract
The invention discloses the disposal route that a kind of wireless network card chip emulation firmware is optimized, the method for the front-end simulation of chip and rear end emulation demand customized firmware, and provides support.Method comprise interruption compilation process, improve cpu bus efficiency and the optimization of firmware volume.The correctness of aforesaid operations can be judged by the self-check module in simulating, verifying environment and simulation waveform and optimize the integrality of rear data.
Description
Technical field
The present invention relates to a kind of disposal route optimized based on SoC framework 802.11n wireless network card chip emulation firmware.
Background technology
Due to the increase of SOC communication chip complexity, more and more stricter to the requirement of power consumption and efficiency, this also just has higher requirement to traditional verification mode.Use firmware and RTL to carry out emulation in the front and back end stage can solve and use CPU model not accurate enough and emulate and cannot measure the problems such as chip power-consumption in the past.
, simulation time long characteristic large based on 802.11n wireless network card chip complexity, considers to improve simulation efficiency by optimizing firmware to reduce the post-simulation time.This kind of optimization method, by the amendment to compilation and C language way of realization, realizes the raising of firmware operation performance, the reduction of firmware volume in the impregnable situation of original function.Add in initialization assembly code simultaneously and also can reduce C size of code to the process of vector interrupt, non vector interrupt, and the amendment to this function after common part integration is together facilitated.
Owing to needing to carry out the work such as time stimulatiom and waveform interception analysis power consumption at post-simulation, emulation uses the operating efficiency of firmware just to seem especially important, and the firmware after optimization can save simulation time in the post-simulation stage, and post-simulation work can be restrained as early as possible.
Summary of the invention
Method of the present invention utilizes assembly language and C language to realize one to cooperatively interact the fixer system carrying out emulating with verification environment, and this system comprises initialization and interrupt response.
Initialization comprises boots, interface and IO initialization, internal register initialization, key list initialization, and wherein interface and IO initialization can be distinguished by macro definition according to the different scenes of firmware application.
Interrupt response comprises downlink command response, upstream data response, downlink data response, UART interrupt response, TIMER interrupt response, WatchDog interrupt response, PMU interrupt response, SPIRF interrupt response etc., wherein achieves in the mode of list structure service data in upstream data response, downlink data response.
The present invention utilizes the collaborative simulation of firmware realization and verification environment and RTL, emulation and post-simulation work before realizing; CPU starts to call firmware program after completing electrification reset, and firmware is according to the data structure response instruction consulted with verification environment and data, and the self-verifying module finally provided by verification environment completes result and judges and terminate emulation; Firmware is as follows with the flow process in verification environment and RTL collaborative simulation process:
(1) first CPU calls in firmware the boots program collecting and write after electrification reset, completes the configuration to interrupt control register, utilize boots program realize interrupt function link and vector interrupt, non vector interrupt initialization operation; By realizing the operation of removing vector interrupt to the indirect assignment of interrupt control register in vector interrupt operation;
(2) association's data structure is used to complete the assignment operation of the related registers such as interface register, internal register, key list, key information district, MAC Address, BD, by association's data structure, scattered data structure is integrated together and carries out whole word assignment;
(3) carrying out in assignment operating process to BD register, using loop statement to replace the code presented in expanded form, realize the optimization of code under identical function;
(4) carry out the operation response of interrupt function, realize downlink command, up-downgoing data manipulation;
(5) the operation response backed off after random interrupt function completing this interrupt function carries out waiting for the process of next interrupt function;
(6), complete the inspection of each transmitting and receiving data frame at verification environment after, emulation is stopped.
Accompanying drawing explanation
Fig. 1 is a kind of process flow figure optimized based on SoC framework 802.11n wireless network card chip emulation firmware;
Fig. 2 uses association's process schematic diagram data;
Fig. 3 uses for loop statement initialization BD schematic diagram;
Fig. 4 is verification environment and firmware structure schematic diagram.
Embodiment
The present invention uses EDA emulation tool to combine checking and firmware collaborative simulation, under the prerequisite of function realizing original firmware, by the optimization to firmware code, realizes the raising of performance and the reduction of firmware area.The automatic comparison module improved by verification environment and the method for checking waveform carry out the judgement of simulation result, according to the validity that its result verification firmware is optimized.
Below in conjunction with drawings and Examples, present invention is described.
Fig. 1 is firmware operation flow chart illustration, describe firmware with the related procedure in verification environment collaborative simulation process.CPU starts to call firmware program after completing electrification reset, and firmware is according to the data structure response instruction consulted with verification environment and data, and the self-verifying module finally provided by verification environment completes result and judges and terminate emulation.
First 101:CPU can call in firmware the boots program collecting and write after electrification reset, completes the configuration to interrupt control register.
102: the initialization operation completing the related registers such as interface register, internal register, key list, key information district, MAC Address, BD.
103: carry out the operation response interrupting irq function, realize downlink command, up-downgoing data manipulation, release the process that irq function carries out waiting for next irq function after completing this operation.If CPU does not temporarily process this irq, do not remove interruption, wait for that next cpu cycle scans in this to have no progeny and process again.
104: after the operation completing an interruption irq service routine, wait for the generation of next irq program.
105: complete the inspection of each transmitting and receiving data frame at verification environment after, stop emulation.
Power on after CPU completes reset at chip, first call the boots program that assembly language is write, the initial configuration of interrupting is operated in and carries out here.Use and " ldrr0 ,=Addr are operated to the assignment of register; Ldrr1 ,=Data; Strr1, [r0] " realize the configuration of interruption control module, if use vector interrupt, by " ldrr9 ,=ICVectAddr; Ldrr9, [r9] " obtain Current interrupt number and indicate PC pointer to jump to response address, realize calling irq interrupt function.Non vector interrupt is then that the mode by reading " IRQStatusReg " register completes redirect.Irq function in C firmware is the entity function of interrupt processing, and this function does not have difference when processing above-mentioned two interruptions.
As shown in Figure 2, after completing operation such as boots interruption initialization and interface initialization etc., association's data structure just can be used to carry out assignment operation to free time such as key list, key information district, MAC Address districts.The feature of this operation is originally scattered data structure to be integrated together to carry out whole word assignment.In the past in firmware use pointer assignment method, being made in firmware like this, to write meeting more convenient, but can cause the wasting of resources in bus more.As used pointer assignment 4bit " f ", bus can show as " 32 ' hxxxxxxxf ", and remaining idle will be wasted, and will stop above-mentioned waste with whole word output after data preparation, decrease bus operation number of times.
201: the data structure before integration can be position, byte, half-word, and can be discontinuous.
202: the data after integration can output in bus with the form of a whole word.
As shown in Figure 3, realize using for circulation to replace the operation of Switch statement, thus reduce C code cubage.Switch statements all in theory can carry out this and optimize, and the Switch statement line number just had is little, or too complex need not realize or badly realize this optimization.Initialization BD chained list spatial operation carries out the Optimum Operation of for loop statement conversion after debugging is stablized with regard to can be implemented in very much.In practical operation, find that the line number of C code is fewer, compiling " * .hex " file is out also less, and the load time being reacted to firmware in simulation process is also fewer, directly can improve simulation efficiency.
Above-mentioned firmware Optimum Operation is suitable for too in FPGA emulation and actual plate level firmware, and just because FGPA emulation or plate level operate insensitive to the time of firmware operation, it is not very urgent for result in the demand of firmware Optimum Operation.
Claims (3)
1. based on the disposal route that the 802.11n wireless network card chip emulation firmware of SoC framework is optimized, it is characterized in that: the collaborative simulation utilizing firmware realization and verification environment and RTL, emulation and post-simulation work before realizing; CPU starts to call firmware program after completing electrification reset, and firmware is according to the data structure response instruction consulted with verification environment and data, and the self-verifying module finally provided by verification environment completes result and judges and terminate emulation; Firmware is as follows with the flow process in verification environment and RTL collaborative simulation process:
(1) first CPU calls in firmware the boots program collecting and write after electrification reset, completes the configuration to interrupt control register, utilize boots program realize interrupt function link and vector interrupt, non vector interrupt initialization operation; By realizing the operation of removing vector interrupt to the indirect assignment of interrupt control register in vector interrupt operation;
(2) association's data structure is used to complete the assignment operation of interface register, internal register, key list, key information district, MAC Address, BD register, by association's data structure, scattered data structure be integrated together and carry out whole word assignment, the data after integration can output in bus with the form of a whole word;
(3) carrying out in assignment operating process to BD register, using loop statement to replace the code presented in expanded form, using for circulation to replace Switch statement, realize the optimization of code under identical function;
(4) carry out the operation response of interrupt function, realize downlink command, up-downgoing data manipulation;
(5) the operation response backed off after random interrupt function completing this interrupt function carries out waiting for the process of next interrupt function;
(6), complete the inspection of each transmitting and receiving data frame at verification environment after, emulation is stopped.
2. method according to claim 1, it is characterized in that: utilize association's data structure to improve bus data transfer efficiency, reach the object reducing power consumption, when bus carries out data transmission, the data structure that needs operate is integrated, the unified of data is completed to respective stored address and exports.
3. method according to claim 1, it is characterized in that: by association's data structure, scattered data structure is integrated together and carries out whole word assignment, data structure before integration is position or byte or half-word, and be discontinuous or continuous print, the data structure after integration outputs in bus with the form of a whole word.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201110255501.0A CN102955713B (en) | 2011-08-31 | 2011-08-31 | The disposal route that a kind of 802.11n wireless network card chip emulation firmware is optimized |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201110255501.0A CN102955713B (en) | 2011-08-31 | 2011-08-31 | The disposal route that a kind of 802.11n wireless network card chip emulation firmware is optimized |
Publications (2)
Publication Number | Publication Date |
---|---|
CN102955713A CN102955713A (en) | 2013-03-06 |
CN102955713B true CN102955713B (en) | 2015-11-25 |
Family
ID=47764542
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201110255501.0A Active CN102955713B (en) | 2011-08-31 | 2011-08-31 | The disposal route that a kind of 802.11n wireless network card chip emulation firmware is optimized |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN102955713B (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US9916185B2 (en) | 2014-03-18 | 2018-03-13 | International Business Machines Corporation | Managing processing associated with selected architectural facilities |
US9582295B2 (en) | 2014-03-18 | 2017-02-28 | International Business Machines Corporation | Architectural mode configuration |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6848084B1 (en) * | 2002-07-02 | 2005-01-25 | Cadence Design Systems, Inc. | Method and apparatus for verification of memories at multiple abstraction levels |
CN1818790A (en) * | 2005-02-07 | 2006-08-16 | 中芯国际集成电路制造(上海)有限公司 | Optical adjacent correction for mask pattern during photoetching process |
CN101344899A (en) * | 2008-08-15 | 2009-01-14 | 炬力集成电路设计有限公司 | Simulation test method and system of on-chip system |
CN101720466A (en) * | 2007-05-09 | 2010-06-02 | 新思公司 | Techniques for use with automated circuit design and simulations |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP2797239B1 (en) * | 2005-10-28 | 2018-09-05 | Nokia Solutions and Networks Oy | A method and a telecommunication device for selecting a number of code channels and an associated spreading factor for a CDMA transmission |
CN101047927B (en) * | 2007-04-23 | 2011-11-30 | 北京中星微电子有限公司 | System and method for implementing mobile terminal baseband SOC |
-
2011
- 2011-08-31 CN CN201110255501.0A patent/CN102955713B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6848084B1 (en) * | 2002-07-02 | 2005-01-25 | Cadence Design Systems, Inc. | Method and apparatus for verification of memories at multiple abstraction levels |
CN1818790A (en) * | 2005-02-07 | 2006-08-16 | 中芯国际集成电路制造(上海)有限公司 | Optical adjacent correction for mask pattern during photoetching process |
CN101720466A (en) * | 2007-05-09 | 2010-06-02 | 新思公司 | Techniques for use with automated circuit design and simulations |
CN101344899A (en) * | 2008-08-15 | 2009-01-14 | 炬力集成电路设计有限公司 | Simulation test method and system of on-chip system |
Also Published As
Publication number | Publication date |
---|---|
CN102955713A (en) | 2013-03-06 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103678745B (en) | Cross-platform multi-level integrated design system for FPGA | |
CN103412990B (en) | A kind of multi-level collaborative low-power design method | |
US8341568B2 (en) | Systems and methods for logic verification | |
CN101788931B (en) | Dynamic local reconfigurable system for real-time fault tolerance of hardware | |
CN103235749A (en) | FPGA-based sensor network SoC proto verification platform | |
CN116661870A (en) | RISC-V architecture-based high-performance embedded processor | |
CN103927219A (en) | Accurate-period simulation model for reconfigurable special processor core and hardware architecture thereof | |
CN105975664B (en) | A kind of appraisal procedure of chip power-consumption Evaluation Platform | |
CN109446740B (en) | System-on-chip architecture performance simulation platform | |
US20150347654A1 (en) | Extracting system architecture in high level synthesis | |
CN100568247C (en) | An event processing unit group of a multi-core processor that satisfies systemC syntax | |
CN116414526B (en) | Simulation device and method based on virtual machine | |
CN102207904A (en) | Apparatus and method for simulating a reconfigurable processor | |
CN102955713B (en) | The disposal route that a kind of 802.11n wireless network card chip emulation firmware is optimized | |
US7409670B1 (en) | Scheduling logic on a programmable device implemented using a high-level language | |
CN108121842A (en) | The verification method and device of the low energy consumption operation mode of multiprocessor system chip | |
WO2023232006A1 (en) | Simulation device, simulation system, simulation method, and storage medium | |
CN203260028U (en) | Sensor network SoC prototype verification platform based on FPGA | |
CN115017845A (en) | Bus driving type chip simulation excitation model for IP unit level verification | |
CN100373351C (en) | A high-speed transaction-level software-hardware co-simulation method | |
US7370311B1 (en) | Generating components on a programmable device using a high-level language | |
CN114138342B (en) | ROCC coprocessor interface model and its automatic generation tools and implementation methods | |
CN111679859A (en) | An automated parallel MPI-I/O acceleration method for I/O-intensive high-performance applications | |
CN103455401B (en) | A Co-Verification Method for DSP and FPGA Tightly Coupled Architecture | |
CN113806153B (en) | Chip verification method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
CB02 | Change of applicant information |
Address after: 102209 Beijing, Beiqijia, the future of science and technology in the south area of China electronic network security and information technology industry base C building, Applicant after: Beijing CEC Huada Electronic Design Co., Ltd. Address before: 100102 Beijing City, Chaoyang District Lize two Road No. 2, Wangjing science and Technology Park A block five layer Applicant before: Beijing CEC Huada Electronic Design Co., Ltd. |
|
COR | Change of bibliographic data | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant |