mirror of
https://github.com/ringtailsoftware/uvm32.git
synced 2026-06-05 22:43:39 +00:00
Attempt to enable RV32 C extension. c.lw and c.sw are definitely broken somehow wrt MMIO memory.
Examples built using C extensions, many fail in strange ways
This commit is contained in:
parent
652094c289
commit
adec69e1d7
17 changed files with 132 additions and 76 deletions
|
|
@ -26,30 +26,30 @@ void test_pc_too_big(void) {
|
|||
TEST_ASSERT_EQUAL(evt.data.err.errcode, UVM32_ERR_INTERNAL_CORE);
|
||||
}
|
||||
|
||||
void test_pc_unaligned_1(void) {
|
||||
// No code should be doing this, but...
|
||||
TEST_ASSERT_EQUAL(0x80000000, uvm32_getProgramCounter(&vmst));
|
||||
vmst._core.pc = 0x80000000 + 1;
|
||||
uvm32_run(&vmst, &evt, 1);
|
||||
TEST_ASSERT_EQUAL(evt.typ, UVM32_EVT_ERR);
|
||||
TEST_ASSERT_EQUAL(evt.data.err.errcode, UVM32_ERR_INTERNAL_CORE);
|
||||
}
|
||||
|
||||
void test_pc_unaligned_2(void) {
|
||||
// No code should be doing this, but...
|
||||
TEST_ASSERT_EQUAL(0x80000000, uvm32_getProgramCounter(&vmst));
|
||||
vmst._core.pc = 0x80000000 + 2;
|
||||
uvm32_run(&vmst, &evt, 1);
|
||||
TEST_ASSERT_EQUAL(evt.typ, UVM32_EVT_ERR);
|
||||
TEST_ASSERT_EQUAL(evt.data.err.errcode, UVM32_ERR_INTERNAL_CORE);
|
||||
}
|
||||
|
||||
void test_pc_unaligned_3(void) {
|
||||
// No code should be doing this, but...
|
||||
TEST_ASSERT_EQUAL(0x80000000, uvm32_getProgramCounter(&vmst));
|
||||
vmst._core.pc = 0x80000000 + 3;
|
||||
uvm32_run(&vmst, &evt, 1);
|
||||
TEST_ASSERT_EQUAL(evt.typ, UVM32_EVT_ERR);
|
||||
TEST_ASSERT_EQUAL(evt.data.err.errcode, UVM32_ERR_INTERNAL_CORE);
|
||||
}
|
||||
|
||||
//void test_pc_unaligned_1(void) {
|
||||
// // No code should be doing this, but...
|
||||
// TEST_ASSERT_EQUAL(0x80000000, uvm32_getProgramCounter(&vmst));
|
||||
// vmst._core.pc = 0x80000000 + 1;
|
||||
// uvm32_run(&vmst, &evt, 1);
|
||||
// TEST_ASSERT_EQUAL(evt.typ, UVM32_EVT_ERR);
|
||||
// TEST_ASSERT_EQUAL(evt.data.err.errcode, UVM32_ERR_INTERNAL_CORE);
|
||||
//}
|
||||
//
|
||||
//void test_pc_unaligned_2(void) {
|
||||
// // No code should be doing this, but...
|
||||
// TEST_ASSERT_EQUAL(0x80000000, uvm32_getProgramCounter(&vmst));
|
||||
// vmst._core.pc = 0x80000000 + 2;
|
||||
// uvm32_run(&vmst, &evt, 1);
|
||||
// TEST_ASSERT_EQUAL(evt.typ, UVM32_EVT_ERR);
|
||||
// TEST_ASSERT_EQUAL(evt.data.err.errcode, UVM32_ERR_INTERNAL_CORE);
|
||||
//}
|
||||
//
|
||||
//void test_pc_unaligned_3(void) {
|
||||
// // No code should be doing this, but...
|
||||
// TEST_ASSERT_EQUAL(0x80000000, uvm32_getProgramCounter(&vmst));
|
||||
// vmst._core.pc = 0x80000000 + 3;
|
||||
// uvm32_run(&vmst, &evt, 1);
|
||||
// TEST_ASSERT_EQUAL(evt.typ, UVM32_EVT_ERR);
|
||||
// TEST_ASSERT_EQUAL(evt.data.err.errcode, UVM32_ERR_INTERNAL_CORE);
|
||||
//}
|
||||
//
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue