UCL-INGI / INGInious

INGInious is a secure and automated exercises assessment platform using your own tests, also providing a pluggable interface with your existing LMS.
http://www.inginious.org
Other
202 stars 139 forks source link

Ability to execute code on the same machine #865

Open tbarbette opened 1 year ago

tbarbette commented 1 year ago

For performance-related course (execution time of sorting algorithms, number of cycles to execute a loop, number of cache misses in a code, ...), we'd like students to get the same "numbers". This also allows a scoreboard, to create a competition between the students.

Potential solutions A few solutions are:

Alternatives

anthonygego commented 1 year ago

You will never get accurate time measurements whatever the setup is, except if your code is the only thing running on the machine with the exact same initial conditions for the whole machine state (hardware state included). That is why measuring code complexity, implementing and counting software traps or using simulators are probably the best solutions.

Trying to shrink the measurement approximation window with such requirements makes implementing the missing instructions in a simulator look like a trivial and inexpensive goal.

tbarbette commented 1 year ago

I agree there will still be external parameters. But if we can run the code on a dedicated CPU per jobs, on the same machine, the biggest ones are out of the picture already :)