Semihost extended exit and More floating point support (VABS, VCMP, VMRS) #51
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes several changes across different files to enhance functionality, improve code structure, and update test scripts. The most important changes include modifying return types and error handling in
src/main.rs
, adding new floating-point register operations, and updating test scripts for better error handling and documentation.Modifications to return types and error handling:
src/main.rs
: Changed the return type ofrun_bin
andrun
functions fromResult<()>
toResult<u32>
, and updated themain
function to handle the new return type and exit with the appropriate code. [1] [2] [3] [4] [5] [6]Enhancements to floating-point operations:
src/semihost.rs
: Added handling forSysExitExtended
command with subcode and exit code.zmu_cortex_m/src/core/fpregister.rs
: Introduced a new traitFpscr
for accessing and modifying floating-point status and control register flags.Updates to test scripts:
test_gcc.sh
: Rearranged the order of GCC tests, added error handling to abort on test failure, and improved the output for better readability. [1] [2]tests/instruction-test-bench/main.c
: Added detailed comments and new test cases for ARM Cortex-M instructions, including floating-point operations. [1] [2] [3]Code structure improvements:
zmu_cortex_m/src/core/instruction.rs
: Added new instruction parameters and restructured theInstruction
enum to better organize multiply and saturating instructions. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10]Miscellaneous changes:
zmu.code-workspace
: Updated workspace settings to associateassert.h
with the C language.zmu_cortex_m/build.rs
: Enabled additional floating-point instruction decoding.zmu_cortex_m/src/core/exception.rs
: Simplified the handling of the processor's sleeping state. [1] [2]