typos 6 minor changes

This commit is contained in:
mariusmonton 2018-11-11 11:12:12 +01:00
parent 36646a182e
commit 1fcbcf500b
3 changed files with 7 additions and 5 deletions

View File

@ -168,7 +168,7 @@ typedef enum {
/** /**
* @brief Instruction decoding and fields access * @brief Instruction decoding and fields access
*/ */
class Instruction{ class Instruction {
public: public:
/** /**
@ -329,6 +329,7 @@ public:
m_instr.range(11,7) = aux.range(4,1); m_instr.range(11,7) = aux.range(4,1);
m_instr[6] = aux[11]; m_instr[6] = aux[11];
} }
/** /**
* @brief Access to immediate field for J-type * @brief Access to immediate field for J-type
* @return immediate_J field * @return immediate_J field
@ -345,6 +346,7 @@ public:
if (m_instr[31] == 1) { if (m_instr[31] == 1) {
aux |= (0b111111111111) << 20; aux |= (0b111111111111) << 20;
} }
return aux; return aux;
} }

View File

@ -310,7 +310,7 @@ void CPU::CPU_thread(void) {
exec->NOP(inst); exec->NOP(inst);
} // switch (inst.check_extension()) } // switch (inst.check_extension())
} }
perf->instructionsInc(); perf->instructionsInc();
if (PC_not_affected == true) { if (PC_not_affected == true) {

View File

@ -5,13 +5,13 @@ TARGET_ARCH=riscv32
CC = riscv32-unknown-linux-gnu-gcc CC = riscv32-unknown-linux-gnu-gcc
# compiling flags here # compiling flags here
#CFLAGS = -Wall -I. -O0 -nostdlib -march=rv32i -mabi=ilp32 --entry main #CFLAGS = -Wall -I. -O0 -nostdlib -march=rv32i -mabi=ilp32 --entry main
#CFLAGS = -Wall -I. -O0 CFLAGS = -Wall -I. -O0 -static
CFLAGS = -Wall -I. -O0 -Xlinker --gc-sections -lgcc -lc -static #CFLAGS = -Wall -I. -O0 -Xlinker --gc-sections -lgcc -lc -static --specs=nano.specs
LINKER = riscv32-unknown-linux-gnu-gcc LINKER = riscv32-unknown-linux-gnu-gcc
# linking flags here # linking flags here
LFLAGS = -I. --entry main LFLAGS = -I. --entry main -L/opt/riscv/riscv32-unknown-elf/lib/
LIBS = $(EXTRA_LIBS) LIBS = $(EXTRA_LIBS)