Browse Source

remove unused variable

master
吴冕志 2 years ago
parent
commit
cdc6fe7913
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      lab2/datalab-handout/bits.c

+ 1
- 1
lab2/datalab-handout/bits.c View File

@ -323,7 +323,7 @@ int howManyBits(int x) {
int rs1 = rs2r >> 1;
int bits1_flag = (!!(rs1) << 31) >> 31; // 0xfffffff if not 0
int bits1 = 1;
int rs1r = (bits1_flag & rs1) | ((~bits1_flag) & rs2r); // rs1, if rs1 not 0, rs2 if rs1 0
//int rs1r = (bits1_flag & rs1) | ((~bits1_flag) & rs2r); // rs1, if rs1 not 0, rs2 if rs1 0
int b1 = bits1_flag & bits1;
int is0orneg1 = (!(x ^ (0))) | (!(x ^((1<<31)>>31)));

Loading…
Cancel
Save