data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v
1: b'%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:1: Cannot find include file: src/main/Define/signal_def.v\n`include "src/main/Define/signal_def.v" \n         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n        ... Looked in:\n             data/full_repos/permissive/115074071/src/main/Controller,data/full_repos/permissive/115074071/src/main/Define/signal_def.v\n             data/full_repos/permissive/115074071/src/main/Controller,data/full_repos/permissive/115074071/src/main/Define/signal_def.v.v\n             data/full_repos/permissive/115074071/src/main/Controller,data/full_repos/permissive/115074071/src/main/Define/signal_def.v.sv\n             src/main/Define/signal_def.v\n             src/main/Define/signal_def.v.v\n             src/main/Define/signal_def.v.sv\n             obj_dir/src/main/Define/signal_def.v\n             obj_dir/src/main/Define/signal_def.v.v\n             obj_dir/src/main/Define/signal_def.v.sv\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:2: Cannot find include file: src/main/Define/aluop_def.v\n`include "src/main/Define/aluop_def.v" \n         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:3: Cannot find include file: src/main/Define/op_def.v\n`include "src/main/Define/op_def.v" \n         ^~~~~~~~~~~~~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:16: Define or directive not defined: \'`ALUCTRL_ADD\'\n            `ALUCTRL_ADD: begin\n            ^~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:16: syntax error, unexpected \':\', expecting endcase\n            `ALUCTRL_ADD: begin\n                        ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:17: Define or directive not defined: \'`EXTOP_SIGNED\'\n                EXTOp = `EXTOP_SIGNED;\n                        ^~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:18: Define or directive not defined: \'`ALUOP_ADD\'\n                ALUOp = `ALUOP_ADD;\n                        ^~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:18: syntax error, unexpected \';\', expecting TYPE-IDENTIFIER\n                ALUOp = `ALUOP_ADD;\n                                  ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:20: Define or directive not defined: \'`ALUCTRL_ADDU\'\n            `ALUCTRL_ADDU: begin\n            ^~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:20: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n            `ALUCTRL_ADDU: begin\n                           ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:21: Define or directive not defined: \'`EXTOP_UNSIGNED\'\n                EXTOp = `EXTOP_UNSIGNED;\n                        ^~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:22: Define or directive not defined: \'`ALUOP_ADD\'\n                ALUOp = `ALUOP_ADD;\n                        ^~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:22: syntax error, unexpected \';\', expecting TYPE-IDENTIFIER\n                ALUOp = `ALUOP_ADD;\n                                  ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:24: Define or directive not defined: \'`ALUCTRL_RTYPE\'\n            `ALUCTRL_RTYPE: begin\n            ^~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:24: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n            `ALUCTRL_RTYPE: begin\n                            ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:27: Define or directive not defined: \'`ALUCTRL_ITYPE\'\n            `ALUCTRL_ITYPE: begin\n            ^~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:27: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n            `ALUCTRL_ITYPE: begin\n                            ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:29: Define or directive not defined: \'`OP_ADDI\'\n                    `OP_ADDI:   begin\n                    ^~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:30: Define or directive not defined: \'`EXTOP_SIGNED\'\n                        EXTOp   =   `EXTOP_SIGNED;\n                                    ^~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:31: Define or directive not defined: \'`ALUOP_ADD\'\n                        ALUOp   =   `ALUOP_ADD;\n                                    ^~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:31: syntax error, unexpected \';\', expecting TYPE-IDENTIFIER\n                        ALUOp   =   `ALUOP_ADD;\n                                              ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:33: Define or directive not defined: \'`OP_ADDIU\'\n                    `OP_ADDIU:  begin\n                    ^~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:33: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n                    `OP_ADDIU:  begin\n                                ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:34: Define or directive not defined: \'`EXTOP_UNSIGNED\'\n                        EXTOp   =   `EXTOP_UNSIGNED;\n                                    ^~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:35: Define or directive not defined: \'`ALUOP_ADDU\'\n                        ALUOp   =   `ALUOP_ADDU;\n                                    ^~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:35: syntax error, unexpected \';\', expecting TYPE-IDENTIFIER\n                        ALUOp   =   `ALUOP_ADDU;\n                                               ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:37: Define or directive not defined: \'`OP_ANDI\'\n                    `OP_ANDI:   begin\n                    ^~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:37: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n                    `OP_ANDI:   begin\n                                ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:38: Define or directive not defined: \'`EXTOP_UNSIGNED\'\n                        EXTOp   =   `EXTOP_UNSIGNED;\n                                    ^~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:39: Define or directive not defined: \'`ALUOP_ANDI\'\n                        ALUOp   =   `ALUOP_ANDI;\n                                    ^~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:39: syntax error, unexpected \';\', expecting TYPE-IDENTIFIER\n                        ALUOp   =   `ALUOP_ANDI;\n                                               ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:41: Define or directive not defined: \'`OP_ORI\'\n                    `OP_ORI:    begin\n                    ^~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:41: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n                    `OP_ORI:    begin\n                                ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:42: Define or directive not defined: \'`EXTOP_UNSIGNED\'\n                        EXTOp   =   `EXTOP_UNSIGNED;\n                                    ^~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:43: Define or directive not defined: \'`ALUOP_ORI\'\n                        ALUOp   =   `ALUOP_ORI;\n                                    ^~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:43: syntax error, unexpected \';\', expecting TYPE-IDENTIFIER\n                        ALUOp   =   `ALUOP_ORI;\n                                              ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:45: Define or directive not defined: \'`OP_XORI\'\n                    `OP_XORI:   begin\n                    ^~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:45: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n                    `OP_XORI:   begin\n                                ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:46: Define or directive not defined: \'`EXTOP_UNSIGNED\'\n                        EXTOp   =   `EXTOP_UNSIGNED;\n                                    ^~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:47: Define or directive not defined: \'`ALUOP_XORI\'\n                        ALUOp   =   `ALUOP_XORI;\n                                    ^~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:47: syntax error, unexpected \';\', expecting TYPE-IDENTIFIER\n                        ALUOp   =   `ALUOP_XORI;\n                                               ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:49: Define or directive not defined: \'`OP_LUI\'\n                    `OP_LUI:    begin\n                    ^~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:49: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n                    `OP_LUI:    begin\n                                ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:50: Define or directive not defined: \'`EXTOP_UNSIGNED\'\n                        EXTOp   =   `EXTOP_UNSIGNED;\n                                    ^~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:51: Define or directive not defined: \'`ALUOP_LUI\'\n                        ALUOp   =   `ALUOP_LUI;\n                                    ^~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:51: syntax error, unexpected \';\', expecting TYPE-IDENTIFIER\n                        ALUOp   =   `ALUOP_LUI;\n                                              ^\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:53: Define or directive not defined: \'`OP_SLTI\'\n                    `OP_SLTI:   begin\n                    ^~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:53: syntax error, unexpected begin, expecting IDENTIFIER or PACKAGE-IDENTIFIER or TYPE-IDENTIFIER or new\n                    `OP_SLTI:   begin\n                                ^~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:54: Define or directive not defined: \'`EXTOP_SIGNED\'\n                        EXTOp   =   `EXTOP_SIGNED;\n                                    ^~~~~~~~~~~~~\n%Error: data/full_repos/permissive/115074071/src/main/Controller/ALUCtrl.v:55: Define or directive not defined: \'`ALUOP_SLT\'\n                        ALUOp   =   `ALUOP_SLT;\n                                    ^~~~~~~~~~\n%Error: Exiting due to too many errors encountered; --error-limit=50\n'
module ALUCtrl(
    input   [5:0]       OP,
    input   [5:0]       funct,
    input   [1:0]       ALUCtrlOp,

    output  reg[5:0]    ALUOp,
    output  reg[1:0]    EXTOp
);

    always@(*) begin
        case(ALUCtrlOp)
            `ALUCTRL_ADD: begin
                EXTOp = `EXTOP_SIGNED;
                ALUOp = `ALUOP_ADD;
            end
            `ALUCTRL_ADDU: begin
                EXTOp = `EXTOP_UNSIGNED;
                ALUOp = `ALUOP_ADD;
            end
            `ALUCTRL_RTYPE: begin
                ALUOp = funct;
            end
            `ALUCTRL_ITYPE: begin
                case(OP)
                    `OP_ADDI:   begin
                        EXTOp   =   `EXTOP_SIGNED;
                        ALUOp   =   `ALUOP_ADD;
                    end
                    `OP_ADDIU:  begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_ADDU;
                    end
                    `OP_ANDI:   begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_ANDI;
                    end
                    `OP_ORI:    begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_ORI;
                    end
                    `OP_XORI:   begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_XORI;
                    end
                    `OP_LUI:    begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_LUI;
                    end
                    `OP_SLTI:   begin
                        EXTOp   =   `EXTOP_SIGNED;
                        ALUOp   =   `ALUOP_SLT;
                    end
                    `OP_SLTIU:  begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_SLTU;
                    end
                    default:    ALUOp = 2'b000000;
                endcase
            end
            default:
                ALUOp = 0;
        endcase

    end

endmodule
module ALUCtrl(
    input   [5:0]       OP,
    input   [5:0]       funct,
    input   [1:0]       ALUCtrlOp,

    output  reg[5:0]    ALUOp,
    output  reg[1:0]    EXTOp
);


    always@(*) begin
        case(ALUCtrlOp)
            `ALUCTRL_ADD: begin
                EXTOp = `EXTOP_SIGNED;
                ALUOp = `ALUOP_ADD;
            end
            `ALUCTRL_ADDU: begin
                EXTOp = `EXTOP_UNSIGNED;
                ALUOp = `ALUOP_ADD;
            end
            `ALUCTRL_RTYPE: begin
                ALUOp = funct;
            end
            `ALUCTRL_ITYPE: begin
                case(OP)
                    `OP_ADDI:   begin
                        EXTOp   =   `EXTOP_SIGNED;
                        ALUOp   =   `ALUOP_ADD;
                    end
                    `OP_ADDIU:  begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_ADDU;
                    end
                    `OP_ANDI:   begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_ANDI;
                    end
                    `OP_ORI:    begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_ORI;
                    end
                    `OP_XORI:   begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_XORI;
                    end
                    `OP_LUI:    begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_LUI;
                    end
                    `OP_SLTI:   begin
                        EXTOp   =   `EXTOP_SIGNED;
                        ALUOp   =   `ALUOP_SLT;
                    end
                    `OP_SLTIU:  begin
                        EXTOp   =   `EXTOP_UNSIGNED;
                        ALUOp   =   `ALUOP_SLTU;
                    end
                    default:    ALUOp = 2'b000000;
                endcase
            end
            default:
                ALUOp = 0;
        endcase

    end

endmodule