OpenCores
URL https://opencores.org/ocsvn/ao486/ao486/trunk

Subversion Repositories ao486

[/] [ao486/] [trunk/] [rtl/] [ao486/] [commands/] [CMD_POP_seg.txt] - Rev 8

Go to most recent revision | Compare with Previous | Blame | View Log


<defines>
`define CMD_POP_seg     #AUTOGEN_NEXT_CMD

`define CMDEX_POP_seg_STEP_1        4'd0
`define CMDEX_POP_seg_STEP_LAST     4'd1
</defines>

<decode>
(dec_ready_one && (decoder[7:0] == 8'h07 || decoder[7:0] == 8'h17 || decoder[7:0] == 8'h1F)) || (dec_ready_2byte_one && (decoder[7:0] == 8'hA1 || decoder[7:0] == 8'hA9))
`CMD_POP_seg
SET(dec_cmdex, `CMDEX_POP_seg_STEP_1);
SET(consume_one);
SET(dec_is_complex);
</decode>

<microcode>
`CMDEX_POP_seg_STEP_1
CALL(`CMDEX_load_seg_STEP_1);
LOOP(`CMDEX_POP_seg_STEP_LAST);
</microcode>

<read>
IF(rd_cmd == `CMD_POP_seg && rd_cmdex == `CMDEX_POP_seg_STEP_1);

    SET(address_stack_pop);
    // waiting for esp in 'address_ready'
    
    SET(read_length_word);
    
    SET(rd_req_esp);
    
    SET(rd_glob_param_1_set);
    SET(rd_glob_param_1_value, { 13'd0, rd_decoder[5:3], read_4[15:0] });
    
    IF(rd_mutex_busy_memory); SET(rd_waiting);
    ELSE();
        SET(read_virtual);

        IF(~(read_for_rd_ready)); SET(rd_waiting); ENDIF();
    ENDIF();
ENDIF();
</read>

<execute>
IF(exe_cmd == `CMD_POP_seg);
    SET(offset_pop);
ENDIF();
</execute>

<write>
IF(wr_cmd == `CMD_POP_seg && wr_cmdex == `CMDEX_POP_seg_STEP_1);
    
    SAVE(esp, wr_stack_esp);
    SET(wr_make_esp_speculative);
    
    SET(wr_not_finished);
ENDIF();
</write>

<write>
IF(wr_cmd == `CMD_POP_seg && wr_cmdex == `CMDEX_POP_seg_STEP_LAST);
    
    SET(wr_make_esp_commit);
    
    IF(wr_decoder[5:3] == `SEGMENT_SS); SET(wr_inhibit_interrupts_and_debug); ENDIF();
    
    // clear pipeline
    SET(wr_req_reset_micro);
    SET(wr_req_reset_rd);
    SET(wr_req_reset_exe);
ENDIF();
</write>

Go to most recent revision | Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.