bucaps/marss-riscv

Extra `floor`: function is applied to an integer argument

Closed this issue · 1 comments

In https://github.com/bucaps/marss-riscv/blob/master/src/riscvsim/btb.c

int comp = floor(c->num_ways / 2);

...
lower_bound = floor((lower_bound + upper_bound) / 2) + 1;

and in https://github.com/bucaps/marss-riscv/blob/master/src/riscvsim/btb.c

upper_bound = floor((lower_bound + upper_bound) / 2);

...
comp = floor((comp + b->ways - 1) / 2);

Fixed in commit 98f2e59