summary refs log tree commit diff stats
path: root/results/classifier/zero-shot/105/assembly/1649
diff options
context:
space:
mode:
Diffstat (limited to 'results/classifier/zero-shot/105/assembly/1649')
-rw-r--r--results/classifier/zero-shot/105/assembly/164930
1 files changed, 30 insertions, 0 deletions
diff --git a/results/classifier/zero-shot/105/assembly/1649 b/results/classifier/zero-shot/105/assembly/1649
new file mode 100644
index 000000000..7d78cca98
--- /dev/null
+++ b/results/classifier/zero-shot/105/assembly/1649
@@ -0,0 +1,30 @@
+assembly: 0.984
+instruction: 0.900
+graphic: 0.900
+device: 0.747
+semantic: 0.642
+vnc: 0.610
+network: 0.592
+socket: 0.542
+mistranslation: 0.500
+boot: 0.379
+KVM: 0.352
+other: 0.209
+
+"slli" instruction before "la" and "csrw" sequence leads to failure in setting the cs register
+Description of problem:
+slli a0, a0, 8 (1)
+    la a0, mtimvec (2)
+    csrw mtvec, a0 (3)
+    mtimvec:       (4)
+
+For the above assembly snippet, the mtvec could be successfully set to the value of a0 
+without the presence of the line (1) or with the shift amount being zero. However, 
+the mtvec can never be set successfully with the presence of line (1).
+Steps to reproduce:
+1. Create a test.s file and put these 4 lines of assembly into the file
+2. In terminal, run: "riscv64-unknown-elf-gcc -Ttext 0x80000000 -c test.s -o test", "riscv64-unknown-elf-objcopy test -S -O binary test", and "qemu-system-riscv64 test -s -S"
+3. In another terminal window, run [riscv64-unknown-elf-gdb -ex "target remote localhost:1234" -ex "layout asm"]. Keep running si command in gdb until you are at 0x80000000 where you shall see the first instruction as shown in line (1). Then keep going till you have stepped over the instruction shown in line (3). Now, run "p $mtvec" in gdb, you shall see its value being 0.
+4. Redo the above steps without line (1), you shall see mtvec loaded successfully with the correct value.
+Additional information:
+