kaist-cp / cs420

KAIST CS420: Compiler Design (2023 Spring)
420 stars 28 forks source link

[HW1] Is grading method in gg diff. from ./scripts/grade-write_c.sh? Grading takes longer than expected. #480

Closed Re-st closed 1 year ago

Re-st commented 1 year ago

In short, code is being 'checked' on gg for >2hrs by now.

After checking success on ./scripts/grade-write_c.sh (grading 80 fuzzer cases < 20min for all 3 trials), I submitted on gg, 2 hrs ago, and once again the same code 30min ago, but still the code is 'Checking...'. and I cannot help but think is the server down, or grading method of gg is different from ./scripts/grade-write_c.sh (which probably is not true, but just in case). In case theh grading method is different, I leave a question here. Thank you!

(Edit) The log end with "test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 11 filtered out; finished in 85.95s" (...) "Test case # 80 (skipped: 0)". But the status is still 'Checking...'.

m-spitfire commented 1 year ago

I just submitted it and got "Yes" for success, have you checked the success column and see what it says? If it doesn't say "Yes", it's probably a problem in your implementation(maybe infinite loop, but that would time out)

Re-st commented 1 year ago

I just submitted it and got "Yes" for success, have you checked the success column and see what it says? If it doesn't say "Yes", it's probably a problem in your implementation(maybe infinite loop, but that would time out)

It says 'Checking...'.

ID | INPUT | SUBMITTED AT | LOG | SUCCESS? | CHECKED AT write_c.rs | 2023-03-31 15:24:31 | log | Checking... | 2023-03-31 15:24:31 write_c.rs | 2023-03-31 13:52:26 | log | Checking... | 2023-03-31 13:52:26

Kinda weird if there's an infinite loop because 1) would time out (probably?) 2) not happening on running ./scripts/grade-write_c.sh on cp-service.kaist.ac.kr

Re-st commented 1 year ago

In self-grading, If the evaluation ends with "Test case # 80 (skipped: 0)", does it indicate Success?

sklationd commented 1 year ago

Yes! You can check out this issue.

Re-st commented 1 year ago

Yes! You can check out this issue.

Thank you! Very weird that I get the same log at gg but it doesnt comply as success, just still evaluating.

Re-st commented 1 year ago

Now it's almost 4 hours after submission. The status still being 'Checking...', while the log says it's complete, seems like a bug in site. I know this might be a too-much thing to ask, but can I request to get evaluation on the code in other ways than gg, or at least get a probable reason that the bugging situation is belonging to my code (if it is), not to the gg system. I'm getting nervous if this issue lead to 0 points in my first assignment. @AnHaechan @jirheee

AnHaechan commented 1 year ago

I will check this issue before 7pm...

AnHaechan commented 1 year ago

@Re-st

  1. Can you copy-paste and post the full log of your submission here?
  2. Can you send your write_c.rs to haechan.an@cp.kaist.ac.kr? We'll use it for grading if we couldn't resolve your gg problem.
Re-st commented 1 year ago

log is 64mb (57만 줄), while allowed size to upload here is 25mb. I'll try to send both the log and code to your email.

AnHaechan commented 1 year ago

Oh, I meant the log in gg. For example,

===== SETUP =====

===== CHECK =====
[2023-03-31 09:57:55,996: WARNING/ForkPoolWorker-32] Demoting to runner...
info: downloading installer
info: profile set to 'default'
info: default host triple is x86_64-unknown-linux-gnu
warning: Updating existing toolchain, profile choice will be ignored
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
info: default toolchain set to 'stable-x86_64-unknown-linux-gnu'

  stable-x86_64-unknown-linux-gnu unchanged - rustc 1.68.2 (9eb3afe9e 2023-03-27)

Rust is installed now. Great!

To get started you may need to restart your current shell.
This would reload your PATH environment variable to include
Cargo's bin directory ($HOME/.cargo/bin).

To configure your current shell, run:
source "$HOME/.cargo/env"
Cloning into 'kecc-public'...
   Compiling libc v0.2.139
   Compiling proc-macro2 v1.0.51
   Compiling quote v1.0.23
   Compiling unicode-ident v1.0.6
    Checking cfg-if v1.0.0
   Compiling io-lifetimes v1.0.3
   Compiling autocfg v1.1.0
   Compiling syn v1.0.109
   Compiling rustix v0.36.5
    Checking linux-raw-sys v0.1.4
    Checking ppv-lite86 v0.2.17
   Compiling thiserror v1.0.38
   Compiling peg-runtime v0.8.1
    Checking bitflags v1.3.2
    Checking fastrand v1.9.0
    Checking either v1.8.0
    Checking lang-c v0.15.0
    Checking hexf-parse v0.2.1
    Checking itertools v0.10.5
   Compiling num-traits v0.2.15
   Compiling peg-macros v0.8.1
    Checking getrandom v0.2.8
    Checking wait-timeout v0.2.0
    Checking rand_core v0.6.4
    Checking ordered-float v3.4.0
    Checking rand_chacha v0.3.1
    Checking rand v0.8.5
    Checking peg v0.8.1
    Checking tempfile v3.4.0
   Compiling thiserror-impl v1.0.38
    Checking kecc v0.1.0 (/app/files/checks/79b28c96-98dd-4661-959e-51556a611d24/kecc-public)
    Finished dev [unoptimized + debuginfo] target(s) in 7.61s
   Compiling libc v0.2.139
   Compiling proc-macro2 v1.0.51
   Compiling unicode-ident v1.0.6
   Compiling quote v1.0.23
   Compiling cfg-if v1.0.0
   Compiling syn v1.0.109
   Compiling autocfg v1.1.0
   Compiling io-lifetimes v1.0.3
   Compiling rustix v0.36.5
   Compiling thiserror v1.0.38
   Compiling bitflags v1.3.2
   Compiling ppv-lite86 v0.2.17
   Compiling peg-runtime v0.8.1
   Compiling linux-raw-sys v0.1.4
   Compiling fastrand v1.9.0
   Compiling either v1.8.0
   Compiling lang-c v0.15.0
   Compiling hexf-parse v0.2.1
   Compiling itertools v0.10.5
   Compiling num-traits v0.2.15
   Compiling peg-macros v0.8.1
   Compiling getrandom v0.2.8
   Compiling wait-timeout v0.2.0
   Compiling rand_core v0.6.4
   Compiling rand_chacha v0.3.1
   Compiling ordered-float v3.4.0
   Compiling rand v0.8.5
   Compiling peg v0.8.1
   Compiling thiserror-impl v1.0.38
   Compiling tempfile v3.4.0
   Compiling kecc v0.1.0 (/app/files/checks/79b28c96-98dd-4661-959e-51556a611d24/kecc-public)
    Finished release [optimized] target(s) in 12.55s
     Running unittests src/lib.rs (target/release/deps/kecc-7065a22d2103757c)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running tests/test_examples.rs (target/release/deps/test_examples-d8ae6d8bc74bd05f)

running 1 test
[testing "examples/c/unary.c"]
[testing "examples/c/array4.c"]
[testing "examples/c/fib2.c"]
[testing "examples/c/integer_literal2.c"]
[testing "examples/c/cmp.c"]
[testing "examples/c/fib3.c"]
[testing "examples/c/array5.c"]
[testing "examples/c/complement.c"]
[testing "examples/c/typedef.c"]
[testing "examples/c/gcd.c"]
[testing "examples/c/foo4.c"]
[testing "examples/c/sizeof2.c"]
[testing "examples/c/switch.c"]
[testing "examples/c/array.c"]
[testing "examples/c/minus_constant.c"]
[testing "examples/c/simple.c"]
[testing "examples/c/complete_cond.c"]
[testing "examples/c/while_continue_break.c"]
[testing "examples/c/sizeof3.c"]
[testing "examples/c/negate.c"]
[testing "examples/c/temp2.c"]
[testing "examples/c/float2.c"]
[testing "examples/c/struct4.c"]
[testing "examples/c/temp.c"]
[testing "examples/c/cond.c"]
[testing "examples/c/test.c"]
[testing "examples/c/fib4.c"]
[testing "examples/c/array2.c"]
[testing "examples/c/bitwise.c"]
[testing "examples/c/bar.c"]
[testing "examples/c/return_void.c"]
[testing "examples/c/cond_and_loop.c"]
[testing "examples/c/foo.c"]
[testing "examples/c/array3.c"]
[testing "examples/c/fib5.c"]
[testing "examples/c/simple_for.c"]
[testing "examples/c/for_continue_break.c"]
[testing "examples/c/pointer.c"]
[testing "examples/c/struct3.c"]
[testing "examples/c/simple_if.c"]
[testing "examples/c/foo2.c"]
[testing "examples/c/comma.c"]
[testing "examples/c/sizeof4.c"]
[testing "examples/c/alignof.c"]
[testing "examples/c/shift.c"]
[testing "examples/c/fibonacci.c"]
[testing "examples/c/typecast.c"]
[testing "examples/c/simple_cond.c"]
[testing "examples/c/logical_op.c"]
[testing "examples/c/struct.c"]
[testing "examples/c/foo3.c"]
[testing "examples/c/float.c"]
[testing "examples/c/sizeof.c"]
[testing "examples/c/integer_literal.c"]
[testing "examples/c/struct2.c"]
test test_examples_write_c ... ok

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 11 filtered out; finished in 1.17s

   Compiling version_check v0.9.4
   Compiling syn v1.0.109
   Compiling io-lifetimes v1.0.3
   Compiling rustix v0.36.5
   Compiling heck v0.4.1
   Compiling os_str_bytes v6.4.1
   Compiling strsim v0.10.0
   Compiling once_cell v1.17.1
   Compiling termcolor v1.2.0
   Compiling clap_lex v0.3.2
   Compiling proc-macro-error-attr v1.0.4
   Compiling proc-macro-error v1.0.4
   Compiling is-terminal v0.4.1
   Compiling tempfile v3.4.0
   Compiling thiserror-impl v1.0.38
   Compiling clap_derive v4.1.7
   Compiling thiserror v1.0.38
   Compiling clap v4.1.7
   Compiling kecc v0.1.0 (/app/files/checks/79b28c96-98dd-4661-959e-51556a611d24/kecc-public)
    Finished release [optimized] target(s) in 14.32s
Set seed as 22
Building KECC..
Fuzzing with 80 test cases.
Test case #0 (skipped: 0)
Test case #1 (skipped: 0)
Test case #2 (skipped: 0)
Test case #3 (skipped: 0)
Test case #4 (skipped: 0)
Test case #5 (skipped: 0)
Test case #6 (skipped: 0)
Test case #7 (skipped: 0)
Test case #8 (skipped: 0)
Test case #9 (skipped: 0)
Test case #10 (skipped: 0)
Test case #11 (skipped: 0)
Test case #12 (skipped: 0)
Test case #13 (skipped: 0)
Test case #14 (skipped: 0)
Test case #15 (skipped: 0)
Test case #16 (skipped: 0)
Test case #17 (skipped: 0)
Test case #18 (skipped: 0)
Test case #19 (skipped: 0)
Test case #20 (skipped: 0)
Test case #21 (skipped: 0)
Test case #22 (skipped: 0)
Test case #23 (skipped: 0)
Test case #24 (skipped: 0)
Test case #25 (skipped: 0)
Test case #26 (skipped: 0)
Test case #27 (skipped: 0)
Test case #28 (skipped: 0)
Test case #29 (skipped: 0)
Test case #30 (skipped: 0)
Test case #31 (skipped: 0)
Test case #32 (skipped: 0)
Test case #33 (skipped: 0)
Test case #34 (skipped: 0)
Test case #35 (skipped: 0)
Test case #36 (skipped: 0)
Test case #37 (skipped: 0)
Test case #38 (skipped: 0)
Test case #39 (skipped: 0)
Test case #40 (skipped: 0)
Test case #41 (skipped: 0)
Test case #42 (skipped: 0)
Test case #43 (skipped: 0)
Test case #44 (skipped: 0)
Test case #45 (skipped: 0)
Test case #46 (skipped: 0)
Test case #47 (skipped: 0)
Test case #48 (skipped: 0)
Test case #49 (skipped: 0)
Test case #50 (skipped: 0)
Test case #51 (skipped: 0)
Test case #52 (skipped: 0)
Test case #53 (skipped: 0)
Test case #54 (skipped: 0)
Test case #55 (skipped: 0)
Test case #56 (skipped: 0)
Test case #57 (skipped: 0)
Test case #58 (skipped: 0)
Test case #59 (skipped: 0)
Test case #60 (skipped: 0)
Test case #61 (skipped: 0)
Test case #62 (skipped: 0)
Test case #63 (skipped: 0)
Test case #64 (skipped: 0)
Test case #65 (skipped: 0)
Test case #66 (skipped: 0)
Test case #67 (skipped: 0)
Test case #68 (skipped: 0)
Test case #69 (skipped: 0)
Test case #70 (skipped: 0)
Test case #71 (skipped: 0)
Test case #72 (skipped: 0)
Test case #73 (skipped: 0)
Test case #74 (skipped: 0)
Test case #75 (skipped: 0)
Test case #76 (skipped: 0)
Test case #77 (skipped: 0)
Test case #78 (skipped: 0)
Test case #79 (skipped: 0)
Test case #80 (skipped: 0)
AnHaechan commented 1 year ago

Okay, I think the problem of your write_c.rs is probably that it prints out too many stuffs. Can you remove print! or println! or other print-to-stdout functions in your write_c.rs and submit it again to gg?

Re-st commented 1 year ago

Oh, I meant the log in gg. For example,

The problem was on my code.

After comparing my long code to this one, I finally understood the problem was that I put dbg! macro on the code, hence the log became 64mb. (All C ast's formatted and put on the log). I'm really sorry to have bugging you with this. On a new attempt with dbg macro deleted, gg is printing out Yes as result. I didn't think the log printing C asts were sign of wrong coding. Again I am really sorry for the dumb question. @AnHaechan

AnHaechan commented 1 year ago

No, you don't need to be sorry. At least asking it is better than not asking and get zero points for the assignment ;) Always feel free to ask questions!

Re-st commented 1 year ago

Thank you so much!